View previous topic :: View next topic |
Author |
Message |
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Fri May 04, 2012 12:00 am Post subject: AOBScan with variable like registersymbol? |
|
|
Hi.
Is it possible to use AOBScan with a variable from other cheat like registersymbol?
For example:
Code: | AOBScan(aobMoney,01 02 03 ff ab cd ef AND variable(MySymbol,4 Byte) AND 04 05 06 07 08) |
Greez,
Gunny
|
|
Back to top |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Sat Jun 23, 2012 1:04 pm Post subject: |
|
|
Hi.
Is it possible with the new "luafunction()" function?
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25291 Location: The netherlands
|
Posted: Sat Jun 23, 2012 1:13 pm Post subject: |
|
|
Sure, just use lua to build up the string to scan for
_________________
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 |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Sat Jun 23, 2012 1:52 pm Post subject: |
|
|
Hi.
Thank you for your answer.
Can you please give me a small example how to use it in a aa table?
EDIT:
Is this right?
Code: | [ENABLE]
Label(money)
luafunction(_SymbolAODScan(MyMoneySymbol))
AOBMoney:
Money:
dd (int)10000
[DISABLE]
#################################
Function _SymbolAODScan(MySymbol)
MyAOBString = "01 02 03 ff ab cd ef "..MySymbol.." 04 05 06 07 08"
AOBMoney = AOBScan(MyAOBString)
end |
Last edited by sir-gunny on Sat Jun 23, 2012 2:15 pm; edited 1 time in total |
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25291 Location: The netherlands
|
Posted: Sat Jun 23, 2012 2:11 pm Post subject: |
|
|
First execute this lua code so the function is available
Code: |
function myscript()
local MySymbol = Whateveryoudotogetthesymbolbytesasanaob()
local mystring = "01 02 03 ff ab cd ef "..MySymbol.." 04 05 06 07 08"
autoAssemble([[
AOBScan(aobMoney, ]]..mystring..[[
aobMoney:
nop
nop
nop
nop
]]
end
function UndoMyScript()
--some code that disables it
end
|
Then write an aa script like this
Code: |
[enable]
LuaCall(myscript())
[disable]
LuaCall(UndoMyScript())
|
_________________
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 |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Sat Jun 23, 2012 2:49 pm Post subject: |
|
|
Hi Dark Byte.
Thank you that you help a LUA NOOB!
does it work?
Code: | function myscript()
local MySymbol = readBytes(getAddress(MyRegSymbol),4)
local mystring = "01 02 03 ff ab cd ef "..MySymbol.." 04 05 06 07 08"
autoAssemble([[
AOBScan(aobMoney, ]]..mystring..[[ )
]]
end |
AA script:
Code: | [ENABLE]
LuaCall(myscript())
Label(money)
AOBMoney+08:
Money:
dd (int)10000
[DISABLE]
|
Sorry that i waste your time.
|
|
Back to top |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Sun Jun 24, 2012 9:57 am Post subject: |
|
|
Hi.
My script dosn't work. Whats wrong?
Code: | function FindM()
local KW = readBytes(getAddress(pKW),4)
local IW = readBytes(getAddress(pIW),4)
local MW = readBytes(getAddress(pMW),4)
local HW = readBytes(getAddress(pHW),4)
local MarinesString = "01 00 00 00 00 01 "..MW.." 01 "..HW.." 01 "..IW.." 01 "..KW.." 01 00 00 00 00"
autoAssemble([[
AOBScan(aobMarine, ]]..MarinesString..[[ )
]])
end |
aa:
Code: | [ENABLE]
LuaCall(FindMarines())
label(_MK)
label(_MI)
label(_MM)
label(_MH)
registersymbol(_MK)
registersymbol(_MI)
registersymbol(_MM)
registersymbol(_MH)
aobMarine+06:
_MM:
aobMarine+0B:
_MH:
aobMarine+10:
_MI:
aobMarine+15:
_MK:
[DISABLE]
unregistersymbol(_MK)
unregistersymbol(_MI)
unregistersymbol(_MM)
unregistersymbol(_MH) |
Quote: | Error:Failure determining what means |
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25291 Location: The netherlands
|
Posted: Sun Jun 24, 2012 10:56 am Post subject: |
|
|
aobMarine isn't registered in your autoAssemble() script, aobscan does a local define, not a register
try:
Code: |
autoAssemble([[
label(aobMarine)
registersymbol(aobMarine)
AOBScan(_aobMarine, ]]..MarinesString..[[ )
_aobMarine:
aobMarine:
]])
|
also a tip but not sure if it's for use to you:
Auto assembler can access lua variables directly if used as address. You must precede them with a $ sign
_________________
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 |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Sun Jun 24, 2012 11:45 am Post subject: |
|
|
I get the same error.
If i replace the getAddress() function with the address of the symbol (0x0DEC0000) i get a new error: "Error in line 15 (aobMarine+06):This address specifier is not valid"
EDIT:
I tried to use the LUA AOBScan with $ but i get an error:
Script Error:[string "function FindeMarines()..."]:9: unexpected symbol near '$'
Code: | function FindM()
local KW = readBytes(getAddress(pKW),4)
local IW = readBytes(getAddress(pIW),4)
local MW = readBytes(getAddress(pMW),4)
local HW = readBytes(getAddress(pHW),4)
local MarinesString = "01 00 00 00 00 01 "..MW.." 01 "..HW.." 01 "..IW.." 01 "..KW.." 01 00 00 00 00"
$aobMarine=AOBScan(MarinesString)
end |
If i use this i get the error: Error:Failure determining what means (why is between "what" and "means" an emty area?)
Code: | function FindM()
local KW = readBytes(getAddress(pKW),4)
local IW = readBytes(getAddress(pIW),4)
local MW = readBytes(getAddress(pMW),4)
local HW = readBytes(getAddress(pHW),4)
local MarinesString = "01 00 00 00 00 01 "..MW.." 01 "..HW.." 01 "..IW.." 01 "..KW.." 01 00 00 00 00"
aobMarine = AOBScan(MarinesString)
registersymbol(aobMarine)
end |
|
|
Back to top |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Tue Jun 26, 2012 9:44 am Post subject: |
|
|
IT WORKS!!!
I only forget the "!!
Code: | local KW = readBytes(getAddress("pKW"),4) |
Thank you very much!!!
|
|
Back to top |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Thu Nov 01, 2012 11:50 am Post subject: |
|
|
Hi DarkByte.
Can you tell me what is wrong with my script? I have nothing change but it doesn't work anymore. I hope you can help me.
EDIT: If i use the LuaCall() function in AA i get an error. I think the Lua Script is not loaded.
Description: |
|
Download |
Filename: |
myscript.CT |
Filesize: |
4.38 KB |
Downloaded: |
754 Time(s) |
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25291 Location: The netherlands
|
Posted: Thu Nov 01, 2012 12:46 pm Post subject: |
|
|
The luascript must have been executed yes
In general settings you can check if always execute lua scripts is enabled
Also, post the error you get. My target process does not have the aob you're scanning for, so it can't find it. So I can't test it
_________________
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 |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Thu Nov 01, 2012 2:11 pm Post subject: |
|
|
The LuaScript is always executed. But i think it is not loadet?!?!
Description: |
|
Filesize: |
385.29 KB |
Viewed: |
25121 Time(s) |
|
|
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25291 Location: The netherlands
|
Posted: Thu Nov 01, 2012 2:15 pm Post subject: |
|
|
Change FindMarines() function to this
Code: |
function FindMarines()
local KW = readBytes(getAddress("pKW"),4)
local IW = readBytes(getAddress("pIW"),4)
local MW = readBytes(getAddress("pMW"),4)
local HW = readBytes(getAddress("pHW"),4)
local MarinesString = "01 00 00 00 00 01 "..MW.." 01 "..HW.." 01 "..IW.." 01 "..KW.." 01 00 00 00 00"
if (autoAssemble([[
label(aobMarine)
registersymbol(aobMarine)
AOBScan(_aobMarine, ]]..MarinesString..[[ )
_aobMarine:
aobMarine:
]])) == false then
print("Failure assembling this script. AOB scanned was "..MarinesString)
end
end
|
Perhaps the AOB can not be found in the target process causing the script to fail and never registering aobMarine
_________________
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 |
|
|
sir-gunny Advanced Cheater Reputation: 0
Joined: 15 Mar 2012 Posts: 80
|
Posted: Thu Nov 01, 2012 2:27 pm Post subject: |
|
|
haha... lol...
if :
current KW = 26
current IW = 53
current MW = 14
current HW = 11
the string should look like this:
01 00 00 00 00 01 0E 00 00 00 01 0B 00 00 00 01 35 00 00 00 01 1A 00 00 00 01 00 00 00 00
but it look so:
Failure assembling this script. AOB scanned was 01 00 00 00 00 01 14 01 11 01 53 01 26 01 00 00 00 00
as 1byte int... lol?!?!? why??
|
|
Back to top |
|
|
|