09.07.2009, 19:27
I have made menu witch spawns tuned cars, but it's not working... when i select car from menu, menu closes, shows message "enjoy your ride'' , but car is not spawned...
here is a part of menu:
what could be wrong?
here is a part of menu:
Код:
if(CurrentMenu3 == TunedVehicles) { switch(row) { case 0: { TogglePlayerControllable(playerid, 1); if (GetPlayerMoney(playerid) >= 0) { if(IsPlayerInAnyVehicle(playerid)) { TogglePlayerControllable(playerid, 0); ShowMenuForPlayer(TunedVehicles,playerid); SendClientMessage(playerid, COLOR_RED, "You are already in car."); return 1; } else { TogglePlayerControllable(playerid, 1); GivePlayerMoney(playerid, -0); CreateVehicle (562, x, y, z + 2.0, a + 90.0, -1, -1, 5000); LinkVehicleToInterior(PlayerVehI[playerid], GetPlayerInterior(playerid)); ChangeVehiclePaintjob(PlayerVehI[playerid],random(2)+1); AddVehicleComponent(PlayerVehI[playerid],1037); AddVehicleComponent(PlayerVehI[playerid],1010); AddVehicleComponent(PlayerVehI[playerid],1035); AddVehicleComponent(PlayerVehI[playerid],1039); AddVehicleComponent(PlayerVehI[playerid],1041); AddVehicleComponent(PlayerVehI[playerid],1086); AddVehicleComponent(PlayerVehI[playerid],1087); AddVehicleComponent(PlayerVehI[playerid],1147); AddVehicleComponent(PlayerVehI[playerid],1148); AddVehicleComponent(PlayerVehI[playerid],1172); SendClientMessage(playerid, COLOR_GREEN, "You selected a tuned Elegy"); } } else { TogglePlayerControllable(playerid, 0); ShowMenuForPlayer(TunedVehicles,playerid); return 1; }}