A Flash Developer Resource Site

Results 1 to 9 of 9

Thread: [F8] Flash Rollover Button / masked - HELP!!!!!!!!!!!

  1. #1
    Junior Member
    Join Date
    Jan 2009
    Posts
    5

    Question [F8] Flash Rollover Button / masked - HELP!!!!!!!!!!!

    Basically heres my problem, i'm making a flash advertisment for a school project and i'm trying to make a flash rollover button where when the mosue is rolled over it text flys out from under the button and when the mouse is removed from the button the text retracts back under the button image. can anyone give tell me how to make this? i've linked a picture to try and give an idea of what i mean.


  2. #2
    Space Midget Wrangler
    Join Date
    Sep 2002
    Posts
    129
    a. The text should be masked with the mask only allowing visibility in the spot next to the circle. The text should be within its own movie clip so you can use it like a movie clip.

    b. determine the x position when the text is fully hidden

    c. determine the x position when the text is fully visible

    d. download the Caurina Tweener class.

    e. on rollover a tweener command should be given to tween the text from its starting position to its end position.

    f. on rollout or release outside should check the position of the clip. If the clips x position is greater than its starting closed position, trigger a tween command to pull the text to its start position.
    A little pain never hurt anyone

  3. #3
    Junior Member
    Join Date
    Jan 2009
    Posts
    5
    Sorri to ask dude, but i'm reeli new to flash could you try to explain that in basic terms? i'm finding the instructions you gave me quite confusing :S

  4. #4
    Space Midget Wrangler
    Join Date
    Sep 2002
    Posts
    129
    Hi Cubba,

    The best way to learn some of these things is by doing, so I'll give you an overview, but you'll need to try out these things individually to fully grasp them. To Start

    Masking:
    You draw a shape or use a movie clip on a layer, right click the layer and it will give you the option to set the layer to "mask". Anything masked by that layer will only appear where it intersects that shape or movie.

    Positioning:
    All objects on the screen have an x position(left right) and a y position(up down). The key with your task is to make a movieclip that holds your text layer, then find out what coordinates will get that clip under your mask, and which ones won't. Basically if your text movie is under your mask it will be visible, and if it isn't it will be invisible.

    Caurina Tweener:
    This is a library of functions you can download from google. It will let you script the motion of or an effect on a movieclip. Play with it a bit and you'll see just how useful this little tool can be. An example of a caurina command.

    Tweener.addTween(movieClip,{time,_x,_y});

    So in that command you would specify the time you want your tween to take, the x position to move to and the y position to move to.

    Regards,

    Plasnid
    A little pain never hurt anyone

  5. #5
    Junior Member
    Join Date
    Jan 2009
    Posts
    5
    yeah, i understand that i've gotta get practical to learn the software i just couldn't make sense of how to make a mask... etc. but yer thanx that much easier to understand ty

  6. #6
    Junior Member
    Join Date
    Jan 2009
    Posts
    5

    Unhappy

    Hi plasnid,

    Ok i used the instructions you gave me to the best of my ability, although i've hit a stage where i can't figure out which layer to put in the actionscript, tweener... or what ever you call it or if i've even put this thing together right. i've linked what i've done so far and was wondering if you'd take a look. i'd usually just keep trying at it until something clicked but i've got the deadline for this project approaching pretty fast.. end of the motnh to be exact.

    any input would be great ty

    Link:
    http://www.mediafire.com/?nhjyzzyzhjn

  7. #7
    Space Midget Wrangler
    Join Date
    Sep 2002
    Posts
    129
    I like to be helpful, but it looks like you've not even tried to do the masking yet. At least give the masking a shot. I will even send you links to some tutorials that will show you the way.

    How To Make a mask:
    http://www.webdevelopersnotes.com/tu...l_masking.php3


    How to tween using Tweenlite:
    http://blog.greensock.com/tweenliteas2/

    Read 'em, love 'em! This is completely doable. From the look of your sample, you need to combine your text layer and circle graphic layer into one movie clip, and then make a new layer in that clip and put your script there. You can do this!
    Last edited by plasnid; 01-16-2009 at 05:20 PM.
    A little pain never hurt anyone

  8. #8
    Junior Member
    Join Date
    Jan 2009
    Posts
    5
    Managed to get it done thanks for your help. if i could ask you one more thing. how do i link it to an url becasue i used a slightly diffrent method to making it and its in a MC format?

    i've linked it so you can have a look to see exctly what i've done

    http://www.mediafire.com/file/tcioxz...ex_btn_001.fla

  9. #9
    Space Midget Wrangler
    Join Date
    Sep 2002
    Posts
    129
    When you say you want to link it to a url, what do you mean?

    Are you looking to:

    a. put the button in an html page?

    b. link to a webpage from a click on your button?
    A little pain never hurt anyone

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