Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Error with collision

Explorer ,
Feb 21, 2015 Feb 21, 2015

I'm having this problem is a period, and I can not solve it by. When the puppet plays in yellow object he's the error shown in the video, trouble follows me and I can not solve it at all.

Once I tried to copy and paste all the objects to the Frame 1 Frame 2, gave no mistake ... However, it is not feasible because the future has enough problems since then, but I have no ideas of what I can do to avoid.

Movie: Dropbox - demo.mp4

I use these EventListener:

[php]addEventListener (Event.ENTER_FRAME, start);

personagem.addEventListener (Event.ENTER_FRAME, enterFrame);[/php]

But I have tried to use:

[php]removeEventListener (Event.ENTER_FRAME, enterFrame);

removeEventListener (Event.ENTER_FRAME, start);[/php]

And unfortunately it did not work, could someone help me?

TOPICS
ActionScript
200
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Feb 21, 2015 Feb 21, 2015

The error message indicates that line 33 of your code on frame 2 is where the problem arises.

The 1009 error indicates that one of the objects being targeted by your code is out of scope.  This could mean that the object....

 

- is declared but not instantiated

- doesn't have an instance name (or the instance name is mispelled)

- does not exist in the frame where that code is trying to talk to it

- is animated into place but is not assigned instance names in every keyframe for it

- is one of two or m

...
Translate
LEGEND ,
Feb 21, 2015 Feb 21, 2015
LATEST

The error message indicates that line 33 of your code on frame 2 is where the problem arises.

The 1009 error indicates that one of the objects being targeted by your code is out of scope.  This could mean that the object....

 

- is declared but not instantiated

- doesn't have an instance name (or the instance name is mispelled)

- does not exist in the frame where that code is trying to talk to it

- is animated into place but is not assigned instance names in every keyframe for it

- is one of two or more consecutive keyframes of the same objects with no name assigned in the preceding frame(s).

For the code you show, if you assign an event listener to a particular object then you need to remove the event listener from that object.  Your code does not do that for... personagem.addEventListener (Event.ENTER_FRAME, enterFrame);

removeEventListener (Event.ENTER_FRAME, enterFrame); should be

personagem.removeEventListener (Event.ENTER_FRAME, enterFrame);

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines