summaryrefslogtreecommitdiff
path: root/soh/src/code
diff options
context:
space:
mode:
authorMalkierian <malkierian@gmail.com>2024-05-01 11:48:51 -0700
committerGitHub <noreply@github.com>2024-05-01 14:48:51 -0400
commit715bf39d4373ef22dea3ca6a229db7bb2e2d5e95 (patch)
treeedde074fd0b7800da6bcff89151be330cfd12186 /soh/src/code
parent56fe44968996b88a412885c8b978ef881455d763 (diff)
Incorporate LUS CMake CVar system (#4093)
* Incorporate LUS CMake CVar system. Customize all LUS CMake CVars to align with plans for preset system. Swap "gOverlayFont" usage back to LUS CVar macro. * Change CMake sets to use the cache to allow for including LUS's file for the add_compile_defines and remove the duplication on SoH's side. * Move SoH CMake CVars to `soh-cvars.cmake` for clarity.
Diffstat (limited to 'soh/src/code')
-rw-r--r--soh/src/code/game.c2
-rw-r--r--soh/src/code/gfxprint.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/soh/src/code/game.c b/soh/src/code/game.c
index 5fca89dbd..8d97177fd 100644
--- a/soh/src/code/game.c
+++ b/soh/src/code/game.c
@@ -467,7 +467,7 @@ void GameState_Destroy(GameState* gameState) {
// Performing clear skeletons before unload resources fixes an actor heap corruption crash due to the skeleton patching system.
ResourceMgr_ClearSkeletons();
- if (CVarGetInteger("gAltAssets", 0)) {
+ if (CVarGetInteger(CVAR_ALT_ASSETS, 0)) {
ResourceUnloadDirectory("alt/*");
gfx_texture_cache_clear();
}
diff --git a/soh/src/code/gfxprint.c b/soh/src/code/gfxprint.c
index 8a0dbead4..9caad46a8 100644
--- a/soh/src/code/gfxprint.c
+++ b/soh/src/code/gfxprint.c
@@ -141,7 +141,7 @@ static const ALIGN_ASSET(2) char rGfxPrintFontDataAlt[] = drGfxPrintFontDataAlt;
// https://github.com/HarbourMasters/Shipwright/issues/2762
typedef enum {hardcoded, otrDefault, otrAlt} font_texture_t;
font_texture_t GfxPrint_TextureToUse() {
- if (CVarGetInteger("gAltAssets", 0) && ResourceMgr_FileExists(rGfxPrintFontDataAlt)) {
+ if (CVarGetInteger(CVAR_ALT_ASSETS, 0) && ResourceMgr_FileExists(rGfxPrintFontDataAlt)) {
// If we have alt assets enabled, and we have alt prefixed font texture, use that
return otrAlt;
} else if (ResourceMgr_FileExists(rGfxPrintFontData)) {