A Flash Developer Resource Site

Results 1 to 4 of 4

Thread: MC plays on rollOver

  1. #1
    Senior Member Ingale's Avatar
    Join Date
    Jun 2003
    Posts
    332

    MC plays on rollOver

    Hi all!
    I have a MC on stage, which I'd like to play when the moues rolls over some button, to disappear when the mouse rolls out etc... So I have an empty first frame in the MC with stop() AS on it and a stop() AS on the last keyframe. The button has the following AS:
    code:
    on (rollOver) {
    gotoAndPlay("_root.NewSuzukiMC", 2);
    }
    on (rollOut) {
    gotoAndPlay("_root.NewSuzukiMC", 1);
    }


    NewSuzukiMC is the instant name of the MC.
    From some reason it doesn't work, the MC not playing... Any ideas how to fix it? How to make it play on roll over and disappear on roll out?
    Thanks in advance!

    Sometimes the most simple things are the most effective...

  2. #2
    ReMember jennyj's Avatar
    Join Date
    Feb 2003
    Location
    UK
    Posts
    549
    try changing it to this
    Code:
    on (rollOver) {
       _root.NewSuzukiMC.gotoAndPlay(2);
    }
    JennyJ

  3. #3
    Senior Member Ingale's Avatar
    Join Date
    Jun 2003
    Posts
    332
    That seems to be working!
    Thank you for your help!

    Sometimes the most simple things are the most effective...

  4. #4
    Banned
    Join Date
    Apr 2001
    Location
    Montréal, Québec.
    Posts
    25,397
    You should use gotoAndStop rather than gotoAndPlay, or nextFrame() & prevFrame().

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