Core/Item: Localization items. (#223)

This commit is contained in:
HeartWell
2016-11-04 23:03:48 +03:00
committed by Shin
parent b9aa88ac2b
commit 8088ca220a
6 changed files with 38359 additions and 19 deletions

View File

@@ -175,6 +175,18 @@ bool ItemChatLink::ValidateName(char* buffer, const char* context)
bool res = (FormatName(LOCALE_enUS, NULL, suffixStrings) == buffer);
if (!res)
{
ItemLocale const* il = sObjectMgr->GetItemLocale(_item->ItemId);
for (uint8 index = LOCALE_koKR; index < TOTAL_LOCALES; ++index)
{
if (FormatName(index, il, suffixStrings) == buffer)
{
res = true;
break;
}
}
}
//if (!res)
;//sLog->outDebug(LOG_FILTER_CHATSYS, "ChatHandler::isValidChatMessage('%s'): linked item (id: %u) name wasn't found in any localization", context, _item->ItemId);
return res;