Page 1 of 1

Help with "Lua Formula" scan

Posted: Fri Jun 09, 2023 5:36 am
by altare
Hi all,
I have a scan requirement in which correct values are always in pairs, in which the second value is at an offset address of +30hex in respect to the first value found.
I'd like to use a "Lua Formula" for this, which should be quite simple, as in:
1- scan for value
2- check for value at address +30hex
3- if value at base address +30hex is equal and corresponds to search value, return result, otherwise skip

So I kindly ask:
1- is it possible to achieve this with a "Lua Formula" scan?
2- is it possible to create a lua script for the relevant function, and put it in the autorun folder?

Thanks in advance

Re: Help with "Lua Formula" scan

Posted: Mon Jun 12, 2023 5:39 pm
by Paul44
^ i'm sure this is possible but:
a. you should make things more clear by posting some images/andwhatnot. atm i have no idea what you mean with 'scan'... as this will be the "approach" on how to get to your 'address_base' in the 1st place?
b. there are plenty of tables out (t)here that use lua, in particular to aob-memscan/andwhatnot. also: do not forget the folks over @CEF (= CE Forum)...

Re: Help with "Lua Formula" scan

Posted: Sun Aug 13, 2023 10:41 am
by panraven
Not need 'Lua'.
I guess it can be use 'Grouped' scan.
For 'Grouped', CE search memory for multiple fixed size values within a specific range.
eg. for your case, you want to search value1 (assume 4 bytes value), then after +30 offset, another values2; the search should be like this,
4:value1 w:44 4:value2
Where [4:] means 4 bytes integer type, [w:]means a wildcard value (the value is not important) size range(the size is important), here 44 is calc from 0x30(=48) - 4 (the size of value1).
There is a ui for setting up, study the detail should help.

For more complex search criteria, may try 'custom type', see if ce wiki has examples.