mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 17:54:48 +01:00
Core/Player: Added character templates
* Characters with predefined levels can be created * Avaiable factions and classes can be configured * Valid values for `factionGroup` in table `character_template_class` are 3 (Alliance) or 5 (Horde) * Added new permission RBAC_PERM_USE_CHARACTER_TEMPLATES - has to be set, to allow the usage of the templates Closes #13952
This commit is contained in:
@@ -76,6 +76,7 @@ public:
|
||||
{ "areatrigger_teleport", rbac::RBAC_PERM_COMMAND_RELOAD_AREATRIGGER_TELEPORT, true, &HandleReloadAreaTriggerTeleportCommand, "", NULL },
|
||||
{ "autobroadcast", rbac::RBAC_PERM_COMMAND_RELOAD_AUTOBROADCAST, true, &HandleReloadAutobroadcastCommand, "", NULL },
|
||||
{ "battleground_template", rbac::RBAC_PERM_COMMAND_RELOAD_BATTLEGROUND_TEMPLATE, true, &HandleReloadBattlegroundTemplate, "", NULL },
|
||||
{ "character_template", rbac::RBAC_PERM_COMMAND_RELOAD_CHARACTER_TEMPLATE, true, &HandleReloadCharacterTemplate, "", NULL },
|
||||
{ "command", rbac::RBAC_PERM_COMMAND_RELOAD_COMMAND, true, &HandleReloadCommandCommand, "", NULL },
|
||||
{ "conditions", rbac::RBAC_PERM_COMMAND_RELOAD_CONDITIONS, true, &HandleReloadConditions, "", NULL },
|
||||
{ "config", rbac::RBAC_PERM_COMMAND_RELOAD_CONFIG, true, &HandleReloadConfigCommand, "", NULL },
|
||||
@@ -202,6 +203,7 @@ public:
|
||||
|
||||
HandleReloadAutobroadcastCommand(handler, "");
|
||||
HandleReloadBattlegroundTemplate(handler, "");
|
||||
HandleReloadCharacterTemplate(handler, "");
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -383,6 +385,14 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleReloadCharacterTemplate(ChatHandler* handler, char const* /*args*/)
|
||||
{
|
||||
TC_LOG_INFO("misc", "Re-Loading Character Templates...");
|
||||
sObjectMgr->LoadCharacterTemplates();
|
||||
handler->SendGlobalGMSysMessage("DB table `character_template` and `character_template_class` reloaded.");
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleReloadCommandCommand(ChatHandler* handler, const char* /*args*/)
|
||||
{
|
||||
handler->SetLoadCommandTable(true);
|
||||
|
||||
Reference in New Issue
Block a user