For example, let say that there is an Attack Button.
If the player make
a slight tap [ immediately release after press ], then the Player will do Light Attack
a long tap [ hold for a bit then release ], then the Player will do Heavy Attack
a hold [ Not release after a certain amount of time ], then the Player will do Charging
I understand that this can be achieve by
timer++ during Update()
and
timer = 0 when buttonUp()
What I would like to know is,
Is there any Unity Input function that detect how long the button was pressed,
instead of coding a separate timer?