22.10.2014, 20:15
Hey guys i have this code it dosn't spawn a vehicle in the given co-ordinates it does deduct the money but nothing else happen let me know the error?
PHP код:
if(strcmp(text, "1", true) == 0 && UserStats[playerid][Spawned] == 1 && ActiveMenu[playerid][BoatShop1] == 1) //
{
if(RecentPurchasedCar[playerid] >= 1) { SendClientMessage(playerid,COLOR_RED,"You Have Recently Purchased A Vehicle, Please Wait."); return 0; }
if(PlayerCash[playerid] < 15000) { SendClientMessage(playerid,COLOR_RED,"You Do Not Have Enough Money To Buy A Dinghy!"); return 0; }
SendClientMessage(playerid,COLOR_YAY,"You Have Purchased A Dinghy For $15000 From Boat Shop, Enjoy!");
PlayerCash[playerid] -= 15000;
GameTextForPlayer(playerid,"~w~Purchased A ~p~Dinghy",5000,4);
new vehicle;
vehicle = CreateVehicle(473, 1638.9403,580.1939,-0.5031,177.0388, -1, -1, -1);
BoughtVehicle[vehicle] = 1;
RecentPurchasedCar[playerid] = 60;
HideBox(playerid);
return 1;
}