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 


c++ trainer help

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
ahax
How do I cheat?
Reputation: 0

Joined: 18 Sep 2013
Posts: 3

PostPosted: Thu Sep 26, 2013 5:36 pm    Post subject: c++ trainer help Reply with quote

Hey,

I'm trying to write some simple application that would use 'writeprocessmemory' and freeze(i saw on msdn that you can't freeze using wmp but instead of this you can just loop)

Thats what i have for now:
gyazo com/cce8fa578c320d6ff0c00c4ceb0b28ab.png


so how can i write something to entrypoint + offset?
Can you provide me some code examples?

Thanks in advance
Back to top
View user's profile Send private message
atom0s
Moderator
Reputation: 205

Joined: 25 Jan 2006
Posts: 8587
Location: 127.0.0.1

PostPosted: Sat Sep 28, 2013 8:17 pm    Post subject: Reply with quote

You can use CreateToolhelp32Snapshot, Process32First / Process32Next to obtain a list of running processes, see the MSDN example here:

http://msdn.microsoft.com/en-us/library/windows/desktop/ms686701(v=vs.85).aspx

Once you have the process you can use Module32First to get the exe's base address to use for your first pointer calculation.

_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
aeree
Cheater
Reputation: 3

Joined: 23 Jan 2010
Posts: 42
Location: Germany

PostPosted: Fri Oct 04, 2013 9:01 am    Post subject: Reply with quote

Code:


DWORD Address = 0x400000 + 0xB00B5   // =>  "foo.exe" + 0x0FF537
DWORD Offsets[5] = {0x10, 0x3ac, 0x10, 0x70};

for(int i = 0; i < 5; i++)
{
     ReadProcessMemory(hHandle,(LPVOID)Address,&Address,sizeof(Address),NULL);
     Address += Offsets[i];
}





Am I doing this right?

_________________
1 + 1 =
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