Hi guys !
I would like to present you a project I'm working on. It is a library based on cheat engine a powerfull memory editing software.
I made this library to give programmers the possibility to make their own cheat engine with only a few lines of code.
This is really simple, my dll embed the cheat engine core and exports some functions. No more cheat engine software, no more manual updating a trainer ! No more headaches while making a trainer !
Moreover, you can use your favorite programming language and calls theses functions !
What you can do for now :
- inject any asm scripts with theses symbols (ALLOC DEALLOC LABEL DEFINE REGISTERSYMBOL UNREGISTERSYMBOL INCLUDE READMEM LOADLIBRARY).
- manipulate a virtual cheat table to activate and desactivate any script
- the memory scanner will come soon !
And I'm glad to tell you that this project is open source, and available on ****** at this address : ******.com/fenix01/cheatengine-library
You may found on ******, (samples for delphi, c++, lazarus,a compiled library for 64 bits OS, and the full source code)
Here it's a c++ example. It takes only 60 lines of code to inject a script.
Code:
#include <Windows.h>
#include <string>
#include <iostream>
#include "..\..\wrapper\c++\Connector.hpp"
using namespace std;
int _tmain(int argc, _TCHAR* argv[])
{
//load the cheat engine library
HINSTANCE libInst;
//don't forget to put the dll in the same directory
#ifdef _WIN64
libInst = LoadLibraryW(L"ce-lib64.dll");
#else
libInst = LoadLibrary("ce-lib32.dll");
#endif
loadFunctions(libInst);
//get all running processes and print the list
BSTR proc;
iGetProcessList(proc);
wcout << proc;
BSTR pid = ::SysAllocString(L"00000000");
cout << "put the pid of the process\r\n";
wcin >> pid; //don't forget to put the eight digit like 00000000
wcout << pid << "\r\n";
iOpenProcess(pid);//open running process by pid
//add a script to the virtual table
BSTR name = ::SysAllocString(L"example");//name of the script
//Don't try to run this script or you will get an exception.
//this script is just an example.
//It's a hook script for the MessageBox api.
BSTR script = ::SysAllocString(
L"[enable]\r\n"
L"alloc(hook, 1024)\r\n"
L"hook:\r\n"
L"db 49 4C EB 76\r\n"
L"db 68 00 6F 00 6F 00 6B 00 20 00 21 00 00 00\r\n"
L"pop eax\r\n"
L"add esp, 10\r\n"
L"push 30\r\n"
L"push hook+4\r\n"
L"push hook+4\r\n"
L"push 0\r\n"
L"push eax\r\n"
L"jmp [hook]\r\n"
L"0042434C:\r\n"
L"dd hook+12\r\n"
L"[disable]\r\n"
L"0042434C :\r\n"
L"db 49 4C EB 76\r\n"
L"dealloc(hook)");//the auto assemble script
//add the script
iAddScript(name, script);
//remove the script with index 0 in the virtual table
iRemoveScript(0);
//add a script
iAddScript(name, script);
//activate the script
iActivateScript(0, true);
system("PAUSE");
FreeLibrary(libInst);
return 0;
}
In a next stage, I would like to include the lua script engine, the pointer scanner, and the kernelmode driver.