dcsimg
A Flash Developer Resource Site

Results 1 to 12 of 12

Thread: Simple actionscript and buttons

  1. #1
    Member
    Join Date
    Aug 2002
    Posts
    44

    Simple actionscript and buttons

    I have a on (rollOut){} action on a button. In this button, on the 'OVER' keyframe, I have a movie. This movie is text that is animated and has a stop(); action for frame1. The animation is called About_Us_Anim. On frame 30, it has another stop command. From frame 30 to 36, it fades out to the original position.

    Here is my delimma

    I need the fade-out to happen when the mouse rolls off the botton. How can I use an actionscript to tell About_Us_Anim to play(); frame 31++? from the main button named About_Us?

    I also have About_Us (button) telling this.anim1.play(); on rollOver();. When the mouse rolls off the button -- rollOut(){ }; how can I tell Anim1 to go to frame ## and play from there?

    2 diff questions -- same problem.

    Any help is appreciated.
    --Will
    What we do in our spare time:
    Free IPOD 0/5 3 pending:
    http://www.digitalcup.net/ipod/
    Free Flatscreen 0/8 0 pending:
    http://www.digitalcup.net/monitor/

  2. #2
    Banned
    Join Date
    Apr 2001
    Location
    Montréal, Québec.
    Posts
    25,397

  3. #3
    Member
    Join Date
    Aug 2002
    Posts
    44
    Thanks for the visual -- is there a way you can explain how you achieved it using your source code? IE -- why the sprite, button, and how your code works together (where it is placed, etc)

    onClipEvent (enterFrame)
    {
    if (this.hitTest(_root._xmouse, _root._ymouse, true))
    {
    if (_root.fade._currentframe < _root.fade._totalframes)
    ...

    function reverseMe()
    {
    _root.fade.onEnterFrame = function ()
    {
    if (_root.fade._currentframe < 1)
    {
    _root.fade.gotoAndStop(_root.fade
    ...


    I omitted most of the code, for your pleasure of course

    Thanks,
    What we do in our spare time:
    Free IPOD 0/5 3 pending:
    http://www.digitalcup.net/ipod/
    Free Flatscreen 0/8 0 pending:
    http://www.digitalcup.net/monitor/

  4. #4
    Huygens to Titan PCRIDE's Avatar
    Join Date
    May 2002
    Location
    PLUTO
    Posts
    1,335
    OLD newbie, thats what I am trying to do , your link above, how do you attach an get URL to a menu button that does just as yours does.


    see other post ASAP button MC

    THnaks
    PCRIDE

  5. #5
    Banned
    Join Date
    Apr 2001
    Location
    Montréal, Québec.
    Posts
    25,397
    Have a look at this...
    Attached Files Attached Files

  6. #6
    Huygens to Titan PCRIDE's Avatar
    Join Date
    May 2002
    Location
    PLUTO
    Posts
    1,335
    can you look at my fla on the ASAP post , yours is way differant thatn mine, basiclly I want to attach a get url to my menu buttons, when I put it here or there, the MC effect doesn't work

    PCRIDE

  7. #7
    Banned
    Join Date
    Apr 2001
    Location
    Montréal, Québec.
    Posts
    25,397
    I will... Why 200 frames?

  8. #8
    Huygens to Titan PCRIDE's Avatar
    Join Date
    May 2002
    Location
    PLUTO
    Posts
    1,335
    I don't know, I can delet them I guess,

  9. #9
    Banned
    Join Date
    Apr 2001
    Location
    Montréal, Québec.
    Posts
    25,397
    Ok! Think I got it to work! But going to hit the sack! Will clean it up & post the .fla in the morning!

  10. #10
    Huygens to Titan PCRIDE's Avatar
    Join Date
    May 2002
    Location
    PLUTO
    Posts
    1,335
    k when you up, send it my way, thanks


    PCRIDE

  11. #11
    Banned
    Join Date
    Apr 2001
    Location
    Montréal, Québec.
    Posts
    25,397
    Wouldn't want to frustrate Computer Dork by doing so!

  12. #12
    Huygens to Titan PCRIDE's Avatar
    Join Date
    May 2002
    Location
    PLUTO
    Posts
    1,335
    what do you mean, whatever dude! It looks like your outa here in 7 more post!, don't waste one on this reply.

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