With this snippet you can block Keyboard and mouse.
Example
Snippet
Example
PHP:
{$CLEO .cs}
0000:
wait 8500
while true
wait 0
if and
0@ == false
044B: actor $PLAYER_ACTOR on_foot
then
0AB1: @BlockInput 1 status 1 // 1 - block keyboard and mouse
if
32@ > 30000 // if 30sec passed then...
then
0@ = true
0AB1: @BlockInput 1 status 0 // 0 - turn off blocking.
32@ = 0
end
end
end
:BlockInput
0AA2: 10@ = load_library "User32.DLL"
0AA4: 11@ = get_proc_address "BlockInput" library 10@
0AA7: call_function 11@ num_params 1 pop 0 0@ 25@
0AA3: free_library 10@
0AB2: ret 0
Snippet
PHP:
0AB1: @BlockInput 1 status 1 // 1 - block keyboard and mouse , 0 - turn off blocking
PHP:
:BlockInput
0AA2: 10@ = load_library "User32.DLL"
0AA4: 11@ = get_proc_address "BlockInput" library 10@
0AA7: call_function 11@ num_params 1 pop 0 0@ 25@
0AA3: free_library 10@
0AB2: ret 0
Last edited: