so how do you do button press (hard) vs button tap (quick or light)?
the goal is to have a series of fast sword swings if tapping and a heavy swing if you press hard.
I was thinking something like
Update {
if (button1)
set toggle
add timer
if (toggle)
if (button1 == false)
end timer, do action
set toggle = false
}
Action{
if timer > 0.5 seconds doPress
if timer <= 0.5 seconds doTap
}
or something like that, basically checking the button each fram and if its pressed add to a timer, if not skip it, once the button is pushed once, youset a toggle or flag and remove it after the button is let go,. Then checking to see if the timer or counter was incremented past a half second or a quarter second. If you held the button down it would register as Press, if you barely tapped it it would register as a Tap.
Is there any tutorial or example or script for say Fighting game combos? I know you need amove array and a set of sequences you test against. Funky stuff. I was just hoping to have two attacks, a quick light attack and a heavy swing that was slow. Ideally, light tapping rapidly would do a three hit combo, linking from one animation clip to the next. Any clue on how to set this up?