Rabidxotaku How do I cheat? Reputation: 0
Joined: 19 Jul 2015 Posts: 1
|
Posted: Sun Jul 19, 2015 7:23 pm Post subject: Question - Putting Pointers into trainer |
|
|
So essentially I have been using buttons to inject scripts into Terraria, not all are mine and in finished trainer I will of course credit where credit is due, but as of right now I have a question
This is the method I have been using and on further thought this is a toggle not a button :p
Code: | function CEToggleBox2Change(sender)
if (checkbox_getState(UDF1.CEToggleBox2) == 1) then
autoAssemble([[
aobscan(RevertDamage,29 82 18 03 00 00 83 7D) // should be unique
alloc(newmem,$1000)
label(code)
label(return)
newmem:
code:
add [edx+00000318],eax
jmp return
RevertDamage:
jmp code
nop
return:
registersymbol(RevertDamage)
]])
else
autoAssemble([[
RevertDamage:
db 29 82 18 03 00 00
unregistersymbol(RevertDamage)
dealloc(newmem)
]])
end
end
function CEToggleBox3Change(sender)
if (checkbox_getState(UDF1.CEToggleBox3) == 1) then
autoAssemble([[
aobscan(RevertMana,29 82 1C 03 00 00 E9) // should be unique
alloc(newmem,$1000)
label(code)
label(return)
newmem:
code:
add [edx+0000031C],eax
jmp return
RevertMana:
jmp code
nop
return:
registersymbol(RevertMana)
]])
else
autoAssemble([[
RevertMana:
db 29 82 1C 03 00 00
unregistersymbol(RevertMana)
dealloc(newmem)
]])
end
end
|
Anyways!
I have this script there
Code: | [ENABLE]
//define(timer, Terraria.Main::Draw+22db)
define(timer, Terraria.Main::Draw+23e0)
assert(timer, ?? ?? ?? ?? d9 05 ?? ?? ?? ?? df f1)
label(timer_aob)
registersymbol(timer_aob)
timer:
timer_aob:
[DISABLE]
|
Which grabs the address for all global events and then uses that address and applies the offset to get the values and then the values (which are already put in under neath the parent script (up above), I am wondering how I could implement this in a trainer, maybe a button for an auto run functions for the value getters? I have other scripts that also act the same general way. I am just at a lose of what I should do.
|
|