Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


MONO: Instances and invoking

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Tutorials
View previous topic :: View next topic  
Author Message
Dark Byte
Site Admin
Reputation: 465

Joined: 09 May 2003
Posts: 25509
Location: The netherlands

PostPosted: Thu Jul 27, 2017 7:33 am    Post subject: MONO: Instances and invoking Reply with quote

In this tutorial i'll show how to use the mono feature called "find instances of class"
As example game I'll use Kindergarten, as it's really small, and pretty easy, but the playerclass gets destroyed every day. (Not that you actually need to cheat in this game)

First of, I found out the address of money, then used dissect data on it and let mono dissect it for me.
That gave as result that money is inside a class called "PlayerController"

With that information you can go to mono dissect, find the class "PlayerController" , rightclick it, and then choose "Find instances of class"
After the scan is done a dialog will popup with a list of objects that look like they are a PlayerController object (do check the memory yourself if it is actually correct)

Note down the address (or doubleclick it , click on the hexview and press ctrl+g followed by ctrl+c) and go to dissect data with a PlayerController structure configured (if you don't have one, just let it dissect it for you)

Scroll down till you find money, and set the value to whatever you like


----
Invoke Method
----
Alternatively, you can use the invoke Method function with the address you just found

The PlayerController class has a "GetMoney" method which take a single(float) as parameter

So, in the mono dissector highlight GetMoney and choose "Execute/Invoke method"
Give as instance address the address you just found, or pull down the dropdown so it'll search again
Fill in the amount of money you wish in "S: single" and click ok
You'll hear the money sound, and if you look at the screen in the game you'll see the amount of money has been added

_________________
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
View user's profile Send private message MSN Messenger
STN
I post too much
Reputation: 43

Joined: 09 Nov 2005
Posts: 2676

PostPosted: Thu Jul 27, 2017 10:37 am    Post subject: Reply with quote

Quote:
Note down the address (or doubleclick it , click on the hexview and press ctrl+g followed by ctrl+c) and go to dissect data


Would be nice if there was a menu option for data dissecting since sometimes there can be many instances of the class and it gets tiring to check all of them out.

_________________
Cheat Requests/Tables- Fearless Cheat Engine
https://fearlessrevolution.com
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 465

Joined: 09 May 2003
Posts: 25509
Location: The netherlands

PostPosted: Thu Jul 27, 2017 12:05 pm    Post subject: Reply with quote

it's already in the todolist. (you can also add it yourself if you know ce's lua )
_________________
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
View user's profile Send private message MSN Messenger
Oxijen
Expert Cheater
Reputation: 0

Joined: 07 May 2020
Posts: 163
Location: On The Moon

PostPosted: Sun Jan 17, 2021 12:17 pm    Post subject: Reply with quote

when i dissect data and struct the game crashes.
_________________
I can see you Hitler
Especially When I am On the Moon!!
You are Right now in cheat engine forum Wink
Back to top
View user's profile Send private message
Shiller
How do I cheat?
Reputation: 0

Joined: 18 Mar 2023
Posts: 3

PostPosted: Sun Mar 19, 2023 2:17 am    Post subject: Reply with quote

Is there a way to point to the instance after restarting the game?
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 465

Joined: 09 May 2003
Posts: 25509
Location: The netherlands

PostPosted: Sun Mar 19, 2023 2:44 am    Post subject: Reply with quote

you'll have to find the instance again but you can use the find instances option to help you with that
_________________
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
View user's profile Send private message MSN Messenger
Shiller
How do I cheat?
Reputation: 0

Joined: 18 Mar 2023
Posts: 3

PostPosted: Sun Mar 19, 2023 9:24 am    Post subject: Reply with quote

Dark Byte wrote:
you'll have to find the instance again but you can use the find instances option to help you with that


Hi Dark Byte thanks for the answer, my final goal is to build an external cheat so finding it each time again is not what I am looking for, is there any technique to achieve this?
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 465

Joined: 09 May 2003
Posts: 25509
Location: The netherlands

PostPosted: Sun Mar 19, 2023 10:49 am    Post subject: Reply with quote

look at the code of findInstances and use that (it's all lua)
just add some extra checks like validating strings or what not

_________________
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
View user's profile Send private message MSN Messenger
JustHim24
How do I cheat?
Reputation: 0

Joined: 15 Jan 2024
Posts: 5

PostPosted: Mon Mar 25, 2024 2:30 pm    Post subject: Re: MONO: Instances and invoking Reply with quote

Dark Byte wrote:
After the scan is done a dialog will popup with a list of objects that look like they are a PlayerController object (do check the memory yourself if it is actually correct)


What are we checking, the address we found for money? If not then how do we check and verify the instances are correct?

Edit: After staring at the text and re reading i believe i understand.
When we find the money memory and disect it so we can find the playercontroller class, the address that class is at is the instance for invoking the setMoney method? Please correct me if i am wrong
Back to top
View user's profile Send private message
Dark Byte
Site Admin
Reputation: 465

Joined: 09 May 2003
Posts: 25509
Location: The netherlands

PostPosted: Mon Mar 25, 2024 2:50 pm    Post subject: Reply with quote

yup.
_________________
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
View user's profile Send private message MSN Messenger
pbrown273
How do I cheat?
Reputation: 0

Joined: 26 Mar 2024
Posts: 1

PostPosted: Sat Mar 30, 2024 12:57 pm    Post subject: Reply with quote

Thanks for information
Back to top
View user's profile Send private message
Rubrub
How do I cheat?
Reputation: 0

Joined: 08 May 2024
Posts: 1

PostPosted: Wed May 08, 2024 1:44 pm    Post subject: Reply with quote

Hey does this UI support invoking a method with a type such as a UnityEngine.Vector3, or would this need to be done with a lua script?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> Cheat Engine Tutorials All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites