, im posting this because i need a little bit of help on doing a code for my gamemode . a IsPlayerInArea with this cords -385.3699, 1448.057, 665.6389, 2685.911-385.3699, 1448.057, 665.6389, 2685.911
389.8672,2543.0046,16.5391
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if( newstate == PLAYER_STATE_DRIVER )
{
if( GetVehicleModel(GetPlayerVehicleID(playerid)) == 520 || GetVehicleModel(GetPlayerVehicleID(playerid)) == 425 ||
GetVehicleModel(GetPlayerVehicleID(playerid)) == 432 )
{
SendClientMessage(playerid, COLOR_LIGREEN, "<!> AS ENTRADO A UN VEHICULO DE GUERRA! NO PODRAS SALIR DE ESTA ZONA CON ESTE COCHE");
SendClientMessage(playerid, COLOR_LIGREEN, "PARA PODER SALIR DE ZONA DE GUERRA SAL DEL VEHICULO DE I BUSCA OTRO COCHE QUE NO SEA DE ESTOS");
SetPlayerWorldBounds(playerid, 677.3168, -478.7929, 2849.402, 1494.768);
}
}
if( oldstate == PLAYER_STATE_DRIVER )
{
SetPlayerWorldBounds(playerid, 3500.0000,-3500.0000,3500.0000,-3500.0000);
}
return 1;
}
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if( newstate == PLAYER_STATE_DRIVER )
{
isPlayerInArea(CordS HERE);
if( GetVehicleModel(GetPlayerVehicleID(playerid)) == 520 || GetVehicleModel(GetPlayerVehicleID(playerid)) == 425 ||
GetVehicleModel(GetPlayerVehicleID(playerid)) == 432 )
{
SetPlayerWorldBounds(playerid, 677.3168, -478.7929, 2849.402, 1494.768);
SetPlayerPoss( etc..._
}
}
if( oldstate == PLAYER_STATE_DRIVER )
{
SetPlayerWorldBounds(playerid, 3500.0000,-3500.0000,3500.0000,-3500.0000);
}
return 1;
}
|
Originally Posted by Pandabeer1337
would only teleport him out of the hydra everytime he steps in
![]() |
|
Originally Posted by FUNExtreme
Go to the wiki and find info about IsPlayerInArea. Follow the example, when you are done we will add the teleporting back!
|
|
Originally Posted by FUNExtreme
No it wont.
Quote:
|