A Flash Developer Resource Site

Results 1 to 2 of 2

Thread: Fade Explanation, plz :D

  1. #1
    Junior Member
    Join Date
    Apr 2005
    Posts
    7

    Fade Explanation, plz :D

    Again, Sorry for my bad English

    Hi again, now that the size problem is solved... now I'm stucked in a fade problem

    i found that the code is

    zoommas.onRollOut = function() {
    if (zoommas<=100) {
    zoommas.onEnterFrame = function() {
    zoommas._alpha -= 5;
    };
    }
    };

    well, this for a fade out, but now I have a little problem

    the MC fades in from 50 to 100
    and it is supossed to fade out from whatever to 50, but with the above code it fades out to 0 :|....

    how can I set the final value for the alpha???

    thanks in advance

  2. #2
    Like this:

    code:

    zoommas.onRollOut = function() {
    zoommas.onEnterFrame = function() {
    zoommas._alpha -= 5;
    if(zoommas._alpha<=50){
    zoommas._alpha = 50;
    delete this.onEnterFrame;
    }
    };
    };

    zoommas.onRollOver = function() {
    zoommas.onEnterFrame = function() {
    zoommas._alpha += 5;
    if(zoommas._alpha>=100){
    zoommas._alpha = 100;
    delete this.onEnterFrame;
    }
    };
    };

    stuff and other stuff

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center