Hello.
I have a problem with this stock:
I want to delete the vehicle to get a new one but is bugea and it delete the vehicle to the latter that use the command ???
I have a problem with this stock:
pawn Code:
CrearVehiculo(playerid, modelid)
{
new Auto, Float:x,Float:y,Float:z,Float:angulo;
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
Auto = GetPlayerVehicleID(playerid);
GetVehiclePos(Auto, x, y, z);
GetVehicleZAngle(Auto, angulo);
}
else
{
GetPlayerPos(playerid, x, y, z);
GetPlayerFacingAngle(playerid, angulo);
}
if(SpawnAuto[playerid] != 0) DestroyVehicle(SpawnAuto[playerid]);
SpawnAuto[playerid] = CreateVehicle(modelid,x,y,z,angulo,-1,-1,60);
PutPlayerInVehicle(playerid,SpawnAuto[playerid],0);
NombreDelAuto(playerid);
LinkVehicleToInterior(Auto, GetPlayerInterior(playerid));
SetVehicleVirtualWorld(Auto, GetPlayerVirtualWorld(playerid));
return 1;
}
{
new Auto, Float:x,Float:y,Float:z,Float:angulo;
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
Auto = GetPlayerVehicleID(playerid);
GetVehiclePos(Auto, x, y, z);
GetVehicleZAngle(Auto, angulo);
}
else
{
GetPlayerPos(playerid, x, y, z);
GetPlayerFacingAngle(playerid, angulo);
}
if(SpawnAuto[playerid] != 0) DestroyVehicle(SpawnAuto[playerid]);
SpawnAuto[playerid] = CreateVehicle(modelid,x,y,z,angulo,-1,-1,60);
PutPlayerInVehicle(playerid,SpawnAuto[playerid],0);
NombreDelAuto(playerid);
LinkVehicleToInterior(Auto, GetPlayerInterior(playerid));
SetVehicleVirtualWorld(Auto, GetPlayerVirtualWorld(playerid));
return 1;
}
I want to delete the vehicle to get a new one but is bugea and it delete the vehicle to the latter that use the command ???
Aucun commentaire:
Enregistrer un commentaire