跳到正文

个人记录

控制鼠标

leisijun123约 1 分钟
原文
文章信息与版本

文章信息

发布
2026年8月19日
收录
2026年9月28日
更新
2026年11月21日
篇幅
约 1 分钟

版本

  1. v1当前

只需要用一个c++代码,就可以让自己的鼠标自己动 c++代码: #include <bits/stdc++.h> #include <windows.h> using namespace std; int main(){ srand(time(NULL)); cout<<rand()%10+1; for(int i=1;i<=10;i++){ SetCursorPos(rand()%1921,rand()%1080); Sleep(10); } return 0; } sleep是要你的鼠标动多少次 注意:数字不要太大

原文