+ // Game Info: Game Detail
+ float tl, fl, ll;
+ str = ""; // optionally "^7Limits: "
+ tl = STAT(TIMELIMIT);
+ fl = STAT(FRAGLIMIT);
+ ll = STAT(LEADLIMIT);
+ if(tl > 0)
+ str = strcat(str, sprintf(_("^3%1.0f minutes"), tl));
+ if(!ISGAMETYPE(LMS))
+ {
+ if(fl > 0)
+ {
+ if(tl > 0)
+ str = strcat(str, "^7 / "); // delimiter
+ if(teamplay)
+ {
+ str = strcat(str, sprintf(_("^5%s %s"), ScoreString(teamscores_flags(ts_primary), fl),
+ (teamscores_label(ts_primary) == "score") ? CTX(_("SCO^points")) :
+ (teamscores_label(ts_primary) == "fastest") ? CTX(_("SCO^is beaten")) :
+ TranslateScoresLabel(teamscores_label(ts_primary))));
+ }
+ else
+ {
+ str = strcat(str, sprintf(_("^5%s %s"), ScoreString(scores_flags(ps_primary), fl),
+ (scores_label(ps_primary) == "score") ? CTX(_("SCO^points")) :
+ (scores_label(ps_primary) == "fastest") ? CTX(_("SCO^is beaten")) :
+ TranslateScoresLabel(scores_label(ps_primary))));
+ }
+ }
+ if(ll > 0)
+ {
+ if(tl > 0 || fl > 0)
+ str = strcat(str, "^7 / "); // delimiter
+ if(teamplay)
+ {
+ str = strcat(str, sprintf(_("^2+%s %s"), ScoreString(teamscores_flags(ts_primary), ll),
+ (teamscores_label(ts_primary) == "score") ? CTX(_("SCO^points")) :
+ (teamscores_label(ts_primary) == "fastest") ? CTX(_("SCO^is beaten")) :
+ TranslateScoresLabel(teamscores_label(ts_primary))));
+ }
+ else
+ {
+ str = strcat(str, sprintf(_("^2+%s %s"), ScoreString(scores_flags(ps_primary), ll),
+ (scores_label(ps_primary) == "score") ? CTX(_("SCO^points")) :
+ (scores_label(ps_primary) == "fastest") ? CTX(_("SCO^is beaten")) :
+ TranslateScoresLabel(scores_label(ps_primary))));
+ }
+ }
+ }
+
+ pos.y += sb_gameinfo_type_fontsize.y;
+ drawcolorcodedstring(pos + '1 0 0' * (panel_size.x - stringwidth(str, true, sb_gameinfo_detail_fontsize)), str, sb_gameinfo_detail_fontsize, panel_fg_alpha, DRAWFLAG_NORMAL); // align right
+ // map name
+ str = sprintf(_("^7Map: ^2%s"), shortmapname);
+ drawcolorcodedstring(pos, str, sb_gameinfo_detail_fontsize, panel_fg_alpha, DRAWFLAG_NORMAL); // align left
+ // End of Game Info Section
+
+ pos.y += sb_gameinfo_detail_fontsize.y + hud_fontsize.y * 0.3; // space between Game Info Section and score table