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 


Delphi and or C++

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General programming
View previous topic :: View next topic  
Author Message
slippppppppp
Grandmaster Cheater
Reputation: 0

Joined: 08 Aug 2006
Posts: 929

PostPosted: Thu Feb 07, 2008 11:59 pm    Post subject: Delphi and or C++ Reply with quote

Can anyone point me to the right direction on doing this, basically like a cheat engine, but instead either from a standalone or a dll,
How do i enable an asm script, get a value from an allocation and put it into the eip of xxx? Embarassed
Back to top
View user's profile Send private message AIM Address MSN Messenger
NothingToShow
Grandmaster Cheater Supreme
Reputation: 0

Joined: 11 Jul 2007
Posts: 1579

PostPosted: Fri Feb 08, 2008 12:33 am    Post subject: Reply with quote

Cheat Engine is made in Delphi, but I think C++ would be alot more powerfull.
Back to top
View user's profile Send private message
isair
Grandmaster Cheater
Reputation: 0

Joined: 28 Dec 2007
Posts: 804

PostPosted: Fri Feb 08, 2008 5:14 am    Post subject: Reply with quote

Use C++.If you wanna execute some asm instructions in C++ just do sth like this.

Code:

__asm
{
    //put the instructions here
}


And for memory editing if you make a DLL which edits the memory of a program/game you have to work with pointer variables(don't let the name mess up your mind,the pointers you know from memory scanning is different than pointer variables.In C++,using pointer variables you can declare where the data is stored.):

Code:

//declare these variables first,make sure they are global and not local
DWORD *pointer_for_something = (DWORD*)0x004875AD;
DWORD offset_value_for_the_pointer_of_something = 0x000000F5; //You can write 0xF5 instead of that too but I like writing them long :P
//now lets assume that the value you want to edit is an integer
int *something = (int*)(*pointer_for_something + offset_value_for_the_pointer_of_something);

//now after doing that whenever you want to edit the value of something do this
something = (int*)(*pointer_for_something + offset_value_for_the_pointer_of_something);
*something = 10; //You can change it to whatever integer value you like.



The above example is valid if the address of the data you want to edit is determined by a pointer's value and an offset value.If else,you don't need to make it that messy:

Code:

//I assume that you want to edit an integer again
int *something = (int*)0x0835EA66;

//after declaring that variable just do this anywhere you want
*something = 10;


If you want to code a standalone and don't wanna mess with a DLL:

Code:

//declare these global variables
HWND hwnd; //window handle
DWORD pid; //process id
HANDLE phandle; //process handle

//after you declare those variables use these functions
hwnd = FindWindow(0,L"GameWindowName");
if(hwnd)
{
    GetWindowThreadProcessId(hwnd,&pid);
    phandle = OpenProcess(PROCESS_ALL_ACCESS,pid);
}

//After you get the process handle you can read and write to process memory using WriteProcessMemory and ReadProcessMemory functions.
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Madman
I post too much
Reputation: 1

Joined: 04 May 2006
Posts: 3978

PostPosted: Fri Feb 08, 2008 6:00 am    Post subject: Reply with quote

Moller wrote:
Cheat Engine is made in Delphi, but I think C++ would be alot more powerfull.


Didn't he convert some of it, if not all, to C++?

_________________
Back to top
View user's profile Send private message
HomerSexual
Grandmaster Cheater Supreme
Reputation: 5

Joined: 03 Feb 2007
Posts: 1657

PostPosted: Fri Feb 08, 2008 6:35 am    Post subject: Reply with quote

The gui is made in delphi. The dlls, drivers, and guts are made in C.
_________________
Back to top
View user's profile Send private message
NothingToShow
Grandmaster Cheater Supreme
Reputation: 0

Joined: 11 Jul 2007
Posts: 1579

PostPosted: Fri Feb 08, 2008 6:53 am    Post subject: Reply with quote

blankrider wrote:
The gui is made in delphi. The dlls, drivers, and guts are made in C.

Ahh, didn't know that.
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 programming 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