PDA

Просмотр полной версии : [патч] Релоад локалес госсип меню


NeatElves
23.01.2010, 22:36
Тоже вроде правильно, один вопрос - обработчик в ObjectMgr - GossipMenuItemsLocales - забыли переименовать ?))
diff --git a/src/game/Chat.cpp b/src/game/Chat.cpp
index 106f30f..a51ec37 100644
--- a/src/game/Chat.cpp
+++ b/src/game/Chat.cpp
@@ -432,6 +432,7 @@ ChatCommand * ChatHandler::getCommandTable()
{ "locales_achievement_reward", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReloadLocalesAchievementRewardC ommand,"", NULL },
{ "locales_creature", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReloadLocalesCreatureCommand, "", NULL },
{ "locales_gameobject", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReloadLocalesGameobjectCommand, "", NULL },
+ { "locales_gossip_menu_option", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReloadLocalesGossipMenuOptionCo mmand, "", NULL },
{ "locales_item", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReloadLocalesItemCommand, "", NULL },
{ "locales_npc_text", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReloadLocalesNpcTextCommand, "", NULL },
{ "locales_page_text", SEC_ADMINISTRATOR, true, &ChatHandler::HandleReloadLocalesPageTextCommand, "", NULL },
diff --git a/src/game/Chat.h b/src/game/Chat.h
index 04585f5..e2adf0d 100644
--- a/src/game/Chat.h
+++ b/src/game/Chat.h
@@ -345,6 +345,7 @@ class ChatHandler
bool HandleReloadLocalesAchievementRewardCommand(const char* args);
bool HandleReloadLocalesCreatureCommand(const char* args);
bool HandleReloadLocalesGameobjectCommand(const char* args);
+ bool HandleReloadLocalesGossipMenuOptionCommand(const char* args);
bool HandleReloadLocalesItemCommand(const char* args);
bool HandleReloadLocalesNpcTextCommand(const char* args);
bool HandleReloadLocalesPageTextCommand(const char* args);
diff --git a/src/game/Level3.cpp b/src/game/Level3.cpp
index c6b3d08..5756ef9 100644
--- a/src/game/Level3.cpp
+++ b/src/game/Level3.cpp
@@ -180,6 +180,7 @@ bool ChatHandler::HandleReloadAllLocalesCommand(const char* /*args*/)
HandleReloadLocalesAchievementRewardCommand("a");
HandleReloadLocalesCreatureCommand("a");
HandleReloadLocalesGameobjectCommand("a");
+ HandleReloadLocalesGossipMenuOptionCommand("a");
HandleReloadLocalesItemCommand("a");
HandleReloadLocalesNpcTextCommand("a");
HandleReloadLocalesPageTextCommand("a");
@@ -811,6 +812,14 @@ bool ChatHandler::HandleReloadLocalesGameobjectCommand( const char* /*arg*/)
return true;
}

+bool ChatHandler::HandleReloadLocalesGossipMenuOptionCo mmand(const char* /*arg*/)
+{
+ sLog.outString( "Re-Loading Locales Gossip Menu Option ... ");
+ sObjectMgr.LoadGossipMenuItemsLocales();
+ SendGlobalSysMessage("DB table `locales_gossip_menu_option` reloaded.");
+ return true;
+}
+
bool ChatHandler::HandleReloadLocalesItemCommand(const char* /*arg*/)
{
sLog.outString( "Re-Loading Locales Item ... ");

Vladimir
25.01.2010, 11:06
В [9254]. Спасибо. :)