bonjour j'ai un ptit problème avec un script de navigation q:
en cliquant sur un bouton menu un petit carré vient progressivement s'aligner a coté du bouton cliqué,problème
clickedButtonPosition semble indéfini et le carré part en haut???
ps :j'ai mis ce script dans un calque au dessus d'un autre contenant un diaporama,
pourrait il y avoir conflit de variables?
merci d'avance!
// script
var speed:Number = 9; // vitesse anim
menuButton1_btn.onPress=menuButton2_btn.onPress=menuButton3_btn.onPress=menuButton4_btn.onPress=menuButton5_btn.onPress=menuButton6_btn.onPress=function () {
var clickedButtonPosition:Number = this._y; //
je crois que ça merde là var currentSliderPosition:Number = _root.slider_mc._y;
_root.onEnterFrame = function() {
_root.slider_mc._y += (clickedButtonPosition-currentSliderPosition)/speed ;
currentSliderPosition = _root.slider_mc._y;
if (currentSliderPosition>=(clickedButtonPosition-0.8) && currentSliderPosition<=(clickedButtonPosition+0.8)) {
currentSliderPosition = clickedButtonPosition;
delete _root.onEnterFrame;
};
};
};