| View previous topic :: View next topic |
| Author |
Message |
z13swee Newbie cheater
Reputation: 0
Joined: 12 Mar 2017 Posts: 12
|
Posted: Sun Oct 22, 2017 9:16 pm Post subject: Help me understanding subroutine (asm) |
|
|
So i are in search for the base address of the players health in this game. I think i have found the subroutine for takeing damage.
This code in the image is run every time players takes a hit. And if i replace the subss instruction with codes that does nothing, no health is taken from player.
I guess the health is a float? is that common? becuse movss,subss are float number instruction i read somewhere.. and xmm0 is a 128bit register commonly used for float, i also read somewhere..
This subroutine is changing 3 bytes i memory ( found in ecx register when pop'ed ), but what i cant figure out is how those 3 bytes converts to the players health ingame?
Becuse when the 3 bytes are: 99 189 74 then ingame health is 11..
And when the 3 byts are: 196 234 31 is 31 ingame..
How does it caculate that? |
|
| Back to top |
|
 |
Zanzer I post too much
Reputation: 126
Joined: 09 Jun 2013 Posts: 3278
|
Posted: Sun Oct 22, 2017 10:07 pm Post subject: |
|
|
The game is encrypting the value with:
Your address is 4 bytes long, not 3. Yes, it is a float.
I can't make any sense out of the 3 bytes you posted.
Float 31 in hex notation is 41F80000.
XOR with E30671AC and get A2FE71AC.
If you switch your health address to display as hex,
paste A2FE71AC in and you should now have 31 health. |
|
| Back to top |
|
 |
z13swee Newbie cheater
Reputation: 0
Joined: 12 Mar 2017 Posts: 12
|
Posted: Mon Oct 23, 2017 12:00 pm Post subject: |
|
|
Thank you for answering.
I did put A2FE71AC in the 4 bytes, and i then got 3100 health ingame. wich is great
I hafto look into how float hex notaion works  |
|
| Back to top |
|
 |
|