Pastebin is 300% more awesome when you are logged in. Sign Up, it's FREE!
Guest

Untitled

By: Nuukem on Feb 27th, 2012  |  syntax: C++  |  size: 0.74 KB  |  hits: 147  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. /*
  2. YOU ARE FREE TO REDISTRIBUTE AND USE THIS PIECE OF WORK AS LONG AS
  3. CREDITS TO THE AUTHOR, Nukem, ARE CLEARLY STATED.
  4. */
  5.  
  6. typedef void (__cdecl * tCBuf_AddText)(int unk1, char *Cmd);
  7. tCBuf_AddText CBuf_AddText = (tCBuf_AddText)0x00461A30;
  8.  
  9. DWORD WINAPI MainThread(LPVOID lpArg)
  10. {
  11.         char buf[1024];
  12.  
  13.         while(true)
  14.         {
  15.                 if(GetAsyncKeyState(VK_F6))
  16.                 {
  17.                         sprintf_s(buf, "mr %d -1 endround;", *(int*)0x0FF5450);
  18.                         CBuf_AddText(0, buf);
  19.  
  20.                         Sleep(500);
  21.                 }
  22.  
  23.                 Sleep(250);
  24.         }
  25.  
  26.         return 0;
  27. }
  28.  
  29. BOOL APIENTRY DllMain( HMODULE hModule, DWORD  ul_reason_for_call, LPVOID lpReserved )
  30. {
  31.         switch (ul_reason_for_call)
  32.         {
  33.         case DLL_PROCESS_ATTACH:
  34.                         CreateThread(NULL, NULL, MainThread, NULL, NULL, NULL);
  35.                 break;
  36.         }
  37.         return TRUE;
  38. }