19.11.2009, 08:15
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/opene69", cmdtext, true, 8) == 0) // You had "10" showing instead of "8". The number 8=How long the command is with the "/"
{
if(IsPlayerInRangeOfPoint(playerid, 7.0, -1523.627808, 481.981415, 6.207134))
{
MoveObject(Agate, -1535.559692, 481.989716, 6.179688, 2.00);
SendClientMessage(playerid, COLOR_RED, "Gate Opened Automaticly");
}
return 1;
}
if (strcmp("/closee69", cmdtext, true, 9) == 0) // You had "10" showing instead of "9". The number 9=How long the command is with the "/"
{
if(IsPlayerInRangeOfPoint(playerid, 7.0, -1523.627808, 481.981415, 6.207134))
{
MoveObject(Agate, -1523.627808, 481.981415, 6.207134, 2.00);
SendClientMessage(playerid, COLOR_RED, "Gate Closed Automaticly");
}
return 1;
}
return 1;
}