Fri Apr 23, 2021 12:53 pm
I have a bank script in a map and it is really slow having to press a key 100 times to give or take $100 so I'm asking that a new keyword be made so that a key will repeat quickly after being pressed for a second or two.
Sat Apr 24, 2021 10:56 am
You can easily do this yourself with a keybind that triggers on both key press and release.
alias +MyKey "netevent \"MyKey:Pressed\""
alias -MyKey "netevent \"MyKey:Released\""
// Make the keybind for "+MyKey"
Then you handle the repeating from your own code by setting a bool and starting a counter once the key is pressed - then you just execute the action every time a certain amount of time has passed according to the timer.
Sun Apr 25, 2021 9:47 am
I think I understand what you mean but I can't make any sense of this code you posted
Tue Apr 27, 2021 4:15 pm
Sounds like the best solution is to edit the script so you've got an option for taking out $1 per press, or a larger amount per press, or hold to take out $1 each tic that the engine notices that the button is being pressed.
Thu Apr 29, 2021 4:32 pm
I have the solution to this problem! Check this thread:https://forum.zdoom.org/viewtopic.php?f=122&t=72110
Powered by phpBB © phpBB Group.
phpBB Mobile / SEO by Artodia.