From 577db30351c9eec8de63a7b0b6c7d2f29d1cbea7 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Tue, 12 Jan 2021 02:04:03 +0100 Subject: [PATCH] [MIRROR] Regular CTF no longer has wounding (#2652) * Regular CTF no longer has wounding (#56093) :cl: coiax tweak: Regular Capture-The-Flag players can no longer be wounded. Simulated participants in the Medieval Shuttle can still be violently murdered with wounds however. /:cl: CTF is very fast paced, and if you've taken damage without your shield, you are nearly dead most of the time. However, if you do survive, you're supposed to slowly heal, but wounds are untreatable on the battlefield. People still being able to be bloodily stabbed in the Medieval Shuttle is definitely a feature. - Aliens (xenomorphs) are still immune to wounds, but that immunity is now done with a trait, rather than a typecheck. * Regular CTF no longer has wounding Co-authored-by: coiax --- code/__DEFINES/traits.dm | 1 + code/_globalvars/traits.dm | 1 + code/datums/wounds/_wounds.dm | 2 +- code/modules/awaymissions/capture_the_flag.dm | 5 +++++ code/modules/mob/living/carbon/alien/alien.dm | 2 ++ code/modules/shuttle/medisim.dm | 3 +++ code/modules/surgery/bodyparts/_bodyparts.dm | 3 +++ 7 files changed, 16 insertions(+), 1 deletion(-) diff --git a/code/__DEFINES/traits.dm b/code/__DEFINES/traits.dm index a23705f3906..8ca59caee70 100644 --- a/code/__DEFINES/traits.dm +++ b/code/__DEFINES/traits.dm @@ -171,6 +171,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai #define TRAIT_NOLIMBDISABLE "no_limb_disable" #define TRAIT_EASILY_WOUNDED "easy_limb_wound" #define TRAIT_HARDLY_WOUNDED "hard_limb_wound" +#define TRAIT_NEVER_WOUNDED "never_wounded" #define TRAIT_TOXINLOVER "toxinlover" #define TRAIT_NOBREATH "no_breath" #define TRAIT_ANTIMAGIC "anti_magic" diff --git a/code/_globalvars/traits.dm b/code/_globalvars/traits.dm index 925a80b6148..0e98cecae95 100644 --- a/code/_globalvars/traits.dm +++ b/code/_globalvars/traits.dm @@ -64,6 +64,7 @@ GLOBAL_LIST_INIT(traits_by_type, list( "TRAIT_NOLIMBDISABLE" = TRAIT_NOLIMBDISABLE, "TRAIT_EASILY_WOUNDED" = TRAIT_EASILY_WOUNDED, "TRAIT_HARDLY_WOUNDED" = TRAIT_HARDLY_WOUNDED, + "TRAIT_NEVER_WOUNDED" = TRAIT_NEVER_WOUNDED, "TRAIT_TOXINLOVER" = TRAIT_TOXINLOVER, "TRAIT_NOBREATH" = TRAIT_NOBREATH, "TRAIT_ANTIMAGIC" = TRAIT_ANTIMAGIC, diff --git a/code/datums/wounds/_wounds.dm b/code/datums/wounds/_wounds.dm index 1fe723f779c..d779ff3c2e3 100644 --- a/code/datums/wounds/_wounds.dm +++ b/code/datums/wounds/_wounds.dm @@ -110,7 +110,7 @@ * * smited- If this is a smite, we don't care about this wound for stat tracking purposes (not yet implemented) */ /datum/wound/proc/apply_wound(obj/item/bodypart/L, silent = FALSE, datum/wound/old_wound = null, smited = FALSE) - if(!istype(L) || !L.owner || !(L.body_zone in viable_zones) || isalien(L.owner) || !L.is_organic_limb()) + if(!istype(L) || !L.owner || !(L.body_zone in viable_zones) || !L.is_organic_limb() || HAS_TRAIT(L.owner, TRAIT_NEVER_WOUNDED)) qdel(src) return diff --git a/code/modules/awaymissions/capture_the_flag.dm b/code/modules/awaymissions/capture_the_flag.dm index 49ddbc67fa8..d7e02b5a54d 100644 --- a/code/modules/awaymissions/capture_the_flag.dm +++ b/code/modules/awaymissions/capture_the_flag.dm @@ -186,6 +186,9 @@ var/instagib_gear = /datum/outfit/ctf/instagib var/ammo_type = /obj/effect/ctf/ammo + // Fast paced gameplay, no real time for burn infections. + var/player_traits = list(TRAIT_NEVER_WOUNDED) + var/list/dead_barricades = list() var/static/arena_reset = FALSE @@ -322,6 +325,8 @@ M.faction += team M.equipOutfit(chosen_class) RegisterSignal(M, COMSIG_PARENT_QDELETING, .proc/ctf_qdelled_player) //just in case CTF has some map hazards (read: chasms). bit shorter than dust + for(var/trait in player_traits) + ADD_TRAIT(M, trait, CAPTURE_THE_FLAG_TRAIT) spawned_mobs[M] = chosen_class team_members |= new_team_member.ckey return M //used in medisim.dm diff --git a/code/modules/mob/living/carbon/alien/alien.dm b/code/modules/mob/living/carbon/alien/alien.dm index 2f62216b408..1e553005bf6 100644 --- a/code/modules/mob/living/carbon/alien/alien.dm +++ b/code/modules/mob/living/carbon/alien/alien.dm @@ -32,6 +32,8 @@ create_internal_organs() + ADD_TRAIT(src, TRAIT_NEVER_WOUNDED, ROUNDSTART_TRAIT) + . = ..() /mob/living/carbon/alien/create_internal_organs() diff --git a/code/modules/shuttle/medisim.dm b/code/modules/shuttle/medisim.dm index 67008825a9e..b9f06143ff2 100644 --- a/code/modules/shuttle/medisim.dm +++ b/code/modules/shuttle/medisim.dm @@ -11,6 +11,9 @@ /obj/machinery/capture_the_flag/medisim/Initialize(mapload) . = ..() + // Ensure that the historical simulation is extra bloody. + player_traits -= TRAIT_NEVER_WOUNDED + start_ctf() //both machines initialize, so both will call start_ctf instead of toggle_id_ctf calling it for both, twice. /obj/machinery/capture_the_flag/medisim/victory() diff --git a/code/modules/surgery/bodyparts/_bodyparts.dm b/code/modules/surgery/bodyparts/_bodyparts.dm index bbe0f283fee..a8d3d1702c8 100644 --- a/code/modules/surgery/bodyparts/_bodyparts.dm +++ b/code/modules/surgery/bodyparts/_bodyparts.dm @@ -404,6 +404,9 @@ * * bare_wound_bonus- The bare_wound_bonus of an attack */ /obj/item/bodypart/proc/check_wounding(woundtype, damage, wound_bonus, bare_wound_bonus) + if(HAS_TRAIT(owner, TRAIT_NEVER_WOUNDED)) + return + // note that these are fed into an exponent, so these are magnified if(HAS_TRAIT(owner, TRAIT_EASILY_WOUNDED)) damage *= 1.5