A
A
Alexander2021-05-06 00:09:08
C++ / C#
Alexander, 2021-05-06 00:09:08

How to set different actions when clicking on the same button?

How (in Unity) to implement this: QUICKLY press the left mouse button and the character in the game performs an action (eg jump), press the left mouse button again but LONGER and the character performs another action (eg long jump)?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
C
cicatrix, 2021-05-06
@cicatrix

ButtonDown() 1 ) start
the timer for n milliseconds
2) perform a jump

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question