2 Replies Latest reply on Aug 3, 2011 2:18 PM by jack77766

    best method to stop game and make a 3,2,1 countdown on screen?




      Was wondering if I wanted to stop my game so that no input and all ai action seized what the best way to do it is, is there a way besides stop every listener and every timer and ai event?


      Also I want to kind of make a big 3,2,1 countdown appear in the middle of the screen, what is the best way to do that?? make the symbols and then going visible->invisible for each?



        • 1. Re: best method to stop game and make a 3,2,1 countdown on screen?
          Ned Murphy Adobe Community Professional & MVP

          One way you could probably weave in to stop everything in one shot is to have a boolean variable that you set true/false that is used for every event handler function or other function that might be activated.  Meaning the first line inside a function is a conditional to test the value of that boolean... that conditional being the gateway to the rest of the code.  But if you intend to truly shut down the works, then stopping all listeners and processing piece by piece would be your safest bet.


          There are a varety of ways you could do a countdown. Just using a textfield might suffice.  Or maybe you want something more graphical where a movieclip changes frames or something.  There really are too many options for you to need to ask... just think what you'd like to see and do it.

          1 person found this helpful