Core/Scripts: Nuke db_script_string table and make SCRIPT_COMMAND_TALK with broadcast_text instead

Original code by @Ascathor with modifications
Closes #13092
This commit is contained in:
DDuarte
2014-09-13 02:45:51 +01:00
parent f5a3913d95
commit 27479cf571
9 changed files with 226 additions and 75 deletions

View File

@@ -383,7 +383,8 @@ void Map::ScriptsProcess()
if (Player* player = _GetScriptPlayerSourceOrTarget(source, target, step.script))
{
LocaleConstant loc_idx = player->GetSession()->GetSessionDbLocaleIndex();
std::string text(sObjectMgr->GetTrinityString(step.script->Talk.TextID, loc_idx));
BroadcastText const* broadcastText = sObjectMgr->GetBroadcastText(step.script->Talk.TextID);
std::string text = broadcastText->GetText(loc_idx, player->getGender());
switch (step.script->Talk.ChatType)
{