| 0. 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. 21. 22. 23. 24. 25. 26. 27. 28. 29. 30. | /*
Written by LogicKills
This program incorporates my,
mouse-coordinate program, and my
timer program
*/
#include <windows.h>
#include <ctime>
int main()
{
const int SEC = 20; // put how many seconds you want to click..
const int CURSOR_X = 200; // x-coordinate of mouse
const int CURSOR_Y = 144; // y-coordinate of mouse
SetCursorPos(CURSOR_X,CURSOR_Y);
clock_t delay = SEC *CLOCKS_PER_SEC;
clock_t start = clock();
while(clock() - start < delay)
{
mouse_event(MOUSEEVENTF_LEFTDOWN | MOUSEEVENTF_LEFTUP, 0, 0, 0, 0);
}
return 0;
}
|