Script/Commands: implemented .reload battleground_template (#210)
- Closes #28
This commit is contained in:
@@ -0,0 +1,5 @@
|
|||||||
|
INSERT INTO version_db_world(`sql_rev`) VALUES ('1477683243N');
|
||||||
|
|
||||||
|
DELETE FROM `command` WHERE `name` = 'reload battleground_template';
|
||||||
|
INSERT INTO `command` (`name`, `security`, `help`) VALUES
|
||||||
|
('reload battleground_template', 3, 'Syntax: .reload battleground_template\r\nReload Battleground Templates.');
|
||||||
@@ -13,6 +13,7 @@ EndScriptData */
|
|||||||
|
|
||||||
#include "AchievementMgr.h"
|
#include "AchievementMgr.h"
|
||||||
#include "AuctionHouseMgr.h"
|
#include "AuctionHouseMgr.h"
|
||||||
|
#include "BattlegroundMgr.h"
|
||||||
#include "Chat.h"
|
#include "Chat.h"
|
||||||
#include "CreatureTextMgr.h"
|
#include "CreatureTextMgr.h"
|
||||||
#include "DisableMgr.h"
|
#include "DisableMgr.h"
|
||||||
@@ -61,6 +62,7 @@ public:
|
|||||||
{ "areatrigger_tavern", SEC_ADMINISTRATOR, true, &HandleReloadAreaTriggerTavernCommand, "" },
|
{ "areatrigger_tavern", SEC_ADMINISTRATOR, true, &HandleReloadAreaTriggerTavernCommand, "" },
|
||||||
{ "areatrigger_teleport", SEC_ADMINISTRATOR, true, &HandleReloadAreaTriggerTeleportCommand, "" },
|
{ "areatrigger_teleport", SEC_ADMINISTRATOR, true, &HandleReloadAreaTriggerTeleportCommand, "" },
|
||||||
{ "autobroadcast", SEC_ADMINISTRATOR, true, &HandleReloadAutobroadcastCommand, "" },
|
{ "autobroadcast", SEC_ADMINISTRATOR, true, &HandleReloadAutobroadcastCommand, "" },
|
||||||
|
{ "battleground_template", SEC_ADMINISTRATOR, true, &HandleReloadBattlegroundTemplate, "" },
|
||||||
{ "command", SEC_ADMINISTRATOR, true, &HandleReloadCommandCommand, "" },
|
{ "command", SEC_ADMINISTRATOR, true, &HandleReloadCommandCommand, "" },
|
||||||
{ "conditions", SEC_ADMINISTRATOR, true, &HandleReloadConditions, "" },
|
{ "conditions", SEC_ADMINISTRATOR, true, &HandleReloadConditions, "" },
|
||||||
{ "config", SEC_ADMINISTRATOR, true, &HandleReloadConfigCommand, "" },
|
{ "config", SEC_ADMINISTRATOR, true, &HandleReloadConfigCommand, "" },
|
||||||
@@ -179,6 +181,15 @@ public:
|
|||||||
HandleReloadVehicleTemplateAccessoryCommand(handler, "");
|
HandleReloadVehicleTemplateAccessoryCommand(handler, "");
|
||||||
|
|
||||||
HandleReloadAutobroadcastCommand(handler, "");
|
HandleReloadAutobroadcastCommand(handler, "");
|
||||||
|
HandleReloadBattlegroundTemplate(handler, "");
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool HandleReloadBattlegroundTemplate(ChatHandler* handler, char const* /*args*/)
|
||||||
|
{
|
||||||
|
sLog->outString("Re-Loading Battleground Templates...");
|
||||||
|
sBattlegroundMgr->CreateInitialBattlegrounds();
|
||||||
|
handler->SendGlobalGMSysMessage("DB table `battleground_template` reloaded.");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user