View previous topic :: View next topic |
Author |
Message |
eigocc Newbie cheater Reputation: 0
Joined: 22 Dec 2018 Posts: 15
|
Posted: Fri May 17, 2019 12:07 am Post subject: Trainer was cracked |
|
|
After the packaged exe program runs, you can see the CT table in memory, so you can extract it directly and re-modify it, and then package it again. Is there any way to delete the text data of the CT table after the program runs?
Description: |
|
Filesize: |
118.38 KB |
Viewed: |
1727 Time(s) |
|
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 457
Joined: 09 May 2003 Posts: 25262 Location: The netherlands
|
Posted: Fri May 17, 2019 12:16 am Post subject: |
|
|
try encodeFunction/decodeFunction for the luascript part
Code: |
local r=messageDialog('Have you made a backup of your script?',mtWarning,mbYes,mbNo)
if r==mrYes then
if LuaScriptForm==nil then
for i=1,getFormCount()-1 do
local f=getForm(i)
if f.ClassName=='TfrmAutoInject' then
if f.ScriptMode=='smLua' then
LuaScriptForm=f
end
end
end
end
if LuaScriptForm then
local script=LuaScriptForm.assemblescreen.Lines.Text
local newscript='decodeFunction("'..encodeFunction(loadstring(script))..'")()'
LuaScriptForm.assemblescreen.Lines.Text=newscript
else
print("Nope")
end
else
showMessage("Then first make one as your script will be unreadable after this")
end
|
(And perhaps your own version of lua where you randomize the opcode values)
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.
Like my help? Join me on Patreon so i can keep helping |
|
Back to top |
|
|
eigocc Newbie cheater Reputation: 0
Joined: 22 Dec 2018 Posts: 15
|
Posted: Fri May 17, 2019 1:06 am Post subject: |
|
|
I won't use this code. Can you explain it more clearly? Thank you!
Description: |
|
Filesize: |
58.27 KB |
Viewed: |
1710 Time(s) |
|
Description: |
|
Filesize: |
268.95 KB |
Viewed: |
1710 Time(s) |
|
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 457
Joined: 09 May 2003 Posts: 25262 Location: The netherlands
|
Posted: Fri May 17, 2019 1:18 am Post subject: |
|
|
EncodeFunction(loadstring()) encodes the text into lua bytecode and converts that to text
DecodeFunction takes that text and converts it back to bytecode in the form of a function.
the () at the end will execute the function it returns.
But what was the script currently inside the luascript of the table ?
And don't run the code I posted in there, but run it inside a lua engine window instead
and try this code:
Code: |
local r=messageDialog('Have you made a backup of your script?',mtWarning,mbYes,mbNo)
if r==mrYes then
if LuaScriptForm==nil then
for i=1,getFormCount()-1 do
local f=getForm(i)
if f.ClassName=='TfrmAutoInject' then
if f.ScriptMode=='smLua' then
LuaScriptForm=f
end
end
end
end
if LuaScriptForm then
local script=LuaScriptForm.assemblescreen.Lines.Text
local newscript=[[
r=decodeFunction("]]..encodeFunction(loadstring(script))..[[")
if type(r)=='function' then
r()
else
print(type(r))
if type(r)=='string' then
print("decodeFunction returned a string:"..r)
end
end
]]
LuaScriptForm.assemblescreen.Lines.Text=newscript
else
print("Nope")
end
else
showMessage("Then first make one as your script will be unreadable after this")
end
|
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.
Like my help? Join me on Patreon so i can keep helping
Last edited by Dark Byte on Fri May 17, 2019 1:30 am; edited 1 time in total |
|
Back to top |
|
|
eigocc Newbie cheater Reputation: 0
Joined: 22 Dec 2018 Posts: 15
|
Posted: Fri May 17, 2019 1:29 am Post subject: |
|
|
Thank you very much, Dark Byte. I have already figured it out, thank you for your answer!
|
|
Back to top |
|
|
|