06.09.2015, 21:09
Well, I am working on my own admin system, and I've got an issue.
Examples:
it displays a SERVER: Unknown command to a regular player(which is what I want))
I did not do
here because I want it like: When a player is Admin Level 1, he has to see that message with, You're not authorized to use this command. BUT THE BUG IS, when a regular player enters the cmd /getip he receives the message also like the Admin lvl 1. So, my question is how do I make it like, that a regular player ALWAYS has to receive a message with SERVER: Unknown command. When they try to enter an admin cmd.
Conclusion: If an admin lvl 1 enters a cmd from admin lvl 2(or higher) he should receive the message with "You are not authorized to use this command"
And if a regular player enters a cmd which is for ADMINS only, he should receive SERVER: Unknown command.
NOTE: If you need more explanation, reply.
Examples:
PHP код:
CMD:setarmour(playerid, params[])
{
if(PlayerInfo[playerid][AdminLevel] < 1) return 0;
PHP код:
CMD:getip(playerid, params[])
{
if(PlayerInfo[playerid][AdminLevel] < 2) return SendClientMessage(playerid, COLOR_YELLOWGREEN, "Error: You are not authorized to use this command.");
PHP код:
return 0;
Conclusion: If an admin lvl 1 enters a cmd from admin lvl 2(or higher) he should receive the message with "You are not authorized to use this command"
And if a regular player enters a cmd which is for ADMINS only, he should receive SERVER: Unknown command.
NOTE: If you need more explanation, reply.