15.01.2012, 13:26
For the /o command.
Try this.
EDIT: Just saw your /equip and /buyweap cmd, In OnDialogResponse, you used if (dialogid == 1) and if (dialogid == 2) then you changed it to a switch for the equip and buyweap dialogs, try making them like the others (Example: if(dialogid == 999 for the buyweap cmd then insert your code)
pawn Код:
CMD:o(playerid, params[])
{
new text[254];
if(!sscanf(params, "s[254]", text))
{
new string[254], name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s: (( %s ))", name, text);
SendClientMessageToAll(COLOR_WHITE, string);
return 1;
}
else return SendClientMessage(playerid, 0xFFFFFF, "USAGE: /o(oc) [Text]");
}
EDIT: Just saw your /equip and /buyweap cmd, In OnDialogResponse, you used if (dialogid == 1) and if (dialogid == 2) then you changed it to a switch for the equip and buyweap dialogs, try making them like the others (Example: if(dialogid == 999 for the buyweap cmd then insert your code)