Guest User

Untitled

a guest
Nov 24th, 2017
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.58 KB | None | 0 0
  1. #include <iostream>
  2. #include <Windows.h>
  3.  
  4. using namespace std;
  5.  
  6. int main()
  7. {
  8. HWND hwnd = FindWindowA(NULL, "Plants vs. Zombies");
  9.  
  10. cout << "Sun Hack Loading...";
  11.  
  12. DWORD pId;
  13. GetWindowThreadProcessId(hwnd, &pId);
  14.  
  15. HANDLE hProcess = OpenProcess(PROCESS_VM_OPERATION | PROCESS_VM_WRITE | PROCESS_VM_READ, 0, pId);
  16. DWORD newAdress = 0x0B4A7558;
  17. const unsigned int newValue = 9999;
  18.  
  19. WriteProcessMemory(hProcess, reinterpret_cast<LPVOID>(0x0B4A7558), &newValue, sizeof(newValue), 0);
  20.  
  21. CloseHandle(hProcess);
  22. cin.get();
  23. return 0;
  24.  
  25. }
Add Comment
Please, Sign In to add comment