How can we goto next Scene by giving code on a button inside
a movie clip.

in short.
=>Scene 1.
====>MovieClip
======>Button [ on(release) { gotoAndPlay("Scene 2", 1); } ]

=>Scene 2.

This thing is not working. Please tell me the answer of how
to goto next scene from this scene 1.





Answers were Sorted based on User's Feedback



How can we goto next Scene by giving code on a button inside a movie clip. in short. =>Scen..

Answer / guest

HI guy i domt know as2 .

In as3 just use
MovieClip(root).movieclip.button.addEventListener(MouseEvent.CLICK,function(e:Event){
})

Is This Answer Correct ?    6 Yes 3 No

How can we goto next Scene by giving code on a button inside a movie clip. in short. =>Scen..

Answer / dinesh anand

Hi
In scene2 Timeline Fix a label named "scene2PLAY"
Then Copy and Past the below code in ur button
on(Release){
_root.gotoAndPlay("scene2PLAY")
}

Is This Answer Correct ?    2 Yes 2 No

How can we goto next Scene by giving code on a button inside a movie clip. in short. =>Scen..

Answer / samuel jackson

Try to write this code on different layers don't write code on button itself as MovieClip loader doesn't undestand the instance name for different scenes.for eg.
Scene 1 ---> Layer 1 ----> create a movie clip name = mc1
Layer 2 ----> write this code:
stop();
mc1.onRelease = function() {
gotoAndStop("Scene 2",1);
}
the code which you had mentioned is applicable for buttons not for movie clips.

Is This Answer Correct ?    3 Yes 4 No

How can we goto next Scene by giving code on a button inside a movie clip. in short. =>Scen..

Answer / anilreddykalluri

Button.addEventListener(MouseEvent.CLICK,function Name);
function Function Name(e.MouseEvent)
{
gotoAndStop(Scene2);
}

Is This Answer Correct ?    1 Yes 2 No

Post New Answer

More Flash Action Scripting Interview Questions

How to add event listeners in mxml components. Name the as3 components?

0 Answers  


which actionscript classes are used to play flv formatted video? : Adobe flash

0 Answers  


Is it possible to create document or folder from flash? if yes then how?

6 Answers  


what should be inferred by a variable named birthplace_str? : Adobe flash

0 Answers  


what are the statements uses proper for loop syntax? : Adobe flash

0 Answers  






How many menus will you find on the menu bar?

0 Answers  


what are the statements best describes an event handler? : Adobe flash

0 Answers  


what are the properties can be used to control the order in which the user can tab through the elements in a flash movie? : Adobe flash

0 Answers  


How to create scrolling gallery in portfolio?

0 Answers  


Tell me what is the main purpose of actionscript?

0 Answers  


which of the following is not a typical host application for the flash player? : Adobe flash

0 Answers  


which of the following is not a result of exporting a movie for a debug build? : Adobe flash

0 Answers  


Categories