Snorflake

pSpeed GMOD

May 30th, 2015
555
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.33 KB | None | 0 0
  1. class CMisc
  2. {
  3. public:
  4.  
  5.     void SpeedHack(void* CL_Move, int Factor)
  6.     {
  7.  
  8.         if (!GetAsyncKeyState(VK_LSHIFT))
  9.             return;
  10.  
  11.         DWORD* ReturnAddress = (DWORD*)(*(DWORD*)CL_Move + 0x4);
  12.         if (Speed > 1)
  13.         {
  14.             Speed -= 1;
  15.             *ReturnAddress -= 0x5;
  16.         }
  17.         else
  18.         {
  19.             Speed = Factor;
  20.         }
  21.     }
  22.  
  23. private:
  24.     int Speed;
  25. }; CMisc Misc;
Advertisement
Add Comment
Please, Sign In to add comment