From d911fa99a121fd415472c3d5217cd9cda9f2c20a Mon Sep 17 00:00:00 2001 From: nashmuhandes Date: Mon, 21 Jan 2019 13:17:11 +0800 Subject: [PATCH] Move the "time" string in saved game comment into the LANGUAGE lump. # Conflicts: # src/g_game.cpp --- src/g_game.cpp | 12 ++++++------ wadsrc/static/language.enu | 3 +++ 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/g_game.cpp b/src/g_game.cpp index 2d463455f..a6b009aae 100644 --- a/src/g_game.cpp +++ b/src/g_game.cpp @@ -2058,12 +2058,12 @@ static void PutSaveWads (FSerializer &arc) name = Wads.GetWadName (Wads.GetIwadNum()); arc.AddString("Game WAD", name); - // Name of wad the map resides in + // Name of wad the map resides in if (Wads.GetLumpFile (level.lumpnum) > Wads.GetIwadNum()) - { + { name = Wads.GetWadName (Wads.GetLumpFile (level.lumpnum)); arc.AddString("Map WAD", name); - } + } } static void PutSaveComment (FSerializer &arc) @@ -2079,14 +2079,14 @@ static void PutSaveComment (FSerializer &arc) arc.AddString("Creation Time", comment); - // Get level name + // Get level name //strcpy (comment, level.level_name); comment.Format("%s - %s\n", level.MapName.GetChars(), level.LevelName.GetChars()); // Append elapsed time + const char *const time = GStrings("SAVECOMMENT_TIME"); levelTime = level.time / TICRATE; - comment.AppendFormat("time: %02d:%02d:%02d", - levelTime/3600, (levelTime%3600)/60, levelTime%60); + comment.AppendFormat("%s: %02d:%02d:%02d", time, levelTime/3600, (levelTime%3600)/60, levelTime%60); // Write out the comment arc.AddString("Comment", comment); diff --git a/wadsrc/static/language.enu b/wadsrc/static/language.enu index 6f7d41a28..f620abfc1 100644 --- a/wadsrc/static/language.enu +++ b/wadsrc/static/language.enu @@ -856,6 +856,9 @@ STARTUP3 = ""; STARTUP4 = ""; STARTUP5 = ""; +// Save file comment +SAVECOMMENT_TIME = "time"; + // Scoreboard text SCORE_ITEMS = "ITEMS"; SCORE_BONUS = "BONUS";