Just need a little help with a very simple script. Thanks!
Posted: Sat Feb 22, 2020 6:53 am
So I have this script, which is just two combined scripts here:
So its just creating two symbols I can use as pointers in the table to edit a couple of values. Thing is, when the scripts are used separately the two addresses display fine but combined like here only the [right_light] symbol displays the address and the [mounts] symbol displays a long gibberish address. I know both symbols use RAX, but I don't understand the issue as they are at completely different sections of code.
This has happened to me before and I would really like to know how to fix this script so I can do such things in the future. I have several more symbols I need to add to this same script. As it is I'll have to have separate scripts for each one :/ Thanks!
Code: Select all
aobscanmodule(front_mount_drydockone,StarpointGemini2.exe,44 8B 70 1C E9 7D 00 00 00) // should be unique
alloc(newmem,$1000,"StarpointGemini2.exe"+174719)
aobscanmodule(drydock_mount_light_right,StarpointGemini2.exe,9A EA FF 40 32 F6 44 8B 70 1C E9 7E 00 00 00) // should be unique
alloc(newmem1,$1000,"StarpointGemini2.exe"+1748B8)
label(code)
label(return)
alloc(mounts,4)
registersymbol(mounts)
label(code1)
label(return1)
alloc(right_light,4)
registersymbol(right_light)
newmem:
code:
mov [mounts],rax
mov r14d,[rax+1C]
jmp StarpointGemini2.exe+17479F
jmp return
newmem1:
code1:
mov [right_light],rax
mov r14d,[rax+1C]
jmp StarpointGemini2.exe+17493F
jmp return1
front_mount_drydockone:
jmp newmem
nop 4
return:
registersymbol(front_mount_drydockone)
drydock_mount_light_right+06:
jmp newmem1
nop 4
return1:
registersymbol(drydock_mount_light_right)
[DISABLE]
front_mount_drydockone:
db 44 8B 70 1C E9 7D 00 00 00
drydock_mount_light_right+06:
db 44 8B 70 1C E9 7E 00 00 00
unregistersymbol(front_mount_drydockone)
dealloc(newmem)
dealloc(mounts,4)
unregistersymbol(mounts)
unregistersymbol(drydock_mount_light_right)
dealloc(newmem1)
dealloc(right_light,4)
unregistersymbol(right_light)
This has happened to me before and I would really like to know how to fix this script so I can do such things in the future. I have several more symbols I need to add to this same script. As it is I'll have to have separate scripts for each one :/ Thanks!