Advertisement
Tugamars_PT

Sistema de Pedágio [v0.1] By: Tugamars

Dec 1st, 2013
611
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 3.12 KB | None | 0 0
  1. #define FILTERSCRIPT
  2.  
  3. #include <a_samp>
  4.  
  5. #pragma tabsize 0
  6.  
  7. forward fecharlvls();
  8. forward fecharlslv();
  9.  
  10. new CancelaLVLS;
  11. new CancelaLSLV;
  12.  
  13. public OnFilterScriptInit()
  14. {
  15.     print("\n--------------------------------------");
  16.     print(" Sistema de Pedágios By: Tugamars       ");
  17.     print("--------------------------------------\n");
  18.     //Pedagio LV LS
  19.     //Laterais
  20.     CreateObject(979, 1812.13989, 805.36542, 10.42910,   0.00000, 0.00000, 178.75070);
  21.     CreateObject(978, 1781.99170, 804.51849, 10.36460,   0.00000, 0.00000, 179.42149);
  22.     CreateObject(978, 1811.90137, 819.88654, 9.98615,   0.00000, 0.00000, 0.00000);
  23.     CreateObject(979, 1782.73938, 819.75769, 9.99752,   0.00000, 0.00000, 0.00000);
  24.     //Lampadas
  25.     CreateObject(3877, 1798.24463, 806.10339, 10.40543,   0.00000, 0.00000, 0.00000);
  26.     CreateObject(3877, 1808.45886, 806.91925, 10.40543,   0.00000, 0.00000, 0.00000);
  27.     CreateObject(3877, 1796.03662, 820.09576, 10.10944,   0.00000, 0.00000, 0.00000);
  28.     CreateObject(3877, 1786.30347, 818.96729, 10.10944,   0.00000, 0.00000, 0.00000);
  29.     //Cancela
  30.     CancelaLVLS = CreateObject(968, 1788.48254, 810.79248, 10.79725,   0.00000, 90.00000, 357.00000);
  31.     CancelaLSLV = CreateObject(968, 1799.02673, 814.75079, 10.79720,   0.00000, 90.00000, 357.00000);
  32.     //Resto
  33.     CreateObject(8556, 1797.39087, 812.63733, 13.98732,   0.00000, 0.00000, 0.00000);
  34.     CreateObject(8168, 1786.40283, 812.52698, 11.58143,   0.00000, 0.00000, 104.01295);
  35.     CreateObject(8168, 1808.45154, 812.57507, 11.58143,   0.00000, 0.00000, 286.69287);
  36.  
  37.     //Fim Pedagio LV-LS
  38.     return 1;
  39. }
  40.  
  41. public OnFilterScriptExit()
  42. {
  43.     print("\n--------------------------------------");
  44.     print(" Sistema de Pedágios By: Tugamars       ");
  45.     print("--------------------------------------\n");
  46.  
  47.  
  48.  
  49.     return 1;
  50. }
  51. public OnPlayerCommandText(playerid, cmdtext[])
  52. {
  53.     if (strcmp("/pedagio", cmdtext, true, 10) == 0)
  54.     {
  55.        
  56.  
  57.  
  58.         if(IsPlayerInRangeOfPoint(playerid, 3.0, 1802.4081, 812.8696, 10.6952))
  59.         {
  60.            
  61.  
  62.  
  63.             if(GetPlayerMoney(playerid) < 50)
  64.             {
  65.                
  66.  
  67.  
  68.                 SendClientMessage(playerid, 0xF20006FF, "Você não tem dinheiro suficiente");
  69.             }
  70.             if(GetPlayerMoney(playerid) >= 50)
  71.             {
  72.                
  73.  
  74.  
  75.                 GivePlayerMoney(playerid, -50);
  76.                 SetObjectRot(CancelaLSLV, 0.00000, 18.00000, 357.00000);
  77.                 SendClientMessage(playerid, 0xF47A00FF, "Bem vindo a Las Venturas .Foi debitado 50R$ na sua conta .");
  78.                 SetTimer("fecharlslv", 5000, false);
  79.             }
  80.         }
  81.     }
  82.     if(IsPlayerInRangeOfPoint(playerid, 3.0, 1792.0217, 816.1849, 10.8929))
  83.     {
  84.        
  85.  
  86.  
  87.         if(GetPlayerMoney(playerid) < 50)
  88.         {
  89.            
  90.  
  91.  
  92.             SendClientMessage(playerid, 0xF20006FF, "Você não tem dinheiro suficiente");
  93.         }
  94.         if(GetPlayerMoney(playerid) >= 50)
  95.         {
  96.            
  97.  
  98.  
  99.             GivePlayerMoney(playerid, -50);
  100.             SetObjectRot(CancelaLVLS,  0.00000, 18.00000, 357.00000);
  101.             SendClientMessage(playerid, 0xF47A00FF, "Bem vindo a Los Santos .Foi debitado 50R$ na sua conta .");
  102.             SetTimer("fecharlvls", 5000, false);
  103.         }
  104.  
  105.         return 1;
  106.     }
  107.     return 0;
  108. }
  109.  
  110. public fecharlvls()
  111. {
  112.     SetObjectRot(CancelaLVLS,  0.00000, 90.00000, 357.00000);
  113. }
  114. public fecharlslv()
  115. {
  116.     SetObjectRot(CancelaLSLV, 0.00000, 90.00000, 357.00000);
  117. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement