arsenic2k How do I cheat? Reputation: 0
Joined: 18 Oct 2022 Posts: 1
|
Posted: Tue Oct 18, 2022 1:53 pm Post subject: getting value from script to table |
|
|
solved: I was typing [fuel] instead of fuel... so now is working
Hi there I have question regarding lua.
what I want is to get the value from [fuel] add to the table list so can be customizable, by default is 30 but if want another default value without editing the script, my idea was to add the [fuel] address to the table and edit the value, but I got it wrong...
I have this code
Code: |
[ENABLE]
aobscanmodule(infFuel,F1Manager22.exe,F3 0F 11 91 54 04 00 00) // should be unique
alloc(newmem,$1000,infFuel)
label(code)
label(return)
alloc(fuel,4)
fuel:
dd (float)30
newmem:
cmp [rcx+00000884],(float)-1
je code
movss xmm2,[fuel]
movss [rcx+00000454],xmm2
jmp return
code:
movss [rcx+00000454],xmm2
jmp return
infFuel:
jmp newmem
nop 3
return:
registersymbol(infFuel)
registersymbol(fuel)
[DISABLE]
infFuel:
db F3 0F 11 91 54 04 00 00
unregistersymbol(infFuel)
unregistersymbol(fuel)
dealloc(newmem)
dealloc(fuel)
{
// ORIGINAL CODE - INJECTION POINT: F1Manager22.exe+1163DC3
F1Manager22.exe+1163DAA: C3 - ret
F1Manager22.exe+1163DAB: CC - int 3
F1Manager22.exe+1163DAC: CC - int 3
F1Manager22.exe+1163DAD: CC - int 3
F1Manager22.exe+1163DAE: CC - int 3
F1Manager22.exe+1163DAF: CC - int 3
F1Manager22.exe+1163DB0: F3 0F 10 91 54 04 00 00 - movss xmm2,[rcx+00000454]
F1Manager22.exe+1163DB8: 0F 57 C0 - xorps xmm0,xmm0
F1Manager22.exe+1163DBB: F3 0F 5C D1 - subss xmm2,xmm1
F1Manager22.exe+1163DBF: F3 0F 5F D0 - maxss xmm2,xmm0
// ---------- INJECTING HERE ----------
F1Manager22.exe+1163DC3: F3 0F 11 91 54 04 00 00 - movss [rcx+00000454],xmm2
// ---------- DONE INJECTING ----------
F1Manager22.exe+1163DCB: F3 0F 11 91 C0 06 00 00 - movss [rcx+000006C0],xmm2
F1Manager22.exe+1163DD3: C3 - ret
F1Manager22.exe+1163DD4: CC - int 3
F1Manager22.exe+1163DD5: CC - int 3
F1Manager22.exe+1163DD6: CC - int 3
F1Manager22.exe+1163DD7: CC - int 3
F1Manager22.exe+1163DD8: CC - int 3
F1Manager22.exe+1163DD9: CC - int 3
F1Manager22.exe+1163DDA: CC - int 3
F1Manager22.exe+1163DDB: CC - int 3
}
|
|
|