1.)
In this tutorial I will show you how to disable a button
hold action, so when you hold a button, no matter how
long you hold it, the action will only be executed once..
-----------------------
-----------------------
2.)
In this tutorial You need the following:
-Timeline
Panel
-Actions Panel
-A symbol to work inside of
3.)
OK
So I will just start right away by telling you to open
up your symbol, and by giving it 3 keyFrames. Because
in a button tap action, there is actually 3 steps taking
place. The unexecuted with no press, the executed with
a press, and the unexecuted when it is being held down.
Then on the first key frame, put a variable on inside
button on the first keyframe saying that this is button
press stage 1, and I want it to stop here, until an
action is met.
Button Press Stage 1 is, when No Key has been pressed
yet.
-----------------------
-----------------------
4.)
Then
on the second Key frame you are going to put button
press stage of 2 as a variable. This Frame is when the
button has been pressed. Also put what action you want
to happen when the button has been pressed..
-----------------------
-----------------------
5.)
Then on the 3rd keyframe,
you give the variable a stage of 3, because thats when
the button is held down, and the action was already
executed. If the action was exectuted and the button
is still being held down, you will want your button
to stay at this stage, until the key has been unpressed
.
-----------------------
-----------------------
6.)
Then when you go back
outside of that symbol, you put this code.
This code says:
when the button is pressed (in this case the spacebar),
play through all the button stages in this movie clip
how ever if no button is pressed then go to the first
button stage inside this movieclip Then the 2nd if statement
says, if its on the 3rd stage stay at the frame with
the 3rd stage and remember at the 3rd stage no command
is being executed. It will stay at this stage until
the key has been lifted up .