Guest User

Untitled

a guest
Feb 9th, 2012
375
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 5.00 KB | None | 0 0
  1. #include <a_samp>
  2.  
  3. #define max_players         222
  4.  
  5. new Text:IntroText[6];
  6. new IntroIteration[max_players];
  7.  
  8. public OnFilterScriptInit()
  9. {
  10.     IntroText[0] = TextDrawCreate(642.0,1.0,"~n~");
  11.     TextDrawLetterSize(IntroText[0],0.5,49.5);
  12.     TextDrawUseBox(IntroText[0],1);
  13.     TextDrawBoxColor(IntroText[0],0x000000FF);
  14.     TextDrawTextSize(IntroText[0],-2.0,0.0);
  15.    
  16.     IntroText[1] = TextDrawCreate(190.000000,190.000000,"~p~~h~Dragon_Knight");
  17.     TextDrawFont(IntroText[1],2);
  18.     TextDrawLetterSize(IntroText[1],0.570000,1.799999);
  19.    
  20.     IntroText[2] = TextDrawCreate(310.000000,213.000000,"present...");
  21.     TextDrawFont(IntroText[2],2);
  22.     TextDrawLetterSize(IntroText[2],0.570000,1.799999);
  23.    
  24.     IntroText[3] = TextDrawCreate(190.0,235.0,".");
  25.     TextDrawFont(IntroText[3],1);
  26.     TextDrawLetterSize(IntroText[3],23.250051,1.099999);
  27.    
  28.     IntroText[4] = TextDrawCreate(304.00,246.0,"~y~~h~Mafia Wars 2.1");
  29.     TextDrawFont(IntroText[4],2);
  30.     TextDrawLetterSize(IntroText[4],0.340000,1.099999);
  31.    
  32.     IntroText[5] = TextDrawCreate(331.0,258.0,"~g~~h~gta.qth-mo.ru");
  33.     TextDrawFont(IntroText[5],2);
  34.     TextDrawLetterSize(IntroText[5],0.340000,1.099999);
  35.    
  36.     return 1;
  37. }
  38.  
  39. public OnPlayerConnect(playerid)
  40. {
  41.     //TogglePlayerSpectating(playerid,true);
  42.     //ForceClassSelection(playerid);
  43.     IntroIteration[playerid] = 0;
  44.     SetTimerEx("ShowIntro",1000,0,"d",playerid);
  45.    
  46.     return 1;
  47. }
  48.  
  49. forward ShowIntro(playerid);
  50. public ShowIntro(playerid)
  51. {
  52.     IntroIteration[playerid]++;
  53.     switch(IntroIteration[playerid])
  54.     {
  55.         case 1:
  56.             {
  57.                 for(new i; i < 11; i++) SendClientMessage(playerid,-1,"");
  58.                 TextDrawShowForPlayer(playerid,IntroText[0]);
  59.             }
  60.         case 2:
  61.             {
  62.                 TextDrawShowForPlayer(playerid,IntroText[1]);
  63.             }
  64.         case 3:
  65.             {
  66.                 TextDrawColor(IntroText[2],0xFFFFFF00);
  67.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  68.             }
  69.         case 4:
  70.             {
  71.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  72.                 TextDrawColor(IntroText[2],0xFFFFFF11);
  73.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  74.             }
  75.         case 5:
  76.             {
  77.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  78.                 TextDrawColor(IntroText[2],0xFFFFFF22);
  79.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  80.             }
  81.         case 6:
  82.             {
  83.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  84.                 TextDrawColor(IntroText[2],0xFFFFFF33);
  85.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  86.             }
  87.         case 7:
  88.             {
  89.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  90.                 TextDrawColor(IntroText[2],0xFFFFFF44);
  91.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  92.             }
  93.         case 8:
  94.             {
  95.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  96.                 TextDrawColor(IntroText[2],0xFFFFFF55);
  97.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  98.             }
  99.         case 9:
  100.             {
  101.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  102.                 TextDrawColor(IntroText[2],0xFFFFFF66);
  103.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  104.             }
  105.         case 10:
  106.             {
  107.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  108.                 TextDrawColor(IntroText[2],0xFFFFFF77);
  109.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  110.             }
  111.         case 11:
  112.             {
  113.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  114.                 TextDrawColor(IntroText[2],0xFFFFFF88);
  115.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  116.             }
  117.         case 12:
  118.             {
  119.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  120.                 TextDrawColor(IntroText[2],0xFFFFFF99);
  121.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  122.             }
  123.         case 13:
  124.             {
  125.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  126.                 TextDrawColor(IntroText[2],0xFFFFFFAA);
  127.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  128.             }
  129.         case 14:
  130.             {
  131.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  132.                 TextDrawColor(IntroText[2],0xFFFFFFBB);
  133.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  134.             }
  135.         case 15:
  136.             {
  137.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  138.                 TextDrawColor(IntroText[2],0xFFFFFFCC);
  139.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  140.             }
  141.         case 16:
  142.             {
  143.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  144.                 TextDrawColor(IntroText[2],0xFFFFFFDD);
  145.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  146.             }
  147.         case 17:
  148.             {
  149.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  150.                 TextDrawColor(IntroText[2],0xFFFFFFEE);
  151.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  152.             }
  153.         case 18:
  154.             {
  155.                 TextDrawHideForPlayer(playerid,IntroText[2]);
  156.                 TextDrawColor(IntroText[2],0xFFFFFFFF);
  157.                 TextDrawShowForPlayer(playerid,IntroText[2]);
  158.             }
  159.         case 19:
  160.             {
  161.                 TextDrawShowForPlayer(playerid,IntroText[3]);
  162.             }
  163.         case 20:
  164.             {
  165.                 TextDrawShowForPlayer(playerid,IntroText[4]);
  166.             }
  167.         case 21:
  168.             {
  169.                 TextDrawShowForPlayer(playerid,IntroText[5]);
  170.             }
  171.     }
  172.     if(IntroIteration[playerid] < 20) SetTimerEx("ShowIntro",100,0,"d",playerid);
  173.     else if(IntroIteration[playerid] < 22) SetTimerEx("ShowIntro",2000,0,"d",playerid);
  174.     else
  175.     {
  176.         for(new i; i < sizeof(IntroText); i++) TextDrawHideForPlayer(playerid,IntroText[i]);
  177.         //TogglePlayerSpectating(playerid,false);
  178.         //ForceClassSelection(playerid);
  179.     }
  180.    
  181.     return 1;
  182. }
  183.  
  184. public OnFilterScriptExit()
  185. {
  186.     for(new i; i < sizeof(IntroText); i++) TextDrawDestroy(IntroText[i]);
  187.    
  188.     return 1;
  189. }
Advertisement
Add Comment
Please, Sign In to add comment