pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & KEY_SECONDARY_ATTACK )
{
if(IsPlayerInRangeOfPoint( playerid,3.0,1172.8816,-1321.5386,15.3990))
{
SetPlayerPos( playerid,40,2,1000);
SetPlayerInterior(playerid,1);
return SendClientMessage(playerid, COLOR_GREEN, "Dobro dosli u Bolnicu.");
}
else if(IsPlayerInRangeOfPoint(playerid,3.0, 39.5194,1.5769,999.0019))
{
SetPlayerPos(playerid,1172.8816,-1321.5386,15.3990);
return SetPlayerInterior(playerid,0);
}
else if(IsPlayerInRangeOfPoint(playerid,3.0,1481.0033,-1771.5490,18.7958)&&GetPlayerInterior(playerid)==0)
{
SetPlayerPos(playerid,386.5259, 173.6381, 1008.3828);
SetPlayerInterior(playerid,3);
return SendClientMessage(playerid,COLOR_GREEN,"Dobro dosli u gradsku vjecnicu.");
}
else if(IsPlayerInRangeOfPoint(playerid,3.0,389.4573,173.6963,1008.3828)&&GetPlayerInterior(playerid)==3)
{
SetPlayerPos(playerid,1481.0033,-1771.5490,18.7958);
return SetPlayerInterior(playerid, 0);
}
}
return 1;
}
Try this.