Goten How do I cheat? Reputation: 0
Joined: 23 Mar 2015 Posts: 1
|
Posted: Mon Mar 23, 2015 2:11 pm Post subject: Someone help me with my project? |
|
|
Someone help me with code lua:
Aobscan(_aob1, ?? 00 00 00 00 00 F0 BF ?? ?? ?? ?? ?? ?? ?? ?? 9A)
_aob1:
db 00 00 00 00 00 74 42 42
]])
end
hkey=createHotkey("doscript4",VK_9)
function replaceAOB3()
r=AOBScan("00 00 00 00 00 74 42 42")
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, 11, true)
end
end
end
end
function restoreAOB3()
for i=1,#resultlist3 do
local a=tonumber("0x"
resultlist3[i][1])
local orig=resultlist3[i][2];
for j=0,11 do
writeBytes(a+j,orig[j])
end
end
end
function activatetick(mr, before, currentstate)
if (before==false) and (currentstate==true) then
replaceAOB3()
end
return true
end
hkey=createHotkey("replaceAOB3",VK_9)
function deactivatetick(mr, before, currentstate)
if (before==false) and (currentstate==false) then
restoreAOB3()
end
return true
end
hkey=createHotkey("restoreAOB3",VK_SPACE)
al=getAddressList()
mr=addresslist_getMemoryRecord(al,0);
memoryrecord_onActivate(mr,activatetick)
memoryrecord_onDeactivate(mr,deactivatetick)
Whenever I try to use the error does not know why.
_________________
Creation hack for games. |
|
Zanzer I post too much Reputation: 126
Joined: 09 Jun 2013 Posts: 3278
|
Posted: Mon Mar 23, 2015 7:42 pm Post subject: |
|
|
Edit your post and surround everything with [ code ] tags.
Also, post the error you're getting.
Skimming through it, I believe you're using tonumber incorrectly.
Should be tonumber(resultlist3[i][1],16) assuming that holds a hex string representation.
|
|