I'm doing some tinkering with Read- and WriteProcessMemory and an old platformer game I found laying around. Whenever the player enters a new level, enemies are created and the hea开发者_运维百科lth points, coordinates etc for each one is set:
0056BE76 - c7 80 38 01 00 00 64 00 00 00 - mov [eax+00000138],00000064
(EAX being the address of the struct and 138 the offset to their health)
Granted there is free memory to write, is there any way I could store the value of EAX of each one in one and the same location? Like using a delimiter of sorts?
Cheers
From what I understood, i think you can use an union
http://www.wellho.net/resources/ex.php4?item=c209/union.c
精彩评论