mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 07:37:01 +00:00
[7503] Implement proper (not 2 level limited) help.security set for chat commands and subcommands. Update some commands data.
* 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.
This commit is contained in:
parent
73e6ba114f
commit
fc94d6991c
7 changed files with 124 additions and 64 deletions
|
|
@ -882,21 +882,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();
|
||||
|
|
@ -3554,6 +3539,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)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue