From c817b2c1893fd70e9d7ff76712e782cdbec546dd Mon Sep 17 00:00:00 2001 From: MrMelbert <51863163+MrMelbert@users.noreply.github.com> Date: Mon, 29 Jan 2024 20:57:43 -0600 Subject: [PATCH] Un-undefs healthscan mode defines (moves them to a defines file) (#81161) ## About The Pull Request `healthscan` is a global proc, but if you want to call the proc with a different scan mode, you can't use the defines as they're def'd and undef'd in the health analyzer file. So I moved them to a global define file. --- code/__DEFINES/devices.dm | 9 +++++++++ .../objects/items/devices/scanners/health_analyzer.dm | 7 ------- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/code/__DEFINES/devices.dm b/code/__DEFINES/devices.dm index cacda58a9ea80..5e63d9bd6d398 100644 --- a/code/__DEFINES/devices.dm +++ b/code/__DEFINES/devices.dm @@ -13,3 +13,12 @@ #define INSPECTOR_TIME_MODE_SLOW 1 #define INSPECTOR_TIME_MODE_FAST 2 #define INSPECTOR_TIME_MODE_HONK 3 + +// Health scan modes +/// Healthscan prints health of the target +#define SCANNER_CONDENSED 0 +/// Healthscan prints health of each bodypart of the target in addition to broad health +#define SCANNER_VERBOSE 1 +/// Used to prevent health analyzers from switching modes when they shouldn't. +/// Functions the same as [SCANNER_CONDENSED] +#define SCANNER_NO_MODE -1 diff --git a/code/game/objects/items/devices/scanners/health_analyzer.dm b/code/game/objects/items/devices/scanners/health_analyzer.dm index 43d68f1175ffe..0db62c5436994 100644 --- a/code/game/objects/items/devices/scanners/health_analyzer.dm +++ b/code/game/objects/items/devices/scanners/health_analyzer.dm @@ -2,10 +2,6 @@ #define SCANMODE_HEALTH 0 #define SCANMODE_WOUND 1 #define SCANMODE_COUNT 2 // Update this to be the number of scan modes if you add more -#define SCANNER_CONDENSED 0 -#define SCANNER_VERBOSE 1 -// Not updating above count because you're not meant to switch to this mode. -#define SCANNER_NO_MODE -1 /obj/item/healthanalyzer name = "health analyzer" @@ -681,9 +677,6 @@ #undef SCANMODE_HEALTH #undef SCANMODE_WOUND #undef SCANMODE_COUNT -#undef SCANNER_CONDENSED -#undef SCANNER_VERBOSE -#undef SCANNER_NO_MODE #undef AID_EMOTION_NEUTRAL #undef AID_EMOTION_HAPPY