02.11.2015, 17:26
PHP код:
if(PRESSED(KEY_SECONDARY_ATTACK)){
if(GetPlayerMoney(playerid) >= 1){
if(IsPlayerInRangeOfPoint(playerid, 1.0, 320.1455,1733.6205,997.6163)){
new Float:HP;
GetPlayerHealth(playerid, HP);
if(HP < 100.0){
HP += 20.0;
if(HP > 100.0) HP = 100.0;
SetPlayerHealth(playerid, HP);
GivePlayerMoney(playerid, -1);
ApplyAnimation(playerid,"VENDING","VEND_Use",1.4,0 ,1,1,0,2500,1);
}
}
}
}