From d5568e035d8734daf11df1a575add094990dbe1e Mon Sep 17 00:00:00 2001 From: ihatethisengine Date: Wed, 26 Jul 2023 04:09:47 +0300 Subject: [PATCH] heal off weeds --- .../living/carbon/xenomorph/XenoMutatorSets.dm | 1 - .../mob/living/carbon/xenomorph/Xenomorph.dm | 1 - .../mob/living/carbon/xenomorph/life.dm | 18 +++++++++--------- .../living/carbon/xenomorph/xeno_defines.dm | 10 ++++++---- 4 files changed, 15 insertions(+), 15 deletions(-) diff --git a/code/modules/mob/living/carbon/xenomorph/XenoMutatorSets.dm b/code/modules/mob/living/carbon/xenomorph/XenoMutatorSets.dm index 1af6eebcf9e7..b3a207bb5a3f 100644 --- a/code/modules/mob/living/carbon/xenomorph/XenoMutatorSets.dm +++ b/code/modules/mob/living/carbon/xenomorph/XenoMutatorSets.dm @@ -180,7 +180,6 @@ var/mob/living/carbon/xenomorph/xeno var/pull_multiplier = 1 var/egg_laying_multiplier = 1 - var/need_weeds = TRUE //Strains Below remaining_points = 6 diff --git a/code/modules/mob/living/carbon/xenomorph/Xenomorph.dm b/code/modules/mob/living/carbon/xenomorph/Xenomorph.dm index aea1ce9a5906..7c31029cd48e 100644 --- a/code/modules/mob/living/carbon/xenomorph/Xenomorph.dm +++ b/code/modules/mob/living/carbon/xenomorph/Xenomorph.dm @@ -960,7 +960,6 @@ if(iscarrier(src)) huggers_max = caste.huggers_max eggs_max = caste.eggs_max - need_weeds = mutators.need_weeds /mob/living/carbon/xenomorph/proc/recalculate_acid() diff --git a/code/modules/mob/living/carbon/xenomorph/life.dm b/code/modules/mob/living/carbon/xenomorph/life.dm index a0be2d2783a9..a9410108f0bd 100644 --- a/code/modules/mob/living/carbon/xenomorph/life.dm +++ b/code/modules/mob/living/carbon/xenomorph/life.dm @@ -334,11 +334,6 @@ Make sure their actual health updates immediately.*/ if(!T || !istype(T)) return - var/is_runner_hiding - - if(isrunner(src) && layer != initial(layer)) - is_runner_hiding = 1 - if(caste) if(caste.innate_healing || check_weeds_for_healing()) if(!hive) return // can't heal if you have no hive, sorry bud @@ -369,8 +364,15 @@ Make sure their actual health updates immediately.*/ if(armor_integrity > armor_integrity_max) armor_integrity = armor_integrity_max - else //Xenos restore plasma VERY slowly off weeds, regardless of health, as long as they are not using special abilities - if(prob(50) && !is_runner_hiding && !current_aura) + else + if(!need_weeds) //corrupted and renegades can heal off weeds, but slowly + if(lying || resting) + if(health < 0) //Unconscious + heal_wounds(caste.heal_knocked_out * regeneration_multiplier * 0.15, recoveryActual * 0.5) + else + heal_wounds(caste.heal_resting * regeneration_multiplier * 0.15, recoveryActual * 0.5) + plasma_stored += round(plasma_gain * plasma_max / 100 * recovery_aura/4 * 0.15) + else if(prob(50) && !current_aura) //Xenos restore plasma VERY slowly off weeds, regardless of health, as long as they are not using special abilities plasma_stored += 0.1 * plasma_max / 100 @@ -604,8 +606,6 @@ Make sure their actual health updates immediately.*/ if(W && W.linked_hive.is_ally(src)) return TRUE //weeds, yes! - if(need_weeds) - return FALSE //needs weeds, doesn't have any if(hive && hive.living_xeno_queen && !is_mainship_level(hive.living_xeno_queen.loc.z) && is_mainship_level(loc.z)) return FALSE //We are on the ship, but the Queen isn't return TRUE //we have off-weed healing, and either we're on Almayer with the Queen, or we're on non-Almayer, or the Queen is dead, good enough! diff --git a/code/modules/mob/living/carbon/xenomorph/xeno_defines.dm b/code/modules/mob/living/carbon/xenomorph/xeno_defines.dm index 71304c785885..c3ad51d46a53 100644 --- a/code/modules/mob/living/carbon/xenomorph/xeno_defines.dm +++ b/code/modules/mob/living/carbon/xenomorph/xeno_defines.dm @@ -1115,13 +1115,15 @@ var/list/defectors = list() -/datum/hive_status/corrupted/add_xeno(mob/living/carbon/xenomorph/X) +/datum/hive_status/corrupted/add_xeno(mob/living/carbon/xenomorph/xeno) . = ..() - X.add_language(LANGUAGE_ENGLISH) + xeno.add_language(LANGUAGE_ENGLISH) + xeno.need_weeds = FALSE -/datum/hive_status/corrupted/remove_xeno(mob/living/carbon/xenomorph/X, hard) +/datum/hive_status/corrupted/remove_xeno(mob/living/carbon/xenomorph/xeno, hard) . = ..() - X.remove_language(LANGUAGE_ENGLISH) + xeno.remove_language(LANGUAGE_ENGLISH) + xeno.need_weeds = FALSE /datum/hive_status/corrupted/can_delay_round_end(mob/living/carbon/xenomorph/xeno) if(!faction_is_ally(FACTION_MARINE, TRUE))