Comunidad de diseño web y desarrollo en internet online

PROBLEMAS FADE IN FADE OUT

Citar            
MensajeEscrito el 02 Ago 2008 06:14 pm
Buenas gente.
Tengo un problema, tengo una botonera hecha y quiere hacer un fade in fade out con cada boton. ¿Podriais ayudarme? Gracias.

Por Shaben

21 de clabLevel



Genero:Masculino  

firefox
Citar            
MensajeEscrito el 03 Ago 2008 09:26 am
Hola, es simple creas un boton sobre una Moviclip, y pones este scrip en el boton, al mc le pones como nombre de instancia en este casi tu_mc. cualquier duda tamos aca.

Suerte

Código :

on(rollOver)
{
   this.tu_mc.onEnterFrame = function ()
    {      
//15 es el numero del fotograma hasta dnd va a llegar tu animacion dentro del mc
        if (this._currentframe != 15)
        {
            this.nextFrame();
        }         
        else
        {
            this.stop();
            delete this["onEnterFrame"];
        } // end if
    };
}
on (rollOut)
{
   this.tu_mc.onEnterFrame = function ()
    {            
//1 es el numero del fotograma hasta dnd retrocede tu animacion
        if (this._currentframe != 1)
        {
            this.prevFrame();
        }         
        else
        {
            this.stop();
            delete this["onEnterFrame"];
        } // end if
    };
}

Por buffy299

26 de clabLevel



 

msie
Citar            
MensajeEscrito el 03 Ago 2008 09:28 am
me olvidaba...al final agregas el onpress ,,,osea..lo k keres k haga cada btn.

Por buffy299

26 de clabLevel



 

msie
Citar            
MensajeEscrito el 03 Ago 2008 05:40 pm
Muchas gracias me ha ido de fábula. ;)
El boton que he puesto encima ha sido transparente, por si a alguien le ha surgido esta misma duda, basta con poner el boton transparente, de la misma dimension del mc, para que valla perfecto.

Por Shaben

21 de clabLevel



Genero:Masculino  

firefox
Citar            
MensajeEscrito el 03 Ago 2008 10:53 pm
Puedes utilizar tu mismo mc como botón, no tienes que ponerle un boton transparente por encima.

Por elchininet

Claber

3921 de clabLevel

17 tutoriales

Genero:Masculino  

Front-end developer at Booking.com

firefox

 

Cristalab BabyBlue v4 + V4 © 2011 Cristalab
Powered by ClabEngines v4, HTML5, love and ponies.