SorinAlex

Untitled

Jan 27th, 2014
135
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.46 KB | None | 0 0
  1. #include <iostream>
  2. #include <string>
  3. #include <windows.h>
  4.  
  5. using namespace std;
  6.  
  7. HANDLE console = GetStdHandle(STD_OUTPUT_HANDLE);
  8. COORD CursorPosition;
  9.  
  10. void gotoXY(int x, int y, string text);
  11. void gotoXY(int x, int y);
  12.  
  13. int main(int)
  14. {
  15. string Plane[]=
  16. {" _ "
  17. ," -=\\`\\ "
  18. ," |\\ ____\\_\\__ "
  19. ," -=\\c`\"\"\"\"\"\"\" \"`) "
  20. ," `~~~~~/ /~~` "
  21. ," -==/ / "
  22. ," '-' "};
  23.  
  24. string cloud[]=
  25. {" _ _ "
  26. ," ( ` )_ "
  27. ," ( ) `) "
  28. ," (_ (_ . _) _) "};
  29.  
  30.  
  31. char holder = ' ';
  32.  
  33. int len, x, y;
  34.  
  35. len = Plane[0].length();
  36. string border(len,'\xCD');
  37. string shadow(len+2,'\xB2');
  38. cout << "\t \xC9" << border << "\xBB" << endl;
  39. for (x=0;x<11;x++)
  40. cout<<"\t \xBA \xBA\xB2"<<endl;
  41. cout<<"\t \xBA _ \xBA\xB2"<<endl;
  42. cout<<"\t \xBA ( ) \xBA\xB2"<<endl;
  43. cout<<"\t \xBA _ . ( ` ) . ) \xBA\xB2"<<endl;
  44. cout<<"\t \xBA ( _ )_ (_, _( ,_)_) \xBA\xB2"<<endl;
  45. cout<<"\t \xBA (_ _(_ ,) \xBA\xB2"<<endl;
  46. cout << "\t \xC8" << border << "\xBC\xB2" << endl;
  47. cout << "\t " << shadow << endl;
  48. do{
  49. for (y=0;y<7;y++)
  50. {
  51. gotoXY(11,1+y,Plane[y]);
  52. }
  53.  
  54. for (x=0;x<4;x++)
  55. {
  56. gotoXY(11,8+x,cloud[x]);
  57. }
  58.  
  59. for (y=0;y<7;y++)
  60. {
  61. holder = Plane[y][len];
  62. for (x=len;x>0;x--)
  63. {
  64. Plane[y][x]=Plane[y][x-1];
  65. }
  66. Plane[y][0]=holder;
  67. }
  68.  
  69. for (y=0;y<4;y++)
  70. {
  71. holder = cloud[y][0];
  72. for (x=0;x<len;x++)
  73. {
  74. cloud[y][x]=cloud[y][x+1];
  75. }
  76. cloud[y][len]=holder;
  77. }
  78. Sleep(60);
  79. }while(true);
  80. return 0;
  81. }
  82.  
  83. void gotoXY(int x, int y, string text)
  84. {
  85. CursorPosition.X = x;
  86. CursorPosition.Y = y;
  87. SetConsoleCursorPosition(console,CursorPosition);
  88. cout << text;
  89. }
Advertisement
Add Comment
Please, Sign In to add comment