Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <Windows.h>
- #include <Psapi.h>
- #include <TlHelp32.h>
- #include <vector>
- #include <string>
- #include "Includes.h"
- #include "DXfunctions.h"
- using namespace std;
- bool HideMenu = false;
- DWORD MenuPosition = 0;
- bool ENABLE_AIMBOT = true;
- bool ENABLE_CROSSHAIR = true;
- bool ENABLE_CHAMS = true;
- float AIM_X = 0.1f;
- float AIM_Y = -0.2f;
- float AIM_Z = 1.6f;
- DWORD AIM_PLAYERS = 2;
- DWORD AIM_KEY = VK_END;
- DWORD AIM_KEY_SEATED = VK_F5;
- int AIM_FOV = 0;
- int AIM_SMOOTH = 0;
- const DWORD MaxOptions = 8;
- const wchar_t* AimOptions[3] = { L"", L"", L"" };
- struct ContractWarsMenu_t
- {
- wchar_t* type;
- float Number;
- bool IsTrue;
- };
- ContractWarsMenu_t HackMenu[MaxOptions] = {
- { L"", 0.0f , true },
- { L"", 0.1f , false },
- { L"", -0.2f , false },
- { L"", 1.6f , false },
- { L"", 0.0f , false },
- { L"", 2.0f , false },
- { L"", 0.0f , true },
- { L"", 0.0f , true }
- };
- void ShowMenuOptions(LPDIRECT3DDEVICE9 pDevice)
- {
- pDevice->GetViewport(&viewport);
- if (viewport.Width <= 100) return;
- if (GetAsyncKeyState(VK_F7) & 1) HideMenu = !HideMenu;
- if (HideMenu) return;
- DrawString(hackMenuFont, 10, 10, 0xFF00CCFF, L"Hack created by Chase Nelson", 1);
- int LastValue = 0;
- for (int i = 0; i < MaxOptions; i++)
- {
- if (i == MenuPosition)
- {
- DrawRectangle(pDevice, hackMenuLine, 8, 48 + (i * 15), 230, 18, 0xFF0000FF);
- }
- DrawString(hackMenuFont, 10, 50 + (i * 15), 0xFF00FF00, L"", HackMenu[i].type);
- if (i == 0 || i == 6 || i == 7) DrawString(hackMenuFont, 150, 50 + (i * 15), HackMenu[i].IsTrue == true ? 0xFF00FF00 : 0xFFFF0000, L"", HackMenu[i].IsTrue == true ? L"TRUE" : L"FALSE"); else
- if (i == 1 || i == 2 || i == 3 || i == 4) DrawString(hackMenuFont, 150, 50 + (i * 15), 0xFF00FF00, L"", HackMenu[i].Number); else//4.2 = mostrar só duas casas decimais
- if (i == 5) DrawString(hackMenuFont, 150, 50 + (i * 15), 0xFF00FF00, L"", AimOptions[(int)HackMenu[i].Number]);
- LastValue = i;
- }
- DrawString(hackMenuFont, 10, 50 + ((LastValue + 2) * 15), RED, L"", 1);
- if (GetAsyncKeyState(VK_F7) & 1) { if (MenuPosition > 0) MenuPosition--; }
- if (GetAsyncKeyState(VK_F8) & 1) { if (MenuPosition < MaxOptions - 1) MenuPosition++; }
- if (GetAsyncKeyState(VK_F5) & 1)
- {
- if (MenuPosition == 0) HackMenu[MenuPosition].IsTrue = false; else
- if (MenuPosition == 1) HackMenu[MenuPosition].Number -= 0.1f; else
- if (MenuPosition == 2) HackMenu[MenuPosition].Number -= 0.1f; else
- if (MenuPosition == 3) HackMenu[MenuPosition].Number -= 0.1f; else
- if (MenuPosition == 4) { if (HackMenu[MenuPosition].Number > 50) HackMenu[MenuPosition].Number -= 1.0f; }
- else
- if (MenuPosition == 5) { if (HackMenu[MenuPosition].Number > 0) HackMenu[MenuPosition].Number -= 1.0f; }
- else
- if (MenuPosition == 6) HackMenu[MenuPosition].IsTrue = false; else
- if (MenuPosition == 7) HackMenu[MenuPosition].IsTrue = false;
- }
- if (GetAsyncKeyState(VK_F7) & 1)
- {
- if (MenuPosition == 0) HackMenu[MenuPosition].IsTrue = true; else
- if (MenuPosition == 1) HackMenu[MenuPosition].Number += 0.1f; else
- if (MenuPosition == 2) HackMenu[MenuPosition].Number += 0.1f; else
- if (MenuPosition == 3) HackMenu[MenuPosition].Number += 0.1f; else
- if (MenuPosition == 4) { if (HackMenu[MenuPosition].Number < 200) HackMenu[MenuPosition].Number += 1.0f; }
- else
- if (MenuPosition == 5) { if (HackMenu[MenuPosition].Number < 2) HackMenu[MenuPosition].Number += 1.0f; }
- else
- if (MenuPosition == 6) HackMenu[MenuPosition].IsTrue = true; else
- if (MenuPosition == 7) HackMenu[MenuPosition].IsTrue = true;
- }
- ENABLE_AIMBOT = HackMenu[0].IsTrue;
- AIM_X = HackMenu[1].Number;
- AIM_Y = HackMenu[2].Number;
- AIM_Z = HackMenu[3].Number;
- AIM_FOV = HackMenu[4].Number;
- AIM_PLAYERS = HackMenu[5].Number;
- ENABLE_CROSSHAIR = HackMenu[6].IsTrue;
- ENABLE_CHAMS = HackMenu[7].IsTrue;
- }
- struct PlayerINFO
- {
- D3DXVECTOR3 Position2D;
- D3DXVECTOR3 PositionFoot;
- D3DXVECTOR3 PositionHead;
- float DistanceFromPlayer;
- float CrosshairDistance;
- int Team;
- };
- vector<PlayerINFO*>pINFO;
- void AddEnemy(LPDIRECT3DDEVICE9 Device, int Team)
- {
- if (hackMenuLine == NULL) return;
- if (hackMenuFont == NULL) return;
- PlayerINFO* playerINFO = new PlayerINFO;
- playerINFO->Team = Team;
- D3DXMATRIX matrix;
- D3DXVECTOR4 position, positionH, positionF;
- D3DXVECTOR4 input;
- Device->GetVertexShaderConstantF(0, (float *)&matrix, 4);
- input.x = AIM_X;
- input.y = AIM_Y;
- input.z = AIM_Z;
- if ((GetAsyncKeyState(AIM_KEY_SEATED) & 0x8000)) input.z -= 0.5f;
- input.w = 0;
- D3DXMatrixTranspose((D3DXMATRIX *)&matrix, (D3DXMATRIX *)&matrix);
- position.x = input.x * matrix._11 + input.y * matrix._21 + input.z * matrix._31 + matrix._41;
- position.y = input.x * matrix._12 + input.y * matrix._22 + input.z * matrix._32 + matrix._42;
- position.z = input.x * matrix._13 + input.y * matrix._23 + input.z * matrix._33 + matrix._43;
- position.w = input.x * matrix._14 + input.y * matrix._24 + input.z * matrix._34 + matrix._44;
- float A = 0.1f;
- float B = -0.2f;
- float C = 0.0f;
- positionF.x = A * matrix._11 + B * matrix._21 + C * matrix._31 + matrix._41;
- positionF.y = A * matrix._12 + B * matrix._22 + C * matrix._32 + matrix._42;
- positionF.z = A * matrix._13 + B * matrix._23 + C * matrix._33 + matrix._43;
- positionF.w = A * matrix._14 + B * matrix._24 + C * matrix._34 + matrix._44;
- A = 0.1f;
- B = -0.2f;
- C = 1.8f;
- positionH.x = A * matrix._11 + B * matrix._21 + C * matrix._31 + matrix._41;
- positionH.y = A * matrix._12 + B * matrix._22 + C * matrix._32 + matrix._42;
- positionH.z = A * matrix._13 + B * matrix._23 + C * matrix._33 + matrix._43;
- positionH.w = A * matrix._14 + B * matrix._24 + C * matrix._34 + matrix._44;
- playerINFO->DistanceFromPlayer = position.z;
- if (matrix._44 > 1.0f)
- {
- playerINFO->Position2D.x = ((position.x / position.w) * (viewport.Width / 2)) + viewport.X + (viewport.Width / 2);
- playerINFO->Position2D.y = viewport.Y + (viewport.Height / 2) - ((position.y / position.w) * (viewport.Height / 2));
- playerINFO->PositionHead.x = ((positionH.x / positionH.w) * (viewport.Width / 2)) + viewport.X + (viewport.Width / 2);
- playerINFO->PositionHead.y = viewport.Y + (viewport.Height / 2) - ((positionH.y / positionH.w) * (viewport.Height / 2));
- playerINFO->PositionFoot.x = ((positionF.x / positionF.w) * (viewport.Width / 2)) + viewport.X + (viewport.Width / 2);
- playerINFO->PositionFoot.y = viewport.Y + (viewport.Height / 2) - ((positionF.y / positionF.w) * (viewport.Height / 2));
- pINFO.push_back(playerINFO);
- }
- }
- void AimEnemy(LPDIRECT3DDEVICE9 Device)
- {
- if (pINFO.size() != NULL)
- {
- UINT BestTarget = -1;
- DOUBLE fClosestPos = 99999;
- float Radius = 4.0f;
- float ScreenCenterX = viewport.Width / 2.0f;
- float ScreenCenterY = viewport.Height / 2.0f;
- for (int i = 0; i < pINFO.size(); i++)
- {
- if (AIM_PLAYERS == 2 || (AIM_PLAYERS == (float)pINFO[i]->Team))
- {
- float h = pINFO[i]->PositionHead.y - pINFO[i]->PositionFoot.y;
- float w = h / 4;
- if (h < viewport.Height / 4)
- {
- //DrawPoint(Device, (int)pINFO[i]->Position2D.x, viewport.Height - (int)pINFO[i]->Position2D.y, 4, 4, RED);
- //DrawCircle((int)pINFO[i]->Position2D.x, viewport.Height - (int)pINFO[i]->Position2D.y, Radius, 20, Device, hackMenuLine, RED);
- //DrawLine(ScreenCenterX, ScreenCenterY*2.0f, pINFO[i]->Position2D.x, viewport.Height - pINFO[i]->Position2D.y + Radius, 1, RED, Device, hackMenuLine);
- //DrawString(hackMenuFont, pINFO[i]->Position2D.x + 3, viewport.Height - pINFO[i]->Position2D.y, 0xFF00FF00, L"Distance: %4.2f mts", ModelInfo[i]->DistanceFromPlayer);
- //DrawRectangle(Device, hackMenuLine, pINFO[i]->PositionFoot.x - w + w / 2, viewport.Height - pINFO[i]->PositionFoot.y - h, w, h, RED);
- }
- float radius = AIM_FOV;
- pINFO[i]->CrosshairDistance = GetDistance(pINFO[i]->Position2D.x, pINFO[i]->Position2D.y, ScreenCenterX, ScreenCenterY);
- if (pINFO[i]->Position2D.x >= ScreenCenterX - radius && pINFO[i]->Position2D.x <= ScreenCenterX + radius && pINFO[i]->Position2D.y >= ScreenCenterY - radius && pINFO[i]->Position2D.y <= ScreenCenterY + radius)
- {
- if (pINFO[i]->CrosshairDistance < fClosestPos)
- {
- fClosestPos = pINFO[i]->CrosshairDistance;
- BestTarget = i;
- }
- }
- }
- }
- if (BestTarget != -1)
- {
- double DistX = (double)pINFO[BestTarget]->Position2D.x - ScreenCenterX;
- double DistY = (double)pINFO[BestTarget]->Position2D.y - ScreenCenterY;
- DistX /= AIM_SMOOTH;
- DistY /= -AIM_SMOOTH;
- if ((GetAsyncKeyState(AIM_KEY) & 0x8000) || (GetAsyncKeyState(AIM_KEY_SEATED) & 0x8000))
- mouse_event(MOUSEEVENTF_MOVE, (DWORD)DistX, (DWORD)DistY, NULL, NULL);
- }
- pINFO.clear();
- }
- }
- LPDIRECT3DTEXTURE9 g_pTexRed = NULL;
- LPDIRECT3DTEXTURE9 g_pTexOrange = NULL;
- LPDIRECT3DTEXTURE9 g_pTexGreen = NULL;
- LPDIRECT3DTEXTURE9 g_pTexBlue = NULL;
- const BYTE red[58] = {
- 0x42, 0x4D, 0x3A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x36, 0x00, 0x00, 0x00, 0x28, 0x00,
- 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00
- };
- const BYTE orange[58] = {
- 0x42, 0x4D, 0x3A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x36, 0x00, 0x00, 0x00, 0x28, 0x00,
- 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x18, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xA5, 0xFF, 0x00
- };
- const BYTE green[60] =
- {
- 0x42, 0x4D, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x36, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00,
- 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01,
- 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x12, 0x0B, 0x00, 0x00, 0x12, 0x0B, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x20, 0xA0, 0x00, 0x00, 0xFF, 0xFF
- };
- const BYTE blue[60] =
- {
- 0x42, 0x4D, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x36, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00,
- 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01,
- 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x12, 0x0B, 0x00, 0x00, 0x12, 0x0B, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00
- };
- void CreatePlayerChams(LPDIRECT3DDEVICE9 pDevice,
- D3DPRIMITIVETYPE PrimType,
- INT BaseVertexIndex,
- UINT MinVertexIndex,
- UINT NumVertices,
- UINT startIndex,
- UINT primCount,
- LPDIRECT3DTEXTURE9 VisibleColor,
- LPDIRECT3DTEXTURE9 BehindWallColor)
- {
- DWORD old_render;
- pDevice->SetRenderState(D3DRS_ZENABLE, false);
- pDevice->SetTexture(0, VisibleColor);
- pDevice->GetRenderState(D3DRS_ZFUNC, &old_render);
- pDevice->SetRenderState(D3DRS_ZFUNC, D3DCMP_NEVER);
- oDrawIndexedPrimitive(pDevice, PrimType, BaseVertexIndex, MinVertexIndex, NumVertices, startIndex, primCount);
- pDevice->SetRenderState(D3DRS_ZENABLE, true);
- pDevice->SetRenderState(D3DRS_ZFUNC, old_render);
- pDevice->SetTexture(0, BehindWallColor);
- }
- HRESULT WINAPI hkReset(LPDIRECT3DDEVICE9 pDevice, D3DPRESENT_PARAMETERS* pPresentationParameters)
- {
- HRESULT hr = NULL;
- if (hackMenuFont != NULL) hackMenuFont->OnLostDevice();
- if (hackMenuLine != NULL) hackMenuLine->OnLostDevice();
- hr = oReset(pDevice, pPresentationParameters);
- if (hackMenuFont != NULL) hackMenuFont->OnResetDevice();
- if (hackMenuLine != NULL) hackMenuLine->OnResetDevice();
- return hr;
- }
- HRESULT WINAPI hkEndScene(LPDIRECT3DDEVICE9 pDevice)
- {
- pDevice->GetViewport(&viewport);
- if (hackMenuFont == NULL) D3DXCreateFont(pDevice, 15, 0, FW_BOLD, 1, 0, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, ANTIALIASED_QUALITY, DEFAULT_PITCH | FF_DONTCARE, "Verdana", &hackMenuFont);
- if (hackMenuLine == NULL) D3DXCreateLine(pDevice, &hackMenuLine);
- if (g_pTexRed == NULL) D3DXCreateTextureFromFileInMemory(pDevice, (LPCVOID)&red, sizeof(red), &g_pTexRed);
- if (g_pTexOrange == NULL) D3DXCreateTextureFromFileInMemory(pDevice, (LPCVOID)&orange, sizeof(orange), &g_pTexOrange);
- if (g_pTexGreen == NULL) D3DXCreateTextureFromFileInMemory(pDevice, (LPCVOID)&green, sizeof(green), &g_pTexGreen);
- if (g_pTexBlue == NULL) D3DXCreateTextureFromFileInMemory(pDevice, (LPCVOID)&blue, sizeof(blue), &g_pTexBlue);
- ShowMenuOptions(pDevice);
- if (ENABLE_AIMBOT) AimEnemy(pDevice);
- if (ENABLE_CROSSHAIR) ShowCrossHair(pDevice, viewport, 10, RED);
- return oEndScene(pDevice);
- }
- HRESULT WINAPI hkDrawIndexedPrimitive(LPDIRECT3DDEVICE9 pDevice, D3DPRIMITIVETYPE PrimType, INT BaseVertexIndex, UINT MinVertexIndex, UINT NumVertices, UINT startIndex, UINT primCount)
- {
- if (viewport.Width <= 100) return oDrawIndexedPrimitive(pDevice, PrimType, BaseVertexIndex, MinVertexIndex, NumVertices, startIndex, primCount);
- if (pDevice->GetStreamSource(0, &pStreamData, &XOffset, &Stride) == D3D_OK) if (pStreamData != NULL) { pStreamData->Release(); pStreamData = NULL; }
- bool isBEAR = Stride == 40 && (((NumVertices == 452) && (primCount == 434)) || ((NumVertices == 1099) && (primCount == 1222)) || ((NumVertices == 859) && (primCount == 1272)) || ((NumVertices == 192) && (primCount == 256)) || ((NumVertices == 1618) && (primCount == 2004)) || ((NumVertices == 114) && (primCount == 194)) || ((NumVertices == 612) && (primCount == 288)) || ((NumVertices == 651) && (primCount == 957)) || ((NumVertices == 530) && (primCount == 936)) || ((NumVertices == 724) && (primCount == 8)) || ((NumVertices == 651) && (primCount == 957)));
- bool isUSEC = Stride == 40 && (((NumVertices == 279) && (primCount == 335)));
- if (ENABLE_AIMBOT == true)
- {
- if (isBEAR || isUSEC)
- {
- if (isBEAR)
- {
- AddEnemy(pDevice, 0);
- if (ENABLE_CHAMS) CreatePlayerChams(pDevice, PrimType, BaseVertexIndex, MinVertexIndex, NumVertices, startIndex, primCount, g_pTexOrange, g_pTexRed);
- }
- else if (isUSEC)
- {
- AddEnemy(pDevice, 1);
- if (ENABLE_CHAMS) CreatePlayerChams(pDevice, PrimType, BaseVertexIndex, MinVertexIndex, NumVertices, startIndex, primCount, g_pTexBlue, g_pTexGreen);
- }
- }
- }
- return oDrawIndexedPrimitive(pDevice, PrimType, BaseVertexIndex, MinVertexIndex, NumVertices, startIndex, primCount);
- }
- void InitHOOK(DWORD* table)
- {
- LPDIRECT3DDEVICE9 pd3dDevice;
- pd3dDevice = GETp3dDevice();
- DWORD* pVTable = (DWORD*)pd3dDevice;
- pVTable = (DWORD*)pVTable[0];
- table[ENDSCENE] = pVTable[42];
- table[DIP] = pVTable[82];
- table[RESET] = pVTable[16];
- }
- bool CustomWPM(HANDLE hProcess, LPVOID lpBaseAddress, byte* lpBuffer, char* mask)
- {
- DWORD dwOldProtectionState;
- DWORD dummy;
- BOOL result = FALSE;
- DWORD Addr = (DWORD)lpBaseAddress;
- for (; *mask; mask++, lpBuffer++, Addr++)
- {
- if (*mask == 'x')
- {
- if (VirtualProtectEx(hProcess, (LPVOID)Addr, 1, PAGE_READWRITE, &dwOldProtectionState) == TRUE)
- {
- result = WriteProcessMemory(hProcess, (LPVOID)Addr, &*lpBuffer, 1, NULL);
- VirtualProtectEx(hProcess, (LPVOID)Addr, 1, dwOldProtectionState, &dummy);
- }
- }
- }
- return result;
- }
- bool DataCompare(byte* pData, byte* pattern, char* mask)
- {
- for (; *mask; mask++, pattern++, pData++)
- {
- if (*mask == 'x' && *pData != *pattern)
- return false;
- }
- return true;
- }
- vector<DWORD> FindPattern(HANDLE hProcess, DWORD addr, DWORD length, byte* pattern, char* mask)
- {
- MEMORY_BASIC_INFORMATION mbi = { 0 };
- DWORD offset = 0;
- DWORD dwTemp;
- vector<DWORD> Enderecos;
- while (offset < length)
- {
- VirtualQueryEx(hProcess, (LPCVOID)(addr + offset), &mbi, sizeof(MEMORY_BASIC_INFORMATION));
- //if (mbi.State != MEM_FREE) //Aqui procura todo tipo de memória
- if (mbi.Type == MEM_PRIVATE && (mbi.State != MEM_RESERVE))//Aqui é um filtro... localizou muito rápido e funciona no CW (15SET2015)
- {
- byte* buffer = new byte[mbi.RegionSize];
- ReadProcessMemory(hProcess, mbi.BaseAddress, buffer, mbi.RegionSize, NULL);
- for (unsigned int i = 0; i < mbi.RegionSize; i++)
- {
- if (DataCompare(buffer + i, pattern, mask))
- {
- dwTemp = (DWORD)mbi.BaseAddress + i;
- Enderecos.push_back(dwTemp);
- }
- }
- delete[] buffer;
- }
- offset += mbi.RegionSize;
- }
- return Enderecos;
- }
- DWORD GetBaseAddr(DWORD id)
- {
- MODULEINFO modinfo = { 0 };
- GetModuleInformation((HANDLE)id, GetModuleHandle(NULL), &modinfo, sizeof(MODULEINFO));
- return (DWORD)modinfo.lpBaseOfDll;
- }
- DWORD WINAPI StartingHACK(LPVOID)
- {
- vector<DWORD> Addresses;
- while (GetModuleHandle("d3d9.dll") == NULL)
- {
- Sleep(250);
- }
- DWORD BaseAddr = GetBaseAddr((DWORD)GetCurrentProcess());
- HANDLE hProcess = OpenProcess(PROCESS_ALL_ACCESS, FALSE, GetCurrentProcessId());
- Addresses = FindPattern(hProcess, BaseAddr, 0x7FFFFFFF, (PBYTE)"\x02\x28\x00\x00\x00\x00\x18\x40\x00\x00\x00\x00\x22\x00\x00\x80\x40\x2A\x02\x28\x00\x00\x00\x00\x17", "xx????xx????x??xxxxx????x");
- if (Addresses.size() != NULL)
- {
- DWORD Addr;
- for (unsigned int a = 0; a < Addresses.size(); a++)
- {
- Addr = Addresses[a];
- CustomWPM(hProcess, (LPVOID)Addr, (PBYTE)"\x22\x00\x00\x00\x00\x2A", "xxxxxx");
- }
- Addresses.clear();
- }
- DWORD VTable[3] = { 0 };
- InitHOOK(VTable);
- HOOK(EndScene, VTable[ENDSCENE]);
- HOOK(DrawIndexedPrimitive, VTable[DIP]);
- HOOK(Reset, VTable[RESET]);
- return 0;
- }
- BOOL WINAPI DllMain(HMODULE hModule, DWORD dwReason, LPVOID lpvReserved)
- {
- if (dwReason == DLL_PROCESS_ATTACH)
- {
- CreateThread(0, 0, StartingHACK, 0, 0, 0);
- }
- return TRUE;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement