Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <string>
- #include<windows.h>
- using namespace std;
- int main(){
- // POINT p;
- system("color a");
- cout << "==========================================" << endl;
- cout << "== KNIVES OUT Macro by z NzLeoGenX_x ==" << endl;
- cout << "== KNIVES OUT Macro by z NzLeoGenX_x ==" << endl;
- cout << "== Ativar: CapsLock ==" << endl;
- cout << "==========================================" << endl;
- while(true){
- Sleep(20);
- //GetCursorPos(&p);
- //cout << "X: " << p.x << endl;
- //cout << "Y: " << p.y << endl;
- //system("cls");
- //0x14 = caps lock
- //codigos: https://msdn.microsoft.com/pt-br/library/windows/desktop/dd375731(v=vs.85).aspx
- if(GetAsyncKeyState(0x14) & 0x8000){
- mouse_event(MOUSEEVENTF_LEFTDOWN, 0, 0, 0, 0);
- Sleep(50);
- mouse_event(MOUSEEVENTF_LEFTUP, 0, 0, 0, 0);
- //Tem que deixar um Sleep aqui ou buga
- // SetCursorPos(p.x -1 ,p.y + 2);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement