the rose Newbie cheater Reputation: 0
Joined: 28 Mar 2012 Posts: 19
|
Posted: Sat Nov 24, 2012 2:39 pm Post subject: help for exchange aob in lua scripit (backup also) |
|
|
need to change this aob :01 02 03 04 04 05 07 08
for this : 01 02 03 04 10 10 12 13
My script below is changing, I'm having problems with backup...
function replaceAOB3()
r=AOBScan("01 02 03 04 05 06 07 08")
if (r~=nil) then
c=strings_getCount(r)
if (c>0) then
resultlist3=nil
resultlist3={}
for i=0,c-1 do
a=strings_getString(r,i);
resultlist3[i+1]={}
resultlist3[i+1][1]=a
resultlist3[i+1][2]=readBytes(a, 8, true)
for j=4,5 do
writeBytes(tonumber("0x"..a)+j, 10)
end
for j=6,6 do
writeBytes(tonumber("0x"..a)+j, 12)
end
for j=7,7 do
writeBytes(tonumber("0x"..a)+j, 13)
end
end
else
print("No results");
end
else
print("Scan error")
end
end
function restoreAOB3()
for i=1,#resultlist3 do
local a=tonumber("0x"..resultlist3[i][1])
local orig=resultlist3[i][2];
for j=4,8 do
writeBytes(a+j,orig[j])
end
end
end
can someone pass me a simpler way?
thank you
|
|