onEnterFrame???

Out of context: Reply #1

  • Started
  • Last post
  • 2 Responses
  • unknown0

    set id vars for each menu behavior so you can ask onEnterFrame if that variable is true then do the thing otherwise nothing. That way you will release the CPU from onEnterFrame running constantly. Let me show you an example how I do it in some cases:

    process=false; (place this somewhere on the frame actions)

    onClipEvent(enterFrame){
    if(process){
    ..do something until it's done
    }
    }

    this means that let's say you have a button and when you click on it you set process var to true, in that case onClipEvent will start looping...this is good because you can change the process var when those onClipEvent actions are actually finished back to false and onEnterFrame will stop working..

    I hope this helped.

    Cheers.

View thread