Hi I'm running into a problem with an address I am getting on cheat engine. I'm following fleeps C# Trainer tutorial and I have all the C# code sorted out and it's working but I'm coming across this and I'm not sure where to go with it.
I've found the static pointer address for the ammo for all guns in the game "Postal 2" (Bought it on the recent steam sales) the value changes when I switch weapons in game and works when I even restart the game and re attach cheat engine but I'm not sure how to add the address to the code of my trainer the problem is that the pointer is called "FPSGame.DLL"+00024EFC what does this mean? how do I go about getting the actual pointer address so I can add it into my code?
Loop through all process modules and if the name matches, get the baseaddress and add 0x24EFC to it.
it returns HMODULE but u can do Address=(DWORD)(GetModuleHandleA("FPSGame.dll")); and it will return u base of the dll. Then add the offset 00024EFC to Address (Address+=0x00024EFC) variable and ur done ;] Dont forget the 0x!!!
Whenever someone ask this question, people always give them the hard solution. That is what happens when people don't know enough about Cheat Engine.
Just follow these 3 simple steps:
- First, Open Cheat Engine's "Memory Viewer" window
- Next, In Memory Viewer, click the "View" button (located at the top inside the toolbox)
- Finally, un-check "Show Module Address"
he asked how to add this address to his trainer, so GetModuelHandle is the solution.
Thanks for the replys
Last edited by polk666; 07-19-2013 at 08:22 PM.
Process p = Process.GetProcessesByName("yourprocnamewithout.ex e");
foreach (ProcessModule mod in p.Modules)
if (mod.ModuleName == "FPSGame.dll")
baseaddress = mod.BaseAddress.ToInt32();
Trainer.WriteInteger("yourprocnamewithout.exe", baseaddress+0x24EFC, 1 (whatever) );
For that use this C# trainer class: