Spawning cars in interiors, Need help.
#1

I have this script that spawns you a car on command. But in places such as arenas it just stays invisible even if it says to link the interior to the vehicle...

Код:
if(strcmp(cmd, "/aspawncar", true) == 0)
	{
	  if(IsPlayerConnected(playerid))
	  {
	    if (PlayerInfo[playerid][pAdmin] < 3)
			{
			  SendClientMessage(playerid, COLOR_GRAD1, "You're not the sufficient administrators rank.");
			  return 1;
			}
			tmp = strtok(cmdtext, idx);
			if(!strlen(tmp))
			{
				SendClientMessage(playerid, COLOR_GRAD2, "SYNTAX - /aspawncar [carid]");
				return 1;
			}
			new car;
			car = strval(tmp);
			if(car < 400 || car > 611) { SendClientMessage(playerid, COLOR_WHITE, "IDs must be between 400 and 611."); return 1; }
      new Float:XX, Float:YY, Float:ZZ;
			GetPlayerPos(playerid, XX,YY,ZZ);
			new carsp = CreateVehicle(car, XX,YY,ZZ, 0.0, random(126), random(126), -1);
			LinkVehicleToInterior(carsp, GetPlayerInterior(playerid));
		}
		return 1;
	}
EDIT: Its bit messed up, but its not because of that, something in the code
Reply


Messages In This Thread
Spawning cars in interiors, Need help. - by Antiono_Costa - 18.08.2009, 19:41
Re: Spawning cars in interiors, Need help. - by CAR - 18.08.2009, 19:59
Re: Spawning cars in interiors, Need help. - by bubka3 - 18.08.2009, 20:04
Re: Spawning cars in interiors, Need help. - by CAR - 18.08.2009, 20:05
Re: Spawning cars in interiors, Need help. - by Antiono_Costa - 19.08.2009, 10:17

Forum Jump:


Users browsing this thread: 1 Guest(s)