30.05.2009, 14:07
double post!
Depends on how most your commands are. If most of your commands are like this:
i.e. it has new string somewhere in the command...
..then remove the new string under OnPlayerCommandText.
If not, then delete new string from that command. The error message is saying that you have two strings named "string" at the same time.
Depends on how most your commands are. If most of your commands are like this:
i.e. it has new string somewhere in the command...
pawn Код:
if(!strcmp(cmdtext, "/me", true, 3)) // 3 is the length of /me
{
if(!cmdtext[3]) return SendClientMessage(playerid, 0xFF0000FF, "USAGE/UŻYCIE: /me [action/akcja]");
new string[128], name[16]; // new "string" here!!!
GetPlayerName(playerid, name, sizeof(name));
format(string, 128, "*** %s %s", name, cmdtext[4]);
SendClientMessageToAll(COLOR_LIGHTGREEN, string);
return 1;
}
If not, then delete new string from that command. The error message is saying that you have two strings named "string" at the same time.