I want to make an One Hit Kill script for a game, and i want to use my health address to differentiate myself from the others
But when i try to compare My Health Address with Target Health Address, game crash.
This is my script:
Code: Select all
[ENABLE]
aobscanmodule(OHK,GameAssembly.dll,C4 08 89 48 18 5D C3) // should be unique
alloc(newmem,$1000)
label(origin)
label(return)
label(_ohk)
label(_p_Heal)
label(target)
newmem:
// Get my Health Address
push edx
lea edx,[[_pHealth]+18] // "_pHealth" its Player Base Address and 0x18 its the Health offset
mov [_p_Heal],edx
pop edx
// Get others Health Address
push edx
mov edx,eax
lea edx,[edx+18] // "edx+18" its others health address
mov [target],edx
pop edx
cmp target,_p_Heal // Here its the problem, when i compare these 2, game crashes
jne _ohk
mov [eax+18],ecx
pop ebp
ret
jmp return
_ohk:
mov [eax+18],00
pop ebp
ret
jmp return
origin:
mov [eax+18],ecx
pop ebp
ret
jmp return
_p_Heal:
dq 0
target:
dq 0
OHK+02:
jmp newmem
return:
registersymbol(OHK _p_Heal target)
[DISABLE]
OHK+02:
db 89 48 18 5D C3
unregistersymbol(OHK _p_Heal target)
dealloc(newmem)