1
0
Fork 0

Added crBlocked and crNoPermission

This commit is contained in:
STRWarrior 2014-06-17 16:19:31 +02:00
parent 15ae4ce233
commit 008a6ce311
2 changed files with 4 additions and 2 deletions

View File

@ -1334,7 +1334,7 @@ cPluginManager::CommandResult cPluginManager::HandleCommand(cPlayer * a_Player,
if (CallHookExecuteCommand(a_Player, Split))
{
LOGINFO("Player %s tried executing command \"%s\" that was stopped by the HOOK_EXECUTE_COMMAND hook", a_Player->GetName().c_str(), Split[0].c_str());
return crError;
return crBlocked;
}
if (
@ -1345,7 +1345,7 @@ cPluginManager::CommandResult cPluginManager::HandleCommand(cPlayer * a_Player,
{
a_Player->SendMessageFailure(Printf("Forbidden command; insufficient privileges: \"%s\"", Split[0].c_str()));
LOGINFO("Player %s tried to execute forbidden command: \"%s\"", a_Player->GetName().c_str(), Split[0].c_str());
return crError;
return crNoPermission;
}
ASSERT(cmd->second.m_Plugin != NULL);

View File

@ -63,6 +63,8 @@ public: // tolua_export
crExecuted,
crUnknownCommand,
crError,
crBlocked,
crNoPermission,
} ;
// tolua_begin