Some more hard-coded text removal

This commit is contained in:
Joonas Rikkonen
2017-12-27 14:40:33 +02:00
parent 2894b74edc
commit 4f0b190371
12 changed files with 135 additions and 82 deletions
@@ -38,8 +38,11 @@ namespace Barotrauma
if (singleplayer)
{
string summaryText = TextManager.Get(gameOver ? "gameover" :
(progress ? "progress" : "return"));
string summaryText = TextManager.Get(gameOver ? "RoundSummaryGameOver" :
(progress ? "RoundSummaryProgress" : "RoundSummaryReturn"));
summaryText.Replace("[sub]", Submarine.MainSub.Name);
summaryText.Replace("[location]", GameMain.GameSession.StartLocation.Name);
var infoText = new GUITextBlock(new Rectangle(0, y, 0, 50), summaryText, "", innerFrame, true);
y += infoText.Rect.Height;
@@ -53,7 +56,7 @@ namespace Barotrauma
y += 30 + endText.Text.Split('\n').Length * 20;
}
new GUITextBlock(new Rectangle(0, y, 0, 20), "Crew status:", "", innerFrame, GUI.LargeFont);
new GUITextBlock(new Rectangle(0, y, 0, 20), TextManager.Get("RoundSummaryCrewStatus"), "", innerFrame, GUI.LargeFont);
y += 30;
GUIListBox listBox = new GUIListBox(new Rectangle(0,y,0,90), null, Alignment.TopLeft, "", innerFrame, true);
@@ -75,7 +78,7 @@ namespace Barotrauma
characterInfo.CreateCharacterFrame(characterFrame,
characterInfo.Job != null ? (characterInfo.Name + '\n' + "(" + characterInfo.Job.Name + ")") : characterInfo.Name, null);
string statusText = "OK";
string statusText = TextManager.Get("StatusOK");
Color statusColor = Color.DarkGreen;
Character character = characterInfo.Character;
@@ -88,12 +91,12 @@ namespace Barotrauma
{
if (character.IsUnconscious)
{
statusText = "Unconscious";
statusText = TextManager.Get("Unconscious");
statusColor = Color.DarkOrange;
}
else if (character.Health / character.MaxHealth < 0.8f)
{
statusText = "Injured";
statusText = TextManager.Get("Injured");
statusColor = Color.DarkOrange;
}
}
@@ -110,7 +113,7 @@ namespace Barotrauma
if (GameMain.GameSession.Mission != null)
{
new GUITextBlock(new Rectangle(0, y, 0, 20), "Mission: " + GameMain.GameSession.Mission.Name, "", innerFrame, GUI.LargeFont);
new GUITextBlock(new Rectangle(0, y, 0, 20), TextManager.Get("Mission") + ": " + GameMain.GameSession.Mission.Name, "", innerFrame, GUI.LargeFont);
y += 30;
new GUITextBlock(new Rectangle(0, y, innerFrame.Rect.Width - 170, 0),
@@ -124,7 +127,7 @@ namespace Barotrauma
if (GameMain.GameSession.Mission.Completed && singleplayer)
{
new GUITextBlock(new Rectangle(0, 0, 0, 30), "Reward: " + GameMain.GameSession.Mission.Reward, "", Alignment.BottomLeft, Alignment.BottomLeft, innerFrame);
new GUITextBlock(new Rectangle(0, 0, 0, 30), TextManager.Get("Reward") + ": " + GameMain.GameSession.Mission.Reward, "", Alignment.BottomLeft, Alignment.BottomLeft, innerFrame);
}
}
else