3 Replies Latest reply on Jul 20, 2006 10:17 AM by aniebel

    who's got a spare minute to help a beginner ?

    Behtar
      have practised drawing, anaimations, tweening, masking etc etc. Now in actionscsript do understand play, stop and goto. presently trying to make an animation which includes closing and opening of gate on pressing of "Open" and "close" buttons.
      I want that as soon as I press the open or close button, the gate starts opening or closing irrelevant of present gate position
        • 1. Re: who's got a spare minute to help a beginner ?
          aniebel Level 2
          What you can do is create a movie clip of the gate and in the time line for that mc.On the first frame, you can set the gate as it's default state (open, closed or whatever) and put a stop();. In frame 2, label that frame "open" then make your open animation. At the end of that animation, put a stop(); In another frame somewhere afterwards, put another label for "open" then make your open animation with a stop(); at the end as above.

          Place an instance of the mc on the stage and give it an instance name.. say... "gate_mc". Then place your button instances on the stage. IF they are mc buttons, you can use the code below. Let's say their instance names are "openBtn_mc" and closeBtn_mc".

          Then, make a new layer at the top and name it "actions" and lock that layer. This will prevent anything being placed on that layer mistakenly. In the first frame put this code:
          • 2. Re: who's got a spare minute to help a beginner ?
            Behtar Level 1
            Thanks dear
            its great you told me that. going to try it now. thanks again
            • 3. Re: who's got a spare minute to help a beginner ?
              aniebel Level 2
              You're welcome. Let me know if it works.