13.07.2011, 14:09
you dont have {} in OnPlayerCommandText() and missing return 0
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/enter", cmdtext, true, 6) == 0)
{
if(PlayerToPoint(10,playerid,2860.3044,1808.9399,10.8203))
{
SetPlayerPos(playerid,2306.5095,-15.9654,26.7496);
return 1;
}
return 0;
}
if (strcmp("/exit", cmdtext, true, 6) == 0)
{
if(IsPlayerInRangeOfPoint(playerid,2306.5095,-15.9654,26.7496))
{
SetPlayerPos(playerid,2860.3044,1808.9399,10.8203);
return 1;
}
}
return 0;
}