KaLu17

[command] Health

May 3rd, 2014
304
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.55 KB | None | 0 0
  1. CMD:hp(playerid, params[])
  2. {
  3.     new Float:zycie, text[128];
  4.     if(sscanf(params, "f", zycie))
  5.         return SendClientMessage(playerid, -1, "Użyj: /hp [ilosc]");
  6.     if(GetPlayerMoney(playerid) < 100)
  7.         return SendClientMessage(playerid, -1, "Nie posiadasz wystarczającej ilości pieniędzy, aby móc uzupełnić życie.");
  8.  
  9.     format(text, sizeof(text), "Twój stan HP został pomyślnie uzupełniony na %f, kosztem $100.", zycie);
  10.     SendClientMessage(playerid, -1, text);
  11.     SetPlayerHealth(playerid, zycie), GivePlayerMoney(playerid, -100);        
  12.     return 1;
  13. }
Advertisement
Add Comment
Please, Sign In to add comment