Page 1 of 1

Cheat Engine 7.2 - New .NET Dissect

Posted: Thu Nov 12, 2020 3:58 pm
by ODimm
Hi,

CE 7.2 offers a new .NET Dissect and it has a new function : it can show public static fields of a class.

it works for Mono and Il2CPP Unity games.

i've always used mono_class_getStaticFieldAddress to get the static area from a class, and it still works fine for mono.

but for Il2CPP games is does not work, so maybe someone can help me how to make a script that gets a static field on a Il2CPP game?

i know its very specific, especially coz CE 7.2 .NET Dissector is new, but maybe someone has an idea how it works, so thanks for everyone who knows that and can help me on this topic!

Re: Cheat Engine 7.2 - New .NET Dissect

Posted: Fri Nov 13, 2020 1:01 am
by tfigment
Have not looked at 7.2 yet. I wrote some of the original static data code generation and then ported it manually for Wasteland 3 I did not write a general one for CE. Not sure if we we are talking same code but you can see the manual code for getting static data for il2cpp games in this table:

viewtopic.php?f=4&t=13525

You could copy paste the code and change things as needed. Maybe will help if that is what you were looking for as example as there are many ways to do this each with varying levels of success.

Re: Cheat Engine 7.2 - New .NET Dissect

Posted: Fri Nov 13, 2020 4:35 pm
by ODimm
tfigment wrote:
Fri Nov 13, 2020 1:01 am
Have not looked at 7.2 yet. I wrote some of the original static data code generation and then ported it manually for Wasteland 3 I did not write a general one for CE. Not sure if we we are talking same code but you can see the manual code for getting static data for il2cpp games in this table:

viewtopic.php?f=4&t=13525

You could copy paste the code and change things as needed. Maybe will help if that is what you were looking for as example as there are many ways to do this each with varying levels of success.
Hi,


i see your are calling il2cpp_class_from_name / il2cpp_class_get_field_from_name / il2cpp_field_static_get_value :)

really thanks, that does help me alot, will try it on the next il2cpp game!

do you know some wiki pages about (CE)mono function? im just curious how you know about that functions.

thanks again!

Re: Cheat Engine 7.2 - New .NET Dissect

Posted: Sat Nov 14, 2020 6:48 pm
by Cake-san
Or you can manually find it inside method/function ...
Usually either locate inside awake or .ctor method/function ... or inside other method/function that need that variable
Image
Image
Image

According to the image... static LevelController instance is [[[7FFFD2F135A0]+b8]]

Re: Cheat Engine 7.2 - New .NET Dissect

Posted: Sat Nov 14, 2020 7:28 pm
by silver001
Thank you for these tips, tfigment and Cake-san !
I am learning stuff all the time.