mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 09:44:45 +01:00
[7503] Implement proper (not 2 level limited) help.security set for chat commands and subcommands. Update some commands data. Author: VladimirMangos
* Now `command` table loading set data for any use subcommand levels
* Errors output for not existed in code commands at related data loading from table.
* Detail log level report outout about overwrited security level for loaded chat command data.
Using this functionality found and fixed/update data for `command` in mangos.sql
NOTE: some command security levels changed.
Thank you to benemorius for pointing to this security problem.
--HG--
branch : trunk
This commit is contained in:
@@ -1415,21 +1415,6 @@ bool ChatHandler::HandleAccountSetPasswordCommand(const char* args)
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ChatHandler::HandleAllowMovementCommand(const char* /*args*/)
|
||||
{
|
||||
if(sWorld.getAllowMovement())
|
||||
{
|
||||
sWorld.SetAllowMovement(false);
|
||||
SendSysMessage(LANG_CREATURE_MOVE_DISABLED);
|
||||
}
|
||||
else
|
||||
{
|
||||
sWorld.SetAllowMovement(true);
|
||||
SendSysMessage(LANG_CREATURE_MOVE_ENABLED);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ChatHandler::HandleMaxSkillCommand(const char* /*args*/)
|
||||
{
|
||||
Player* SelectedPlayer = getSelectedPlayer();
|
||||
@@ -4124,6 +4109,21 @@ bool ChatHandler::HandleNearGraveCommand(const char* args)
|
||||
}
|
||||
|
||||
//-----------------------Npc Commands-----------------------
|
||||
bool ChatHandler::HandleNpcAllowMovementCommand(const char* /*args*/)
|
||||
{
|
||||
if(sWorld.getAllowMovement())
|
||||
{
|
||||
sWorld.SetAllowMovement(false);
|
||||
SendSysMessage(LANG_CREATURE_MOVE_DISABLED);
|
||||
}
|
||||
else
|
||||
{
|
||||
sWorld.SetAllowMovement(true);
|
||||
SendSysMessage(LANG_CREATURE_MOVE_ENABLED);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ChatHandler::HandleNpcChangeEntryCommand(const char *args)
|
||||
{
|
||||
if(!args)
|
||||
|
||||
Reference in New Issue
Block a user