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 


Help understand some asm

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
ogpayne
Cheater
Reputation: 0

Joined: 08 Dec 2014
Posts: 45

PostPosted: Mon Sep 12, 2016 8:46 pm    Post subject: Help understand some asm Reply with quote

Hi everyone, it has been a really long time since I have bothered with any asm and I just need some help understanding what is happening here. Now this function that is highlighted is increasing by 1 for everyone portion of the map you find in an arpg. So when you discover a new part of the map it adds 1 to something in the memory and it saves that part of the map as identified. I'm trying to make it so the full map is already identified. I also dont understand why it is adding "1BC" to esi. What is "1BC"? If you can interpret anything else from this picture please explain so I can understand, thank you very much! Also if you need more pictures to see what is happening, let me know!

Back to top
View user's profile Send private message
sbryzl
Master Cheater
Reputation: 6

Joined: 25 Jul 2016
Posts: 252

PostPosted: Mon Sep 12, 2016 11:05 pm    Post subject: Reply with quote

[esi + 1c4] is a pointer, as indicated by the brackets, whose pointed to value is moved into edx. then edx is tested to be equal to zero and if it is then it jumps directly to your op which increments the value pointed to by [esi+1bc].

esi is the register which looks to be holding a base address and the program is working with information at offsets like 1bc from the base address which likely means there is a data table there containing information or flags.
Back to top
View user's profile Send private message
rog9001
Expert Cheater
Reputation: 2

Joined: 22 Dec 2015
Posts: 214
Location: Jupiter

PostPosted: Tue Sep 13, 2016 11:18 am    Post subject: Reply with quote

well esi is the register and 1BC is the offset.
If you have used the dissect data structure tool you will know what I am talking about.

In the data structure it goes like this (obviously):
Code:

00000004 - float       ADDRESS: 4.0001
00000008 - double    ADDRESS: -9.3702
0000000C - 4 bytes   ADDRESS: 2000
00000010 - float       ADDRESS: 5.097E4
.
.
.
000001BC - 4 bytes  ADDRESS: 920


basically you can also write it like this:

Code:

[esi+00000004] - float       ADDRESS: 4.0001
[esi+00000008] - double    ADDRESS: -9.3702
[esi+0000000C] - 4 bytes   ADDRESS: 2000
[esi+00000010] - float       ADDRESS: 5.097E4
.
.
.
[esi+000001BC] - 4 bytes  ADDRESS: 920


so lets say that the value at [esi+000001BC] is 920. inc [esi+000001BC] means that the value which is stored in [esi+000001BC] is having 1 added to it (920+1=921).

(sorry if I am bad at explaining things xD )
Back to top
View user's profile Send private message
ogpayne
Cheater
Reputation: 0

Joined: 08 Dec 2014
Posts: 45

PostPosted: Wed Sep 14, 2016 3:28 pm    Post subject: Reply with quote

Okay I see, thanks guys. But how could I make this inc by more than 1?
Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Wed Sep 14, 2016 7:01 pm    Post subject: Reply with quote

Code:
add [esi+1BC],2
Back to top
View user's profile Send private message
ogpayne
Cheater
Reputation: 0

Joined: 08 Dec 2014
Posts: 45

PostPosted: Wed Sep 14, 2016 8:11 pm    Post subject: Reply with quote

Ah thank you, sorry for the stupid questions it has been like a year since I have messed with any asm. Anyways, the address that deals with adding to the map also apparently has a lot more functions. The top 3 really high values in this photo are constantly being accessed. I don't know what they are though. The other lower values are being added everytime I find new areas of the map, but what is odd is that it will add one address and inc by 1 but then when I find more of the map it will add another address and inc that one by 1 plus the last one by one and it will continue doing that which is why all of the numbers are higher.. What is happening here? I don't understand how this game is storing the map information.. (one value is 69 because I tried adding 50 to it to see what would happen, nothing happened)


Back to top
View user's profile Send private message
Zanzer
I post too much
Reputation: 126

Joined: 09 Jun 2013
Posts: 3278

PostPosted: Wed Sep 14, 2016 10:09 pm    Post subject: Reply with quote

Try taking one of the address related to the map and find out what accesses this address.
See what instructions pop up when you open the map or something.
If an instruction pops up, find out what addresses that instruction accesses.
When you open the map, if it touches a lot of zeroes, try changing their value and seeing if it alters your map.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking 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