Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // dllmain.cpp : Definiert den Einstiegspunkt für die DLL-Anwendung.
- #include "pch.h"
- #include "il2cpp.h"
- #include <windows.h>
- #include <TlHelp32.h>
- #include <vector>
- #include <chrono>
- #include <thread>
- #include <iostream>
- #include "mem.h"
- #include <string>
- #include <stdio.h>
- #include <stdlib.h>
- #include <time.h>
- #include <inttypes.h>
- #include <vector>
- #include <random>
- #include <climits>
- #include <algorithm>
- #include <functional>
- #pragma warning(disable : 4996)
- using random_bytes_engine = std::independent_bits_engine<std::default_random_engine, CHAR_BIT, unsigned int>;
- uintptr_t GetModuleBaseAddress(DWORD procId, const wchar_t* modName)
- {
- uintptr_t modBaseAddr = 0;
- HANDLE hSnap = CreateToolhelp32Snapshot(TH32CS_SNAPMODULE | TH32CS_SNAPMODULE32, procId);
- if (hSnap != INVALID_HANDLE_VALUE)
- {
- MODULEENTRY32 modEntry;
- modEntry.dwSize = sizeof(modEntry);
- if (Module32First(hSnap, &modEntry))
- {
- do
- {
- if (!_wcsicmp(modEntry.szModule, modName))
- {
- modBaseAddr = (uintptr_t)modEntry.modBaseAddr;
- break;
- }
- } while (Module32Next(hSnap, &modEntry));
- }
- }
- CloseHandle(hSnap);
- return modBaseAddr;
- }
- void __stdcall StartDetection() {
- std::cout << "StartDetection called." << std::endl;
- return;
- }
- void __stdcall StopDetection() {
- std::cout << "StopDetection called." << std::endl;
- return;
- }
- void __stdcall Dispose() {
- std::cout << "Dispose called." << std::endl;
- return;
- }
- void __stdcall ObscuredCheatingDetector() {
- std::cout << "ObscuredCheatingDetector called." << std::endl;
- return;
- }
- void __stdcall Awake() {
- std::cout << "Awake called." << std::endl;
- return;
- }
- void __stdcall OnDestroy() {
- std::cout << "OnDestroy called." << std::endl;
- return;
- }
- void __stdcall OnLevelWasLoadedNew() {
- std::cout << "OnLevelWasLoadedNew called." << std::endl;
- return;
- }
- void __stdcall OnLevelLoadedCallback() {
- std::cout << "OnLevelLoadedCallback called." << std::endl;
- return;
- }
- void __stdcall StartDetectionInternal() {
- std::cout << "StartDetectionInternal called." << std::endl;
- return;
- }
- void __stdcall StartDetectionAutomatically() {
- std::cout << "StartDetectionAutomatically called." << std::endl;
- return;
- }
- void __stdcall PauseDetector() {
- std::cout << "PauseDetector called." << std::endl;
- return;
- }
- void __stdcall ResumeDetector() {
- std::cout << "ResumeDetector called." << std::endl;
- return;
- }
- void __stdcall StopDetectionInternal() {
- std::cout << "StopDetectionInternal called." << std::endl;
- return;
- }
- void __stdcall DisposeInternal() {
- std::cout << "DisposeInternal called." << std::endl;
- return;
- }
- void __stdcall InjectionDetector() {
- std::cout << "InjectionDetector called." << std::endl;
- return;
- }
- void __stdcall OnNewAssemblyLoaded() {
- std::cout << "OnNewAssemblyLoaded called." << std::endl;
- return;
- }
- void __stdcall FindInjectionInCurrentAssemblies() {
- std::cout << "FindInjectionInCurrentAssemblies called." << std::endl;
- return;
- }
- void __stdcall AssemblyAllowed() {
- std::cout << "AssemblyAllowed called." << std::endl;
- return;
- }
- void __stdcall LoadAndParseAllowedAssemblies() {
- std::cout << "LoadAndParseAllowedAssemblies called." << std::endl;
- return;
- }
- void __stdcall GetAssemblyHash() {
- std::cout << "GetAssemblyHash called." << std::endl;
- return;
- }
- void __stdcall PublicKeyTokenToString() {
- std::cout << "PublicKeyTokenToString called." << std::endl;
- return;
- }
- void __stdcall AllowedAssembly() {
- std::cout << "AllowedAssembly called." << std::endl;
- return;
- }
- void __stdcall SpeedHackDetector() {
- std::cout << "SpeedHackDetector called." << std::endl;
- return;
- }
- void __stdcall OnApplicationPause() {
- std::cout << "OnApplicationPause called." << std::endl;
- return;
- }
- void __stdcall Update() {
- //std::cout << "Update called." << std::endl;
- return;
- }
- void __stdcall WallHackDetector() {
- std::cout << "WallHackDetector called." << std::endl;
- return;
- }
- void __stdcall FixedUpdate() {
- std::cout << "FixedUpdate called." << std::endl;
- return;
- }
- void __stdcall UpdateServiceContainer() {
- std::cout << "UpdateServiceContainer called." << std::endl;
- return;
- }
- void __stdcall StartRigidModule() {
- std::cout << "StartRigidModule called." << std::endl;
- return;
- }
- void __stdcall StartControllerModule() {
- std::cout << "StartControllerModule called." << std::endl;
- return;
- }
- void __stdcall StartWireframeModule() {
- std::cout << "StartWireframeModule called." << std::endl;
- return;
- }
- void __stdcall ShootWireframeModule() {
- std::cout << "ShootWireframeModule called." << std::endl;
- return;
- }
- void __stdcall StartRaycastModule() {
- std::cout << "StartRaycastModule called." << std::endl;
- return;
- }
- void __stdcall ShootRaycastModule() {
- std::cout << "ShootRaycastModule called." << std::endl;
- return;
- }
- void __stdcall StopRigidModule() {
- std::cout << "StopRigidModule called." << std::endl;
- return;
- }
- void __stdcall StopControllerModule() {
- std::cout << "StopControllerModule called." << std::endl;
- return;
- }
- void __stdcall StopWireframeModule() {
- std::cout << "StopWireframeModule called." << std::endl;
- return;
- }
- void __stdcall StopRaycastModule() {
- std::cout << "StopRaycastModule called." << std::endl;
- return;
- }
- void __stdcall InitRigidModule() {
- std::cout << "InitRigidModule called." << std::endl;
- return;
- }
- void __stdcall InitControllerModule() {
- std::cout << "InitControllerModule called." << std::endl;
- return;
- }
- void __stdcall UninitRigidModule() {
- std::cout << "UninitRigidModule called." << std::endl;
- return;
- }
- void __stdcall UninitControllerModule() {
- std::cout << "UninitControllerModule called." << std::endl;
- return;
- }
- void __stdcall Detect() {
- std::cout << "Detect called." << std::endl;
- return;
- }
- void __stdcall GenerateColor() {
- std::cout << "GenerateColor called." << std::endl;
- return;
- }
- void __stdcall ColorsSimilar() {
- std::cout << "ColorsSimilar called." << std::endl;
- return;
- }
- void __stdcall MoveNext() {
- std::cout << "MoveNext called." << std::endl;
- return;
- }
- int GetPIDfromProcName(std::wstring targetProcessName) {
- std::vector<DWORD> pids;
- HANDLE snap = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0); //all processes
- PROCESSENTRY32W entry; //current process
- entry.dwSize = sizeof entry;
- if (!Process32FirstW(snap, &entry)) { //start with the first in snapshot
- return 0;
- }
- do {
- if (std::wstring(entry.szExeFile) == targetProcessName) {
- return entry.th32ProcessID; //name matches; return
- }
- } while (Process32NextW(snap, &entry)); //keep going until end of snapshot
- return 0;
- }
- typedef void(__thiscall* _SetMoney)(void* pThis, int money);
- typedef void func(bool money); // Creating an int function alias, replace (void) with your parameters
- typedef void(__stdcall* __OnJoinRound)(int id, const char* name, const char* clanname, bool vip, int team, int deadflag, float x, float y, float z, bool zombie);
- typedef void(__stdcall* __hkIgnore)();
- typedef void(__stdcall* __hkShowItem)(LitJson_JsonData_o jsonData, int id, System_String_o* name, System_String_o* displayType, System_String_o* description, int price, System_String_o* slot, System_String_o* icon, System_String_o* iconLarge, float iconScale);
- typedef void(__stdcall* __Spawn)(float x, float y, float z, float angle);
- typedef void(__stdcall* __CreatePlayer)(int id, System_String_o* name, System_String_o* clanname, bool vip, int team, int deadflag, float x, float y, float z, bool zombie);
- __CreatePlayer _CreatePlayer;
- __OnJoinRound _OnJoinRound;
- __hkShowItem _ShowItem;
- __Spawn _Spawn;
- void __stdcall Spawn(float x, float y, float z, float angle) {
- x = 1;
- y = 1;
- z = 1;
- return _Spawn(x, y, z, angle);
- }
- void __stdcall CreatePlayer(int id, System_String_o* name, System_String_o* clanname, bool vip, int team, int deadflag, float x, float y, float z, bool zombie) {
- std::cout << "New Player. ID: " + std::to_string(id) << std::endl;
- return _CreatePlayer(id,name,clanname,vip,team,deadflag,x,y,z,zombie);
- }
- void __stdcall hkOnJoinRound(int id, const char* name, const char* clanname, bool vip, int team, int deadflag, float x, float y, float z, bool zombie) {
- std::cout << name << std::endl;
- return _OnJoinRound(id, name, clanname, vip, team, deadflag, x, y, z, zombie);
- }
- void __stdcall hkIgnore() {
- //std::cout << "Anti-Cheat Call hooked." << std::endl;
- return;
- }
- // f will be pointing to 0xDEADBEEF function address
- void StartCheat() {
- AllocConsole();
- freopen("CONOUT$", "w", stdout);
- std::cout << "Injected!" << std::endl;
- int PID = GetPIDfromProcName(L"warmode.exe");
- uintptr_t BaseAddress = GetModuleBaseAddress((DWORD)PID, L"GameAssembly.dll");
- //mem::Patch((BYTE*)(BaseAddress + 0x23FCE0) + 1, (BYTE*)0xC3,1);
- uintptr_t UnityBaseAddress = GetModuleBaseAddress((DWORD)PID, L"UnityPlayer.dll");
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FE20, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FF30, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x2400C0, (BYTE*)StopDetection, 6); // StopDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FAD0, (BYTE*)Dispose, 6); // Dispose
- mem::TrampHook32((BYTE*)BaseAddress + 0x240190, (BYTE*)ObscuredCheatingDetector, 6); // ObscuredCheatingDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F900, (BYTE*)Awake, 6); // Awake
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FBA0, (BYTE*)OnDestroy, 6); // OnDestroy
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FBE0, (BYTE*)OnLevelWasLoadedNew, 6); // OnLevelWasLoadedNew
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FBE0, (BYTE*)OnLevelLoadedCallback, 6); // OnLevelLoadedCallback
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FCE0, (BYTE*)StartDetectionInternal, 6); // StartDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FCC0, (BYTE*)StartDetectionAutomatically, 6); // StartDetectionAutomatically
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FC90, (BYTE*)PauseDetector, 6); // PauseDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FCA0, (BYTE*)ResumeDetector, 6); // ResumeDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x2400A0, (BYTE*)StopDetectionInternal, 6); // StopDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F9D0, (BYTE*)DisposeInternal, 6); // DisposeInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F4C0, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F350, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F630, (BYTE*)StopDetection, 6); // StopDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x23E7E0, (BYTE*)Dispose, 6); // Dispose
- mem::TrampHook32((BYTE*)BaseAddress + 0x231780, (BYTE*)InjectionDetector, 6); // InjectionDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x23E610, (BYTE*)Awake, 6); // Awake
- mem::TrampHook32((BYTE*)BaseAddress + 0x23EE60, (BYTE*)OnDestroy, 6); // OnDestroy
- mem::TrampHook32((BYTE*)BaseAddress + 0x23EEA0, (BYTE*)OnLevelWasLoadedNew, 6); // OnLevelWasLoadedNew
- mem::TrampHook32((BYTE*)BaseAddress + 0x23EEA0, (BYTE*)OnLevelLoadedCallback, 6); // OnLevelLoadedCallback
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F120, (BYTE*)StartDetectionInternal, 6); // StartDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F100, (BYTE*)StartDetectionAutomatically, 6); // StartDetectionAutomatically
- mem::TrampHook32((BYTE*)BaseAddress + 0x23EF90, (BYTE*)PauseDetector, 6); // PauseDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F080, (BYTE*)ResumeDetector, 6); // ResumeDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F5B0, (BYTE*)StopDetectionInternal, 6); // StopDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x23E6E0, (BYTE*)DisposeInternal, 6); // DisposeInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x23EF50, (BYTE*)OnNewAssemblyLoaded, 6); // OnNewAssemblyLoaded
- mem::TrampHook32((BYTE*)BaseAddress + 0x23E8B0, (BYTE*)FindInjectionInCurrentAssemblies, 6); // FindInjectionInCurrentAssemblies
- mem::TrampHook32((BYTE*)BaseAddress + 0x23E510, (BYTE*)AssemblyAllowed, 6); // AssemblyAllowed
- mem::TrampHook32((BYTE*)BaseAddress + 0x23EA60, (BYTE*)LoadAndParseAllowedAssemblies, 6); // LoadAndParseAllowedAssemblies
- mem::TrampHook32((BYTE*)BaseAddress + 0x23E940, (BYTE*)GetAssemblyHash, 6); // GetAssemblyHash
- mem::TrampHook32((BYTE*)BaseAddress + 0x23F000, (BYTE*)PublicKeyTokenToString, 6); // PublicKeyTokenToString
- //mem::TrampHook32((BYTE*)BaseAddress + 0x190580, (BYTE*)AllowedAssembly, 6); // AllowedAssembly
- mem::TrampHook32((BYTE*)BaseAddress + 0x243980, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x243850, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x243910, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x243B20, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x2438D0, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x243B70, (BYTE*)StopDetection, 6); // StopDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x243440, (BYTE*)Dispose, 6); // Dispose
- mem::TrampHook32((BYTE*)BaseAddress + 0x243E10, (BYTE*)SpeedHackDetector, 6); // SpeedHackDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x243270, (BYTE*)Awake, 6); // Awake
- mem::TrampHook32((BYTE*)BaseAddress + 0x243530, (BYTE*)OnDestroy, 6); // OnDestroy
- mem::TrampHook32((BYTE*)BaseAddress + 0x243570, (BYTE*)OnLevelWasLoadedNew, 6); // OnLevelWasLoadedNew
- mem::TrampHook32((BYTE*)BaseAddress + 0x243570, (BYTE*)OnLevelLoadedCallback, 6); // OnLevelLoadedCallback
- mem::TrampHook32((BYTE*)BaseAddress + 0x243510, (BYTE*)OnApplicationPause, 6); // OnApplicationPause
- mem::TrampHook32((BYTE*)BaseAddress + 0x243C40, (BYTE*)Update, 6); // Update
- mem::TrampHook32((BYTE*)BaseAddress + 0x2436F0, (BYTE*)StartDetectionInternal, 6); // StartDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x2436C0, (BYTE*)StartDetectionAutomatically, 6); // StartDetectionAutomatically
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FC90, (BYTE*)PauseDetector, 6); // PauseDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x23FCA0, (BYTE*)ResumeDetector, 6); // ResumeDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x2400A0, (BYTE*)StopDetectionInternal, 6); // StopDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x243340, (BYTE*)DisposeInternal, 6); // DisposeInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x245E90, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x245D70, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x245DF0, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x245E50, (BYTE*)StartDetection, 6); // StartDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x246610, (BYTE*)StopDetection, 6); // StopDetection
- mem::TrampHook32((BYTE*)BaseAddress + 0x244DC0, (BYTE*)Dispose, 6); // Dispose
- mem::TrampHook32((BYTE*)BaseAddress + 0x247F10, (BYTE*)WallHackDetector, 6); // WallHackDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x244A70, (BYTE*)Awake, 6); // Awake
- mem::TrampHook32((BYTE*)BaseAddress + 0x2452E0, (BYTE*)OnDestroy, 6); // OnDestroy
- mem::TrampHook32((BYTE*)BaseAddress + 0x245460, (BYTE*)OnLevelWasLoadedNew, 6); // OnLevelWasLoadedNew
- mem::TrampHook32((BYTE*)BaseAddress + 0x245460, (BYTE*)OnLevelLoadedCallback, 6); // OnLevelLoadedCallback
- mem::TrampHook32((BYTE*)BaseAddress + 0x244E90, (BYTE*)FixedUpdate, 6); // FixedUpdate
- mem::TrampHook32((BYTE*)BaseAddress + 0x247D80, (BYTE*)Update, 6); // Update
- mem::TrampHook32((BYTE*)BaseAddress + 0x245BC0, (BYTE*)StartDetectionInternal, 6); // StartDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x245B90, (BYTE*)StartDetectionAutomatically, 6); // StartDetectionAutomatically
- mem::TrampHook32((BYTE*)BaseAddress + 0x245510, (BYTE*)PauseDetector, 6); // PauseDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x2455A0, (BYTE*)ResumeDetector, 6); // ResumeDetector
- mem::TrampHook32((BYTE*)BaseAddress + 0x2465E0, (BYTE*)StopDetectionInternal, 6); // StopDetectionInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x244CC0, (BYTE*)DisposeInternal, 6); // DisposeInternal
- mem::TrampHook32((BYTE*)BaseAddress + 0x246990, (BYTE*)UpdateServiceContainer, 6); // UpdateServiceContainer
- mem::TrampHook32((BYTE*)BaseAddress + 0x2460A0, (BYTE*)StartRigidModule, 6); // StartRigidModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x245840, (BYTE*)StartControllerModule, 6); // StartControllerModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x2464D0, (BYTE*)StartWireframeModule, 6); // StartWireframeModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x2457A0, (BYTE*)ShootWireframeModule, 6); // ShootWireframeModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x246010, (BYTE*)StartRaycastModule, 6); // StartRaycastModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x245600, (BYTE*)ShootRaycastModule, 6); // ShootRaycastModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x246720, (BYTE*)StopRigidModule, 6); // StopRigidModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x246560, (BYTE*)StopControllerModule, 6); // StopControllerModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x2467F0, (BYTE*)StopWireframeModule, 6); // StopWireframeModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x2466E0, (BYTE*)StopRaycastModule, 6); // StopRaycastModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x245180, (BYTE*)InitRigidModule, 6); // InitRigidModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x244FD0, (BYTE*)InitControllerModule, 6); // InitControllerModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x2468E0, (BYTE*)UninitRigidModule, 6); // UninitRigidModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x246830, (BYTE*)UninitControllerModule, 6); // UninitControllerModule
- mem::TrampHook32((BYTE*)BaseAddress + 0x244C70, (BYTE*)Detect, 6); // Detect
- mem::TrampHook32((BYTE*)BaseAddress + 0x244F70, (BYTE*)GenerateColor, 6); // GenerateColor
- mem::TrampHook32((BYTE*)BaseAddress + 0x244BA0, (BYTE*)ColorsSimilar, 6); // ColorsSimilar
- mem::TrampHook32((BYTE*)BaseAddress + 0x66AFD0, (BYTE*)MoveNext, 6); // MoveNext
- mem::TrampHook32((BYTE*)BaseAddress + 0x66AA70, (BYTE*)MoveNext, 6); // MoveNext
- std::cout << "Defeated Anti-Cheat!" << std::endl;
- //war_Spawn = (__Spawn)mem::TrampHook32((BYTE*)BaseAddress + 0x1D8950, (BYTE*)Spawn, 6);
- //_CreatePlayer = (__CreatePlayer)mem::TrampHook32((BYTE*)BaseAddress + 0x5B3360, (BYTE*)CreatePlayer, 6);
- //_OnJoinRound = (__OnJoinRound)mem::TrampHook32((BYTE*)BaseAddress + 0x5B3360, (BYTE*)hkOnJoinRound, 6);
- std::cout << "Hooked!" << std::endl;
- while (true) {
- uintptr_t addr;
- uintptr_t IsIngamePtr = mem::FindDMAAddy(UnityBaseAddress + 0x0118EE38, { 0x170 });
- int isgame = *(int*)IsIngamePtr;
- if (isgame == 1) {
- addr = mem::FindDMAAddy(BaseAddress + 0x00F1C254, { 0x34, 0x5B0, 0x0, 0x7B8, 0x2D8 });
- if (addr == (uintptr_t)0xDEADBEEF) {
- continue;
- }
- if (*(bool*)addr) {
- FirstPersonPlayer_StaticFields* locPlayerPtr = (FirstPersonPlayer_StaticFields*)addr;
- FirstPersonPlayer_StaticFields locPlayer = *locPlayerPtr;
- if ((int)locPlayer.debug == 1) {
- if ((uintptr_t)locPlayer.currweapon == (uintptr_t)nullptr) { // 2D8
- }
- else {
- std::string posistr;
- UnityEngine_Vector3_o* posiptr = (UnityEngine_Vector3_o*)mem::FindDMAAddy(UnityBaseAddress + 0x0118EDAC, { 0x314,0x4F8,0x208,0x20,0x80 });
- posistr = std::to_string(posiptr->x) + " / " + std::to_string(posiptr->y) + " / " + std::to_string(posiptr->z);
- std::cout << posistr << std::endl;
- locPlayer.currweapon->data->WalkAcceleration = 0.4;
- locPlayer.currweapon->data->RunAcceleration = 0.6;
- locPlayer.currweapon->clip = 1337;
- }
- Sleep(1000);
- }
- }
- else {
- }
- }
- if (GetAsyncKeyState(VK_END) & 1) {
- return;
- }
- }
- }
- BOOL APIENTRY DllMain(HMODULE hModule,
- DWORD ul_reason_for_call,
- LPVOID lpReserved
- )
- {
- switch (ul_reason_for_call)
- {
- case DLL_PROCESS_ATTACH:
- CreateThread(0, 0, (LPTHREAD_START_ROUTINE)StartCheat, 0, 0, 0);
- case DLL_THREAD_ATTACH:
- case DLL_THREAD_DETACH:
- case DLL_PROCESS_DETACH:
- break;
- }
- return TRUE;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement