13.10.2014, 17:43
pawn Код:
public OnPlayerEnterCheckpoint(playerid)
{
if(g_var[playerid] == 0 && IsPlayerInRangeOfPoint(playerid, 5, 2789.6619, -2517.8105, 16.1509))
{
if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER) return SendClientMessage(playerid, COLOR_GREY, "You are not inside a vehicle.");
new
amount = random(300) + 100,
string[128]
;
DisablePlayerCheckpoint(playerid);
format(string, sizeof(string), "*You've earned {FF6347}$%d{33CCFF} from dropping a car!", amount);
SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
GiveDodMoney(playerid, amount);
SetVehicleToRespawn(GetPlayerVehicleID(playerid));
g_var[playerid] = 1;
SetTimerEx("CountDown", 1200 * 1000, false, "d", playerid);
}
return 1;
}