Guest User

by Pater

a guest
Oct 23rd, 2010
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.69 KB | None | 0 0
  1. #include <a_samp>
  2.  
  3. #define COLOR_RED 0xAA3333AA
  4.  
  5. public OnPlayerCommandText(playerid, cmdtext[])
  6. {
  7.     if (strcmp("/pay", cmdtext, true, 10) == 0)
  8.     {
  9.     new money;
  10.     money = GetPlayerMoney(playerid);
  11.         if(IsPlayerInRangeOfPoint(playerid,1110.4412,-1738.2471,13.4317))return SendClientMessage(playerid,COLOR_RED,"You are too far from the gate to pay");
  12.         if(money < 500)return SendClientMessage(playerid,COLOR_RED,"You do not have enough money");
  13.     MoveObject(980, 1101.7249755859, -1741.2767333984, 15.273958206177,2.0);
  14.     SetPlayerMoney(playerid, money-500);
  15.     SendClientMessage(playerid,COLOR_RED,"You have just paid and the gate is open");
  16.         return 1;
  17.      }
  18.      return 0;
  19. }
Advertisement
Add Comment
Please, Sign In to add comment