Advertisement
Guest User

Untitled

a guest
Nov 1st, 2018
415
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.41 KB | None | 0 0
  1. #include "stdafx.h"
  2. #include "Tools/Hacks/Misc.h"
  3.  
  4. extern std::string settingstostring();
  5. extern void savesets();
  6.  
  7. bool Unhook_Cheat = false;
  8. auto ExitCheat() -> bool;
  9.  
  10. void Unhook()
  11. {
  12. Unhook_Cheat = true;
  13. }
  14.  
  15. void SaveSettings()
  16. {
  17. settingstostring();
  18. }
  19.  
  20. void LoadSettings()
  21. {
  22. savesets();
  23. }
  24.  
  25. bool ExitCheat()
  26. {
  27. if (!Unhook_Cheat)
  28. {
  29. return false;
  30. }
  31.  
  32. Interfaces.pEngine->ClientCmd_Unrestricted("clear", 0);
  33. Interfaces.pEngine->ClientCmd_Unrestricted("cl_mouseenable 1", 0);
  34. Sleep(100);
  35. Interfaces.pEngine->ClientCmd_Unrestricted("crosshair 1", 0);
  36. Sleep(100);
  37. Interfaces.pEngine->ClientCmd_Unrestricted("firstperson", 0);
  38. Sleep(100);
  39.  
  40. if (Interfaces.pEngine->IsInGame() && Interfaces.pEngine->IsConnected())
  41. {
  42. Misc::SetClanTag("", Hacks.LocalPlayer->GetName().c_str());
  43. Sleep(100);
  44. }
  45.  
  46. Hacks.UnHook();
  47. Sleep(200);
  48.  
  49. SetWindowLongPtr(INIT::Window, GWL_WNDPROC, reinterpret_cast<LONG_PTR>(INIT::OldWindow));
  50. Sleep(200);
  51.  
  52. FreeLibraryAndExitThread(INIT::Dll, 0);
  53. }
  54.  
  55. DWORD WINAPI CheatMain(LPVOID lpThreadParameter)
  56. {
  57. Interfaces.InitialiseSDK();
  58.  
  59. CNetvarManager::Instance()->CreateDatabase();
  60.  
  61. Hacks.Hook();
  62.  
  63. auto EngineBuildNumber = Interfaces.pEngine->GetEngineBuildNumber();
  64. {
  65. Interfaces.pEngine->ClientCmd_Unrestricted("clear", 0);
  66.  
  67. while (!Unhook_Cheat)
  68. {
  69. Misc::ServerRankReveal();
  70. Sleep(15);
  71. }
  72.  
  73. //ExitCheat();
  74. }
  75. return 0;
  76. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement