Skip to main content
Participant
September 4, 2017
Question

Help a dummie out- scenes

  • September 4, 2017
  • 2 replies
  • 306 views

Hi,

I am very new to Animate and get given an error to this:

button1.addEventListener(MouseEvent.CLICK, fl_ClickToGoToScene);

function fl_ClickToGoToScene(event:MouseEvent):void

{

MovieClip(this.root).gotoAndPlay(1, "Scène 3");

}

stop();

Error: 1021 duplicate function definition.

Hoping someone more skilled will be able to tell me what to do Thanks in advance

This topic has been closed for replies.

2 replies

Colin Holgate
Inspiring
September 4, 2017

In your Publish Settings is an option to Allow Debugging. Check that box, then the error should tell you what line to look for to fix the problem.

robdillon
Participating Frequently
September 4, 2017

That error is telling you that you have more than one function named fl_ClickToGoToScene() in your movie file. Each function has to have a unique name. So, if you are using this code snippet more than once in your movie, then you should append something to the name to make it unique. You could append a number like: fl_ClickToGoToScene1() for instance.