Joined: 01 Oct 2008
|Posted: Tue Nov 03, 2015 5:23 am Post subject: Custom AA Command for MemoryRecord update/creation
|This is an AA Command extension to allow MemoryRecord manipulation in AA Script.
The command is MemoryRecord or MR, format:
The mr-description-path is a collection of memory record description lua regular expression separated by symbol '/'.
It is in lua regular expression so that the matching need not be complete and exact.
For example, if the following is current address list:
+-Folder2 -- (a)
+-Folder1 -- (b)
+-money -- (c)
GAMEZ/32/Folder2 match (a)
GAME/64/Folder match (b)
GAMEZ/64%-bit/money match (c) , note that the minus sign need to be escape with lua re symbol %
If the memory record expressed by the desc-path not exist, it will be created. Then the record will be update with properties specified on activating. Note that the update will be done even the script activate fail.
record-property-list is the key-value pairs expressed as KEY=VALUE separated by comma ','
The following is an example, if the 64 bit ce is attached to itself , ie, cheatengine-x86_64.exe:
Check main.lua at ce directory or https://raw.githubusercontent.com/cheat-engine/cheat-engine/master/Cheat%20Engine/bin/main.lua for the property of Memory Record.
The following is Memory Record Type defined in define.lua at ce directory:
vtUnicodeString=7 --Only used by autoguess
vtPointer=12 --Only used by autoguess and structures
If the MRAA.lua file has been load as table file in a *.ct, the following script can load & run it.
local hdr = 'loadTableFile: '
assert(type(n)=='string',hdr.."input should be a string -"..tostring(n).." of "..type(n))
local m = assert(findTableFile(n),hdr.."can't find table file -"..n).Stream
m = assert(readStringLocal(m.Memory,m.Size),hdr.."can't read content -"..n)
if type(mode)~='boolean' then return m end
m = assert(loadstring(m,n),hdr.."lua script load fail -"..n)
return mode and m() or m
Sorry, not a detailed explain~
sorry, left an external function in the script, updated.
|custom AA command for MemoryRecord
|| 7.01 KB
|| 327 Time(s)