Destroy
#4

i Can Spawn 50000 Vehicle not fixed
this my full code spawn vehicle
PHP код:
CMD:v(playeridparams[])
{
if(
PlayerInfo[playerid][pRank] >= && PlayerInfo[playerid][pRank] <= 8)
{
        new 
Vehicle[50];
        if(!
sscanf(params"s[50]"Vehicle))
        {
                if(
Myveh[playerid]) DestroyVehicle(Myveh[playerid]);
                new 
string[128], Float:Pos[4];
                
GetPlayerPos(playeridPos[0],Pos[1],Pos[2]); GetPlayerFacingAngle(playeridPos[3]);
                new 
veh GetVehicleModelID(Vehicle);
                if(
veh 400 || veh 611) return SendClientMessage(playeridCOLOR_RED"This is not a valid vehicle name! Please try again ");
                if(
IsPlayerInAnyVehicle(playerid)) { DestroyVehicle(GetPlayerVehicleID(playerid)); }
                
GetXYInFrontOfPlayer(playeridPos[0], Pos[1], 5);
                new 
PVeh CreateVehicle(vehPos[0], Pos[1], Pos[2], Pos[3]+90, -1, -1, -1);
                
LinkVehicleToInterior(PVehGetPlayerInterior(playerid)); SetVehicleVirtualWorld(PVehGetPlayerVirtualWorld(playerid));
                
format(stringsizeof string"You spawned a %s. ID: %i. "aVehicleNames[veh 400], veh);
                
SendClientMessage(playeridCOLOR_GREENstring);
        }
        } else return 
SendClientMessage(playeridCOLOR_LIGHTGREEN"Usage: /v [vehiclename] ");
return 
1;

Reply


Messages In This Thread
Destroy - by Desha1 - 02.01.2015, 14:04
AW: Destroy - by CutX - 02.01.2015, 14:15
Re: Destroy - by ATGOggy - 02.01.2015, 14:20
Re: Destroy - by Desha1 - 02.01.2015, 14:23
AW: Re: Destroy - by CutX - 02.01.2015, 14:25
Re: Destroy - by Desha1 - 02.01.2015, 14:33

Forum Jump:


Users browsing this thread: 1 Guest(s)