How does GetKey differ from GetKeyDown?
if (Input.GetKey(KeyCode.W)) MoveForward();
- True every held frame
- True on release only
- True once per press
- True after a delay
GetKey reports the key is down each frame it is held; GetKeyDown fires only on the press frame.
Play Game Dev ▸