Guest User

Untitled

a guest
Oct 15th, 2018
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.32 KB | None | 0 0
  1. // Rapid Fire.cpp : Defines the entry point for the console application.// Copyright 2013 @ EPiC REV
  2.  
  3.  
  4. #include "stdafx.h"
  5. #include <iostream>
  6. #include <Windows.h>
  7. #include <time.h>
  8.  
  9.  
  10. using namespace std;
  11.  
  12.  
  13. int main()
  14. {
  15. cout << "===============================================================================" << endl;
  16. cout << "External Rapid Fire by EPiC REV (Copyright 2013 @ EPiC REV). Works in any game!" << endl;
  17. cout << "===============================================================================" << endl;
  18. cout << "Press right-click in game to rapid fire." << endl;
  19.  
  20.  
  21. bool RapidFire = false;
  22. int AutoFireTimer = clock();
  23. int currentTime;
  24. bool MouseDown = false;
  25. while(true)
  26. {
  27. //Check for right mouse button to be down.
  28. if(GetAsyncKeyState(VK_RBUTTON) & 0x8000)RapidFire = true;
  29. else RapidFire = false;
  30.  
  31.  
  32. if(RapidFire)
  33. {
  34. //only go if so many milliseconds have passed.
  35. if(!MouseDown)
  36. {
  37. MouseDown = true;
  38. mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0); //
  39. }
  40. if(clock() - AutoFireTimer > 21)
  41. {
  42. MouseDown = false;
  43. mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0); //
  44. AutoFireTimer = clock();
  45. }
  46. }
  47. }
  48.  
  49. }
Add Comment
Please, Sign In to add comment