Make a few more engine strings translatable
authorWuzzy <Wuzzy2@mail.ru>
Sat, 10 Mar 2018 12:32:44 +0100
changeset 13161 26f0c3669b4e
parent 13160 25de976a7b9a
child 13162 c5453cbdeb87
Make a few more engine strings translatable
hedgewars/uGearsHedgehog.pas
hedgewars/uTeams.pas
hedgewars/uTypes.pas
hedgewars/uWorld.pas
share/hedgewars/Data/Locale/de.txt
share/hedgewars/Data/Locale/en.txt
--- a/hedgewars/uGearsHedgehog.pas	Sat Mar 10 03:27:18 2018 +0100
+++ b/hedgewars/uGearsHedgehog.pas	Sat Mar 10 12:32:44 2018 +0100
@@ -47,8 +47,7 @@
     t:= 0;
     while (TeamsArray[t] <> CurrentTeam) do inc(t);
 
-    // TODO: Localize
-    AddChatString(#2 + CurrentTeam^.TeamName + ' automatically skipped turn.');
+    AddChatString(#2 + FormatA(trmsg[sidAutoSkip], CurrentTeam^.TeamName));
 
     ParseCommand('/skip', true)
 end;
--- a/hedgewars/uTeams.pas	Sat Mar 10 03:27:18 2018 +0100
+++ b/hedgewars/uTeams.pas	Sat Mar 10 12:32:44 2018 +0100
@@ -704,7 +704,7 @@
                 begin
                 if (not hasGone) and isGoneFlagPendingToBeSet then
                     begin
-                    AddChatString(#7 + '* '+ TeamName + ' is gone'); // TODO: localize
+                    AddChatString(#7 + '* '+ FormatA(trmsg[sidTeamGone], TeamName));
                     if not CurrentTeam^.ExtDriven then SendIPC(_S'f' + s);
                     hasGone:= true;
                     skippedTurns:= 0;
@@ -743,7 +743,7 @@
         with TeamsArray[t]^ do
             if hasGone then
                 begin
-                AddChatString(#8 + '* '+ TeamName + ' is back');
+                AddChatString(#8 + '* '+ FormatA(trmsg[sidTeamBack], TeamName));
                 if not CurrentTeam^.ExtDriven then SendIPC(_S'g' + s);
                 hasGone:= false;
 
--- a/hedgewars/uTypes.pas	Sat Mar 10 03:27:18 2018 +0100
+++ b/hedgewars/uTypes.pas	Sat Mar 10 12:32:44 2018 +0100
@@ -478,7 +478,8 @@
             sidMute, sidAFK, sidAutoCameraOff, sidAutoCameraOn, sidPressTarget,
             sidNotAvailableInSD, sidHealthGain, sidEmptyCrate, sidUnknownKey,
             sidWinner2, sidWinner3, sidWinner4, sidWinner5, sidWinner6,
-            sidWinner7, sidWinnerAll);
+            sidWinner7, sidWinnerAll, sidTeamGone, sidTeamBack, sidAutoSkip,
+            sidFPS);
 
     // Events that are important for the course of the game or at least interesting for other reasons
     TEventId = (eidDied, eidDrowned, eidRoundStart, eidRoundWin, eidRoundDraw,
--- a/hedgewars/uWorld.pas	Sat Mar 10 03:27:18 2018 +0100
+++ b/hedgewars/uWorld.pas	Sat Mar 10 12:32:44 2018 +0100
@@ -1648,7 +1648,7 @@
             FPS:= Frames;
             Frames:= 0;
             CountTicks:= 0;
-            s:= inttostr(FPS) + ' fps';
+            s:= Format(trmsg[sidFPS], inttostr(FPS));
             tmpSurface:= TTF_RenderUTF8_Blended(Fontz[fnt16].Handle, Str2PChar(s), cWhiteColorChannels);
             tmpSurface:= doSurfaceConversion(tmpSurface);
             FreeAndNilTexture(fpsTexture);
--- a/share/hedgewars/Data/Locale/de.txt	Sat Mar 10 03:27:18 2018 +0100
+++ b/share/hedgewars/Data/Locale/de.txt	Sat Mar 10 12:32:44 2018 +0100
@@ -102,6 +102,10 @@
 01:34=%1, %2, %3, %4, %5 und %6 gewinnen!
 01:35=%1, %2, %3, %4, %5, %6 und %7 gewinnen!
 01:36=Alle gewinnen!
+01:37=%1 ist gegangen.
+01:38=%1 ist zurück.
+01:39=%1 hat den Zug automatisch übersprungen.
+01:40=%1 fps
 
 ; Event messages
 ; Hog (%1) died
--- a/share/hedgewars/Data/Locale/en.txt	Sat Mar 10 03:27:18 2018 +0100
+++ b/share/hedgewars/Data/Locale/en.txt	Sat Mar 10 12:32:44 2018 +0100
@@ -101,6 +101,10 @@
 01:34=%1, %2, %3, %4, %5 and %6 win!
 01:35=%1, %2, %3, %4, %5, %6 and %7 win!
 01:36=Everyone wins!
+01:37=%1 is gone.
+01:38=%1 is back.
+01:39=%1 automatically skipped turn.
+01:40=%1 fps
 
 ; Event messages
 ; Normal hog (%1) died (0 health)