View previous topic :: View next topic |
Author |
Message |
handlingcfg How do I cheat?
Reputation: 0
Joined: 01 Sep 2019 Posts: 8
|
Posted: Fri Nov 26, 2021 12:31 pm Post subject: is entering arbitrary number possible with hotkeys? |
|
|
hi what im looking for press a combination of keys + numbers to enter desired number to variable inside code,
example lets say ctrl+alt is hotkey, and while im pressing these, i press 5-3-3-9-9-1 than my variable would be 53.991 without exited fullscreen
i can make a assembly code for smiliar to this
first declare a variable and add 10 keys for numbers
secondly, another variable and hotkey to add number to total number
thirdly another, another variable, hotkey for set multiple total number variable by 10
but it takes too many keypresses and sonetimes hotkeys would be active multiple times on single press,
second problem about this approach, code must runs between each hotkey press, for some codes its not possible.
is there another way with lua or else?
Last edited by handlingcfg on Sat Nov 27, 2021 8:55 pm; edited 1 time in total |
|
Back to top |
|
 |
Csimbi I post too much
Reputation: 97
Joined: 14 Jul 2007 Posts: 3322
|
Posted: Fri Nov 26, 2021 4:53 pm Post subject: |
|
|
I guess I would try GetAsyncKeyState(...).
At some point I complained to Dark Byte that I'd need more hotkeys for speedhack than just the default 5.
He told me there's a way to extend the built-in hotkeys, but I never took the time to research it.
|
|
Back to top |
|
 |
Dark Byte Site Admin
Reputation: 470
Joined: 09 May 2003 Posts: 25791 Location: The netherlands
|
Posted: Sat Nov 27, 2021 1:35 am Post subject: |
|
|
yes, use a hotkey looking for ctrl+alt and once triggered start a new thread in which you do a almost constant loop checking isKeyDown for 0 to 9
then after getting 5 keys handle the value and quit the thread
maybe use speak() to let the user know the key got handled
and add a delay after handling a key (e.g imagine how to type 10000)
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.
Like my help? Join me on Patreon so i can keep helping |
|
Back to top |
|
 |
|