How do i create a vehicle
#2

Here's a command:

Код:
CMD:veh(playerid, params[])
{
	if(IsPlayerInAnyVehicle(playerid) || GetVehicleModelIDFromName(params[0]) == -1 ||
        GetVehicleModelIDFromName(params[0]) == 520) return true;
	new car, Float:a;
	GetPlayerFacingAngle(playerid, a);
	new Float:oldposx, Float:oldposy, Float:oldposz;
	GetPlayerPos(playerid, oldposx, oldposy, oldposz);
	car = CreateVehicle(GetVehicleModelIDFromName(params[0]),oldposx,oldposy,oldposz,0,0,0,-1);
	SetVehicleVirtualWorld(car, GetPlayerVirtualWorld(playerid));
	PutPlayerInVehicle(playerid,car,0);
	return 1;
}
https://sampwiki.blast.hk/wiki/CreateVehicle
Reply


Messages In This Thread
How do i create a vehicle - by JoanB - 27.03.2014, 08:35
Re: How do i create a vehicle - by SiraBots - 27.03.2014, 08:44
Re: How do i create a vehicle - by ChristianIvann09 - 27.03.2014, 08:44
Re: How do i create a vehicle - by Equuuuin0X - 27.03.2014, 08:54

Forum Jump:


Users browsing this thread: 1 Guest(s)