tengo un dilema nose me ocurre como crear una funcion para que en determinada posicion el MC pare, El tema es que cuando creo la funcion anula la anterior. entoncs directamente se frena y no comienza la animacion. me explico???
les dejo el codigo para que tengan una idea de q toy hablando cualqueir sugestion es bienvenida GRACIAS Y FELIZ AÑOOOOOOOOOOOO
stop();
_global.myVelocity = 2;
_global.myStop = 0;
_global.zeta = 361.8; // when zeta means clip loop.
_global.z = 326;// when z means start next clip.
//variable unDecimal
function sumar(){
this.onEnterFrame = function(){
unDecimal._y += myStop;
if (unNumber._y <= 0) {
unDecimal._y += myStop;
} else if (unNumber._y >= z) {
unDecimal._y += myVelocity;
}
}
}
sumar();
//try whith enteros
unDecimal.onLoad=function() {
this.inicpos_y=new Number();
this.inicpos_y=this._y;
}
unDecimal.onEnterFrame=function () {
if (this._y!= this.inicpos_y) {
_root.actualizaClips();
this.inicpos_y=0;
}
}
function actualizaClips (Void):Void {
if (unDecimal._y > z) {
unEntero._y += myVelocity;
} else if (unEntero._y > z) {
unDecena._y += myVelocity;
} else if (unDecena._y > z) {
unCentena._y += myVelocity;
} else if (unCentena._y > z) {
unMileno._y += myVelocity;
} else if (unMileno._y > z) {
unDiezmil._y += myVelocity;
} else if (unDiezmil._y > z) {
unCienmil._y += myVelocity;
}
}
aaa y otra cosa me han dicho q no es buena idea llamar las variables como "globals" pero sino lo nombro asi no funciona =(
