A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: removing enterframes

  1. #1
    Member
    Join Date
    Nov 2005
    Posts
    75

    Question removing enterframes

    i have this evenetListener:
    Code:
    addEventListener(Event.ENTER_FRAME, findPath);
    and inside of findPath i have a condition which if its satisfied, i want it to stop the enterframe. how do i do that?

  2. #2
    Ө_ө sleepy mod
    Join Date
    Mar 2003
    Location
    Oregon, USA
    Posts
    2,441
    removeEventListener(Event.ENTER_FRAME, findPath);

  3. #3
    Ө_ө sleepy mod
    Join Date
    Mar 2003
    Location
    Oregon, USA
    Posts
    2,441
    Alternately you can use this to clear any eventlistener regardless of the object it's attached to - super useful for anonymous functions!

    e.target.removeEventListener(e.type, arguments.callee);

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