(bcb06cc5c) Unstable v0.9.9.0

This commit is contained in:
Juan Pablo Arce
2020-03-27 15:22:59 -03:00
parent c81486a993
commit b143329701
326 changed files with 9692 additions and 4364 deletions
@@ -206,6 +206,12 @@ namespace Barotrauma
{
lock (mutex)
{
if (textPacks == null)
{
DebugConsole.ThrowError($"Failed to get the text \"{textTag}\" (no text packs loaded).");
return textTag;
}
if (!textPacks.ContainsKey(Language))
{
DebugConsole.ThrowError("No text packs available for the selected language (" + Language + ")! Switching to English...");
@@ -216,6 +222,13 @@ namespace Barotrauma
}
}
#if DEBUG
if (GameMain.Config != null && GameMain.Config.TextManagerDebugModeEnabled)
{
return textTag;
}
#endif
foreach (TextPack textPack in textPacks[Language])
{
string text = textPack.Get(textTag);