From 81313f0c4e73510198819db922caee4460d58947 Mon Sep 17 00:00:00 2001 From: fgsfds Date: Sun, 14 Jan 2024 21:13:31 +0100 Subject: [PATCH] port: ifdef around sight scale changes --- src/game/sight.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/game/sight.c b/src/game/sight.c index fa2155d4d..fb5f255ae 100644 --- a/src/game/sight.c +++ b/src/game/sight.c @@ -24,6 +24,7 @@ #include "video.h" #define SIGHT_COLOUR PLAYER_EXTCFG().crosshaircolour +#define SIGHT_SCALE PLAYER_EXTCFG().crosshairsize static inline f32 sightGetScaleX(void) { @@ -39,6 +40,7 @@ static inline s32 sightGetAdjustedX(const f32 x) #else #define SIGHT_COLOUR 0x00ff0028 +#define SIGHT_SCALE 2 #define sightGetScaleX() 1.f #define sightGetAdjustedX(x) (x) @@ -1471,14 +1473,12 @@ Gfx *sightDrawTarget(Gfx *gdl) #ifndef PLATFORM_N64 gSPSetExtraGeometryModeEXT(gdl++, G_ASPECT_CENTER_EXT); -#endif - -#define SIGHT_SCALE PLAYER_EXTCFG().crosshairsize - if (SIGHT_SCALE == 0) { // Draw single rectangle to preserve intended opacity gDPHudRectangle(gdl++, x, y, x, y); - } else { + } else +#endif + { gDPHudRectangle(gdl++, x + 1 * SIGHT_SCALE, y + 0 * SIGHT_SCALE, x + 3 * SIGHT_SCALE, y + 0 * SIGHT_SCALE); gDPHudRectangle(gdl++, x + 1 * SIGHT_SCALE, y + 0 * SIGHT_SCALE, x + 2 * SIGHT_SCALE, y + 0 * SIGHT_SCALE); gDPHudRectangle(gdl++, x - 3 * SIGHT_SCALE, y + 0 * SIGHT_SCALE, x - 1 * SIGHT_SCALE, y + 0 * SIGHT_SCALE);