diff --git a/source/core/gamecontrol.cpp b/source/core/gamecontrol.cpp index 6a169fc68..5c8e7335b 100644 --- a/source/core/gamecontrol.cpp +++ b/source/core/gamecontrol.cpp @@ -983,11 +983,13 @@ int RunGame() GameTicRate = 30; CheckUserMap(); GPalette.Init(MAXPALOOKUPS + 2); // one slot for each translation, plus a separate one for the base palettes and the internal one + gi->loadPalette(); StartScreen->Progress(); TexMan.Init([]() {}, [](BuildInfo &) {}); StartScreen->Progress(); TileFiles.Init(); TileFiles.LoadArtSet("tiles%03d.art"); // it's the same for all games. + InitFont(); StartScreen->Progress(); I_InitSound(); @@ -1008,8 +1010,6 @@ int RunGame() gameinfo.mBackButton = "engine/graphics/m_back.png"; StartScreen->Progress(); - GPalette.Init(MAXPALOOKUPS + 1); // one slot for each translation, plus a separate one for the base palettes. - gi->loadPalette(); voxInit(); engineInit(); gi->app_init(); @@ -1023,10 +1023,11 @@ int RunGame() if (!(paletteloaded & PALETTE_MAIN)) I_FatalError("No palette found."); - V_LoadTranslations(); // loading the translations must be delayed until the palettes have been fully set up. lookups.postLoadTables(); PostLoadSetup(); lookups.postLoadLookups(); + V_LoadTranslations(); // loading the translations must be delayed until the palettes have been fully set up. + FMaterial::SetLayerCallback(setpalettelayer); if (GameStartupInfo.Name.IsNotEmpty()) I_SetWindowTitle(GameStartupInfo.Name); DeleteStartupScreen(); diff --git a/source/core/palette.cpp b/source/core/palette.cpp index 8d9b74179..b75354b86 100644 --- a/source/core/palette.cpp +++ b/source/core/palette.cpp @@ -303,6 +303,7 @@ void LookupTableInfo::postLoadLookups() } colorswap(&GPalette.GlobalBrightmap); std::swap(GPalette.BaseColors[0], GPalette.BaseColors[255]); + GPalette.Remap[0] = 255; } //========================================================================== diff --git a/wadsrc/static/menudef.txt b/wadsrc/static/menudef.txt index 0e2adadd1..6e628a327 100644 --- a/wadsrc/static/menudef.txt +++ b/wadsrc/static/menudef.txt @@ -44,7 +44,7 @@ LISTMENU "MainMenu" ifgame(ShadowWarrior) { Position 55, 32 - Linespacing 17 + Linespacing 21 SWLogo SWTextItem "$MNU_NEWGAME", "n", "EpisodeMenu" SWTextItem "$MNU_LOADGAME", "l", "LoadGameMenu" diff --git a/wadsrc/static/zscript/games/blood/ui/sbar.zs b/wadsrc/static/zscript/games/blood/ui/sbar.zs index eb3744727..6ade42da0 100644 --- a/wadsrc/static/zscript/games/blood/ui/sbar.zs +++ b/wadsrc/static/zscript/games/blood/ui/sbar.zs @@ -138,7 +138,7 @@ class BloodStatusBar : RazeStatusBar StatsPrintInfo stats; stats.fontscale = 1.; - stats.spacing = SmallFont.GetHeight() + 1; + stats.spacing = SmallFont.GetHeight() + 2; stats.screenbottomspace = bottomy; stats.statfont = SmallFont; stats.letterColor = TEXTCOLOR_DARKRED; diff --git a/wadsrc/static/zscript/games/duke/ui/sbar.zs b/wadsrc/static/zscript/games/duke/ui/sbar.zs index c8434bf50..2d81ff5bd 100644 --- a/wadsrc/static/zscript/games/duke/ui/sbar.zs +++ b/wadsrc/static/zscript/games/duke/ui/sbar.zs @@ -187,7 +187,12 @@ class DukeCommonStatusBar : RazeStatusBar stats.statfont = SmallFont2; stats.spacing = 6; } - else stats.spacing = stats.statfont.GetHeight() + 1; + else + { + if (Raze.isNamWW2GI()) stats.spacing = 12; + else if (!Raze.isRR()) stats.spacing = 11; + else stats.spacing = 14; + } stats.standardColor = (Raze.isNamWW2GI() && am_textfont)? Font.TEXTCOLOR_ORANGE : Font.TEXTCOLOR_UNTRANSLATED; stats.letterColor = Font.TEXTCOLOR_GOLD; PrintAutomapInfo(stats, textfont); diff --git a/wadsrc/static/zscript/statusbar.zs b/wadsrc/static/zscript/statusbar.zs index 84cb5d1db..5a23dab13 100644 --- a/wadsrc/static/zscript/statusbar.zs +++ b/wadsrc/static/zscript/statusbar.zs @@ -77,6 +77,8 @@ class RazeStatusBar : StatusBarCore y3 = y; String text; + + Console.Printf("Stat: scale = %f, spacing = %f", scale, spacing); text = String.Format("%sT: %s%d:%02d", info.letterColor, info.standardColor, stats.time / 60000, (stats.time % 60000) / 1000); drawStatText(info.statFont, 2 * hud_statscale, y3, text, scale); @@ -129,17 +131,19 @@ class RazeStatusBar : StatusBarCore } else if (info.screenbottomspace < 0) { - y = 200 - RelTop - spacing; + y = (200 - RelTop) * hud_scalefactor - spacing; } else { - y = 200 - info.screenbottomspace - spacing; + y = 200 - info.screenbottomspace * hud_scalefactor - spacing; } let cluster = lev.GetCluster(); String volname; if (cluster) volname = cluster.name; if (volname.length() == 0 && am_nameontop) y = 1; + Console.Printf("AM: scale = %f, spacing = %f", scale, spacing); + Screen.DrawText(info.statfont, Font.CR_UNTRANSLATED, 2 * hud_statscale, y, mapname, DTA_FullscreenScale, FSMode_ScaleToHeight, DTA_VirtualWidth, 320, DTA_VirtualHeight, 200, DTA_ScaleX, scale, DTA_ScaleY, scale, DTA_KeepRatio, true); y -= spacing;