19.04.2017, 14:30
PHP код:
case 14:
{
if(CanCAR{playerid} == false) return SendClientMessage(playerid, RED, "Please wait before buying any vehicle.");//
if(GetPlayerCash(playerid) > 33000)
{
new CarOne;
new CarOwnerName[24];
GetPlayerName(playerid,CarOwnerName,24);
CarOne = CreateVehicle(411, 1986.0886,2049.7493,10.5474,135.5690, -1, -1, -1);
SetVehicleNumberPlate(CarOne, pData[playerid][NumPlate]);
GivePlayerCashExx(playerid, -33000);
PutPlayerInVehicle(playerid,CarOne,0);
PurchasedCar[CarOne] = 999;
SendClientMessage(playerid, GREEN, "You have purchased a Infernus for $33,000");
CanCAR{playerid} = false;
SetTimerEx("WaitToBuyCar", 8*60000, false, "d", playerid);
}
if (GetPlayerCash(playerid) < 33000)
{
SendClientMessage(playerid, RED, "You don't have enough cash.");
}
}
Thank you!