02.02.2019, 09:37
Hello,
I've been trying to make a script in which a missile is fired whenever a player is holding the KEY_ACTION button.
This missile will be fully automatic, shooting multiple missiles per second if the player is still holding that button.
The script works fine so far. However, OnPlayerKeyStateChange is obviously only called when the keystate of a player changes. Is there any other function to make it so that the function is always called? I've done some searching but I couldn't find anything.
Thanks in advance!
I've been trying to make a script in which a missile is fired whenever a player is holding the KEY_ACTION button.
This missile will be fully automatic, shooting multiple missiles per second if the player is still holding that button.
The script works fine so far. However, OnPlayerKeyStateChange is obviously only called when the keystate of a player changes. Is there any other function to make it so that the function is always called? I've done some searching but I couldn't find anything.
Thanks in advance!