Version 1.2
821 downloads
Template for automatic finding of the values to modify from the class strings and fields offsets
This gameguardian script to help automatize fields modifications, from the info you have found into the global-metadata file.
have been tested only in this configuration:
- original phone android 11, no-root
- virtualxposed + gameguardian
Now it help me as a base when I try a new game
-> only need to indicate the classes and fields names I want to look for
Notes:
- to use it you need to edit the script and adapt it for your specific game -> it is a template
- must know what is global-metadata file + a bit of lua script language (not too much)
- it is searching the fields into the anonymous A region (often in my android phone fields values are there)
- if the game upgrade, possible that classes names and fields offsets are modified so you must upgrade your script too
How to use and modify the template
1. open the global-metada file [see below to know how to get it], and find the classes and fields you are interested in -> it is the hard stuff
in this example are selected two fields I want to alterate the values:
- classname is LockDrillerMinigameParameters
- field SafeAngle, that is a float, with offset 0x40
- field ShakeModifierIncreasingRate, a float too, offset 0x44
2. edit the metadata_fields_modifier script (on the phone I use Acode), but to be faster can be done on the PC (open with notepad and copy-paste the data directly from global-metadata)
from line 55 in the script, modify the classes_and_fields to fit your data, the example gives:
(before it was line 20 but now line 55)
local classes_and_fields = {
LockDrillerMinigameParameters=
{fields={
{'SafeAngle' , gg.TYPE_FLOAT, 0x40 , 32},
{'ShakeModifier' , gg.TYPE_FLOAT , 0x44 , 0.001}
}},
}
for each field you have:
{'field name', data type, offset, eventual replaced value}
data type possibilities, according what global-metadata indicates
-- gg.TYPE_FLOAT for float
-- gg.TYPE_BYTE for bool
-- gg.TYPE_DWORD for int
Note:
-> "replaced value" is optional, can put only {'SafeAngle',gg.TYPE_FLOAT,0x40}
a) indeed at the beginning you do not know what field is impacting the game, so with this script you can put many classes (ex: 10) and all the int/float fields that seems interesting (ex: 5 for each classes)
b) then running the script in the game, it will find and load each field in gameguardian without modification
c) next you can try to modify the value of each of these fields to look for the best to use, and what values to put
d) edit the script again and this time you can specify the "replaced value" at the end like in my example {'SafeAngle',gg.TYPE_FLOAT,0x40 , 0x32}
3. open the game + run the metadata_fields_modifier script in the game
-> it will ask you what class to search for
Then if successful, the results class and fields data, will be loaded in the gameguardian interface (save tab) so you can check what has be done and modified
=> Hope this script will help you make some great modifications on the games you like.
Extra info about getting global-metadata
- I use the great libil2cpp.so and metadata.dat dumping script (LibDumper by @Lover1500) -> get both needed files (script can be found on this site)
https://gameguardian.net/forum/files/file/2740-libil2cppso-and-metadatadat-dumping-script/?tab=comments#comment-9358
- then I use "il2cppdumper gui" on my phone (dont remember where I found the app apk) to convert both files -> finally got the global-metdata file (named dump.cs)
- seeing it is a very big file not easily readable on the phone -> I send it to the PC to search for some interesting classes to alterate