Posted: Mon Apr 03, 2017 1:28 pm Post subject: Memory Allocation in Assembly?
I'm working on some texture mods for Twisted Metal 2 for PC. I can replace textures just fine but when I increase the size of the textures then the game will crash due to not enough memory being allocated. I can get around this easily with Cheat Engine by running the allocate memory tool and changing the pointer that points to the texture address to the address of the newly allocated memory. Then I can make the textures as big as I want without the game crashing.
But I would like to modify the executable file so it will allocate more memory and change the texture address pointer so I don't have to boot Cheat Engine every time I start the game. I looked around the exe with OllyDbg and Ida and found only one call to GlobalAlloc. I tried increasing the memory allocation size but I couldn't get it to allocate more memory. My experience with assembly is very limited so I'm not sure what to do.
Do you guys have any ideas? I just need to have the executable file allocate more memory and change a pointer to the newly allocated memory.
Joined: 09 May 2003 Posts: 25288 Location: The netherlands
Posted: Mon Apr 03, 2017 1:45 pm Post subject:
Usually games use VirtualAlloc to allocate, but texture memory tends to get allocated using special gpu calls though, so not sure if that helps anything _________________
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
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