Activating the script with the key [help]

K

krul

Expert Cheater
Joined
Jan 30, 2018
Messages
111
I would like to activate the script in-game with a single key.
Default one is Ctrl. How can I change to load it with Q key?
How does CE recognize keyboard keys?

I have found this https://cheatengine.org/keypresstut.php
How do I create hold Q key instead of Ctrl?
Virtual key code of Q is 81. But if I change the line push 81 / /Q nothing happens in the game.
Code:
pushad
push 11 //Ctrl
call GetAsyncKeyState
shr ax,#15
cmp ax,1
popad
jne originalcode
fstp st(0)
fldz
 
TheyCallMeTim13

TheyCallMeTim13

Enchanter
Staff member
Administrator
Fearless Donors
Talents
Joined
Mar 3, 2017
Messages
1,794
krul said:
I would like to activate the script in-game with a single key.
Default one is Ctrl. How can I change to load it with Q key?
How does CE recognize keyboard keys?

I have found this https://cheatengine.org/keypresstut.php
How do I create hold Q key instead of Ctrl?
Virtual key code of Q is 81. But if I change the line push 81 / /Q nothing happens in the game.
Code:
pushad
push 11 //Ctrl
call GetAsyncKeyState
shr ax,#15
cmp ax,1
popad
jne originalcode
fstp st(0)
fldz
This isn't Lua it's ASM, so it needs to be injected into the game's code somewhere.
Topic moved to appropriate area.
 
Top