From 4f91825c97919ff62297f7c4479c71a37ea9ee57 Mon Sep 17 00:00:00 2001 From: Ben10083 Date: Fri, 27 Oct 2023 18:31:11 -0400 Subject: [PATCH 1/2] First pass --- code/__DEFINES/ARES.dm | 3 +++ code/game/gamemodes/cm_initialize.dm | 8 ++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/code/__DEFINES/ARES.dm b/code/__DEFINES/ARES.dm index a1b82af25821..7b6692e9bea6 100644 --- a/code/__DEFINES/ARES.dm +++ b/code/__DEFINES/ARES.dm @@ -70,3 +70,6 @@ /// Cooldowns #define COOLDOWN_ARES_SENSOR 60 SECONDS #define COOLDOWN_ARES_ACCESS_CONTROL 20 SECONDS + +/// Time until someone can respawn as Working Joe +#define JOE_JOIN_DEAD_TIME (15 MINUTES) diff --git a/code/game/gamemodes/cm_initialize.dm b/code/game/gamemodes/cm_initialize.dm index effd3325f887..1c6e34d14bd7 100644 --- a/code/game/gamemodes/cm_initialize.dm +++ b/code/game/gamemodes/cm_initialize.dm @@ -965,10 +965,10 @@ Additional game mode variables. to_chat(joe_candidate, SPAN_WARNING("You are not whitelisted! You may apply on the forums to be whitelisted as a synth.")) return - if((joe_candidate.ckey in joes) && !MODE_HAS_TOGGLEABLE_FLAG(MODE_BYPASS_JOE)) - if(show_warning) - to_chat(joe_candidate, SPAN_WARNING("You already were a Working Joe this round!")) - return + var/deathtime = world.time - joe_candidate.timeofdeath + if(deathtime < JOE_JOIN_DEAD_TIME && !MODE_HAS_TOGGLEABLE_FLAG(MODE_BYPASS_JOE)) + to_chat(joe_candidate, SPAN_WARNING("You have been dead for [DisplayTimeText(deathtime)]. You need to wait [DisplayTimeText(JOE_JOIN_DEAD_TIME - deathtime)] before rejoining as a Working Joe!")) + return FALSE // council doesn't count towards this conditional. if(joe_job.get_whitelist_status(RoleAuthority.roles_whitelist, joe_candidate.client) == WHITELIST_NORMAL) From 1bc84057342ea35134ff6e95129030db4451530b Mon Sep 17 00:00:00 2001 From: Ben10083 Date: Fri, 27 Oct 2023 18:52:23 -0400 Subject: [PATCH 2/2] the fix --- code/game/gamemodes/cm_initialize.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/game/gamemodes/cm_initialize.dm b/code/game/gamemodes/cm_initialize.dm index 1c6e34d14bd7..37d083ef3534 100644 --- a/code/game/gamemodes/cm_initialize.dm +++ b/code/game/gamemodes/cm_initialize.dm @@ -966,8 +966,8 @@ Additional game mode variables. return var/deathtime = world.time - joe_candidate.timeofdeath - if(deathtime < JOE_JOIN_DEAD_TIME && !MODE_HAS_TOGGLEABLE_FLAG(MODE_BYPASS_JOE)) - to_chat(joe_candidate, SPAN_WARNING("You have been dead for [DisplayTimeText(deathtime)]. You need to wait [DisplayTimeText(JOE_JOIN_DEAD_TIME - deathtime)] before rejoining as a Working Joe!")) + if((deathtime < JOE_JOIN_DEAD_TIME && (joe_candidate.ckey in joes)) && !MODE_HAS_TOGGLEABLE_FLAG(MODE_BYPASS_JOE)) + to_chat(joe_candidate, SPAN_WARNING("You have been dead for [DisplayTimeText(deathtime)]. You need to wait [DisplayTimeText(JOE_JOIN_DEAD_TIME - deathtime)] before rejoining as a Working Joe!")) return FALSE // council doesn't count towards this conditional.