Problem : Enter the car at death -
wilking - 11.06.2017
I want after death, enter a car next door will be disabled.
Please ask the Pro help .
Re: Problem : Enter the car at death -
Kane - 11.06.2017
Not sure what you're saying.
Do you want cars to be locked for a player after they die?
Re: Problem : Enter the car at death -
wilking - 11.06.2017
Quote:
Originally Posted by Arthur Kane
Not sure what you're saying.
Do you want cars to be locked for a player after they die?
|
Yup , I want cars to be locked for a player after die.
Re: Problem : Enter the car at death -
wilking - 11.06.2017
help me , Pls
Re: Problem : Enter the car at death -
Whatname - 11.06.2017
Will lock all cars for player if he died in a car
PHP код:
public OnPlayerDeath(playerid)
{
if(IsPlayerInAnyVehicle(playerid))
{
for(new i = 0; i < MAX_VEHICLES; i++)
{
SetVehicleParamsForPlayer(i, playerid, 0, 1);
}
}
return 1;
}
or lock only the car player died in
PHP код:
public OnPlayerDeath(playerid)
{
if(IsPlayerInAnyVehicle(playerid))
{
SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid), playerid, 0, 1);
}
return 1;
}
Re: Problem : Enter the car at death -
wilking - 11.06.2017
Quote:
Originally Posted by Whatname
Will lock all cars for player if he died in a car
PHP код:
public OnPlayerDeath(playerid)
{
if(IsPlayerInAnyVehicle(playerid))
{
for(new i = 0; i < MAX_VEHICLES; i++)
{
SetVehicleParamsForPlayer(i, playerid, 0, 1);
}
}
return 1;
}
or lock only the car player died in
PHP код:
public OnPlayerDeath(playerid)
{
if(IsPlayerInAnyVehicle(playerid))
{
SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid), playerid, 0, 1);
}
return 1;
}
|
It is normal, when death is still enter the car next door.
Is there any other solution?
Re: Problem : Enter the car at death -
Dokins - 11.06.2017
Quote:
Originally Posted by Whatname
Will lock all cars for player if he died in a car
PHP код:
public OnPlayerDeath(playerid)
{
if(IsPlayerInAnyVehicle(playerid))
{
for(new i = 0; i < MAX_VEHICLES; i++)
{
SetVehicleParamsForPlayer(i, playerid, 0, 1);
}
}
return 1;
}
or lock only the car player died in
PHP код:
public OnPlayerDeath(playerid)
{
if(IsPlayerInAnyVehicle(playerid))
{
SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid), playerid, 0, 1);
}
return 1;
}
|
This may not work to be honest as players get removed from vehicles upon death, the best method would be to create a variable of the last vehicle ID then OnPlayerDeath, use that variable to set params.
Re: Problem : Enter the car at death -
Private200 - 12.06.2017
I think he is trying to say that he does not want players to enter the car next to them after dying. But this is not possible by default, unless you are using some roleplay script which forces player into 'injured' mode and forces them an animation.