19.07.2009, 23:18
Hey guyz, i've made this command:
Which is /epr, and when used near a position, it teleports him to another place, but when he is not near the position or any other one, he cannot use it..
So.. the problem is:
I enter the game, i get near the place, i type /epr and it teleports me to the other place, and it says SERVER: Unknown Command
And when i use /epr any place else so i can read You're not near any private room door, it shows me the text and it says SERVER: Unknown Command
I dunno how to fix that... if you can help me.. i will appreciate.
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/epr", cmdtext, true, 10) == 0)
{
if (PlayerToPoint(1, playerid, -2660.8972,1423.4766,906.4609))
{
SetPlayerPos(playerid, -2660.8555,1425.6328,906.4609);
}
else
{
SendClientMessage(playerid, 0x00FFFF00, " You're not near any private room door ");
}
}
return 0;
}
So.. the problem is:
I enter the game, i get near the place, i type /epr and it teleports me to the other place, and it says SERVER: Unknown Command
And when i use /epr any place else so i can read You're not near any private room door, it shows me the text and it says SERVER: Unknown Command
I dunno how to fix that... if you can help me.. i will appreciate.