[MANUAL MIRROR] Robotic organ and disease improvements (#22631)

* Robotic organ and disease improvements (#76766)

## About The Pull Request

In the code description for the `ORGAN_ROBOTIC` flag, it says that
robotic organs are not supposed to decay or regenerate health. I went
and fixed this and added some more "robotic" behavior.

New changes for robotic organs:
- No longer heal damage passively
- No longer gain health from revival
- No longer heal in the smart organ fridge
- No longer heal from pluoxium
- Robotic ears no longer heal from ear healing items (earmuffs, etc.)
- Robotic eyes are immune to changeling blind stings
- Robotic eyes no longer heal from occuline

New changes for diseases:
- Some diseases now require an organ to work. A robotic organ will give
immunity to the disease symptom unless the disease has "Inorganic
Biology".
- The transmission methods for diseases require organs to work but
robotic organs are immune. (except inorganic biology) Airborne disease
transmission require lungs. Ingested (drunk or eaten) disease
transmission requires a stomach. Blood (inject or patch) disease
transmission requires a heart.
- Organs removed from a mob that is afflicted with a disease will be
infectious while handling or transplanting it. (again, robotic organs
are immune unless inorganic biology is present) Certain admin spawned or
special diseases are exempt from this transmission method.
- A stomach is required for nebula nausea, gastritium, carpellosis,
metabolic boost, vomit, weight loss, death sandwich poisoning,
- Lungs are required for choking, asphyxiation, cough, cold9, oxygen
restoration, sneezing, flu, cold, spanish flu, tuberculosis
- A liver is required for tissue hydration, plasma fixation, parasitic
infection
- Ears are required for deafness, sensory restoration
- A heart is required for toxolysis, heart failure
- Eyes are required for sensory restoration, hyphema
- A tongue is required for voice change, parrot possession, pierrot
throat
- Wizarditis no longer requires a head (wtf?) to function

## Why It's Good For The Game

Robotic organs should behave as intended. Not naturally healing (like
organic organs) was supposed to be their downside to counteract their
their ability to not decay upon death.

## Changelog

🆑
fix: Fix robotic organs to not gain health passively, from revival,
smart organ fridge, pluxium, occuline, and earmuffs.
add: Some diseases now require the appropriate internal organ to work. A
robotic organ will give immunity to the disease symptom unless the
disease has "Inorganic Biology".
add: Disease transmission methods now require an internal organ to be
successful. Robotic organs give immunity. (except inorganic biology)
Airborne disease transmission require lungs. Ingested (drunk or eaten)
disease transmission requires a stomach. Blood (inject or patch) disease
transmission requires a heart.
add: Organs removed from a mob that is afflicted with a disease will be
infectious while handling or transplanting it. (again, robotic organs
are immune unless inorganic biology is present) Certain admin spawned or
special diseases are exempt from this transmission method.
add: A stomach is required for nebula nausea, gastritium, carpellosis,
metabolic boost, vomit, weight loss, death sandwich poisoning
add: Lungs are required for choking, asphyxiation, cough, cold9, oxygen
restoration, sneezing, flu, cold, spanish flu, tuberculosis
add: A liver is required for tissue hydration, plasma fixation,
parasitic infection
add: Ears are required for deafness, sensory restoration
add: A heart is required for toxolysis, heart failure
add: Eyes are required for sensory restoration, hyphema
add: A tongue is required for voice change, pierrot throat
bal: Remove head requirement for wizarditis disease
/🆑

---------

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>

* Modular parts

* Printing time

* Hah typos

* I cant spell

* Golden Shower feedback

* Posi-Time

* Update modular_skyrat/modules/synths/code/bodyparts/brain.dm

---------

Co-authored-by: Tim <timothymtorres@gmail.com>
Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com>
This commit is contained in:
Zergspower
2023-08-04 15:07:07 -04:00
committed by GitHub
co-authored by MrMelbert Tim GoldenAlpharex
parent 6debbb2ff9
commit 88bf87fa4e
55 changed files with 512 additions and 239 deletions
+4 -4
View File
@@ -1332,13 +1332,13 @@
owner.visible_message(span_danger("[owner]'s [src.name] seems to malfunction!"))
var/time_needed = 10 SECONDS
var/brute_damage = 5 + 1.5 // Augments reduce brute damage by 5.
var/burn_damage = 4 + 2.5 // As above, but for burn it's 4.
var/brute_damage = 2.5 // SKYRAT EDIT : Balances direct EMP damage for Brute - SR's synth values are multiplied 3x 2.5 * 1.3 * 1.3
var/burn_damage = 2 // SKYRAT EDIT : Balances direct EMP damage for Burn - SR's synth values are multiplied 3x 2 * 1.3 * 1.3
if(severity == EMP_HEAVY)
time_needed *= 2
brute_damage *= 2
burn_damage *= 2
brute_damage *= 1.3 // SKYRAT EDIT : Balance - Lowers total damage from ~125 Brute to ~30
burn_damage *= 1.3 // SKYRAT EDIT : Balance - Lowers total damage from ~104 Burn to ~24
receive_damage(brute_damage, burn_damage)
do_sparks(number = 1, cardinal_only = FALSE, source = owner)
+21
View File
@@ -150,6 +150,9 @@ INITIALIZE_IMMEDIATE(/obj/item/organ)
/obj/item/organ/proc/on_remove(mob/living/carbon/organ_owner, special)
SHOULD_CALL_PARENT(TRUE)
if(!iscarbon(organ_owner))
stack_trace("Organ removal should not be happening on non carbon mobs: [organ_owner]")
for(var/trait in organ_traits)
REMOVE_TRAIT(organ_owner, trait, REF(src))
@@ -163,6 +166,24 @@ INITIALIZE_IMMEDIATE(/obj/item/organ)
SEND_SIGNAL(src, COMSIG_ORGAN_REMOVED, organ_owner)
SEND_SIGNAL(organ_owner, COMSIG_CARBON_LOSE_ORGAN, src, special)
var/list/diseases = organ_owner.get_static_viruses()
if(!LAZYLEN(diseases))
return
var/list/datum/disease/diseases_to_add = list()
for(var/datum/disease/disease as anything in diseases)
// robotic organs are immune to disease unless 'inorganic biology' symptom is present
if(IS_ROBOTIC_ORGAN(src) && !(disease.infectable_biotypes & MOB_ROBOTIC))
continue
// admin or special viruses that should not be reproduced
if(disease.spread_flags & (DISEASE_SPREAD_SPECIAL | DISEASE_SPREAD_NON_CONTAGIOUS))
continue
diseases_to_add += disease
if(LAZYLEN(diseases_to_add))
AddComponent(/datum/component/infective, diseases_to_add)
/// Add a Trait to an organ that it will give its owner.
/obj/item/organ/proc/add_organ_trait(trait)
LAZYADD(organ_traits, trait)
@@ -64,6 +64,9 @@
if(!damage) // No sense healing if you're not even hurt bro
return
if(IS_ROBOTIC_ORGAN(src)) // Robotic organs don't naturally heal
return
///Damage decrements by a percent of its maxhealth
var/healing_amount = healing_factor
///Damage decrements again by a percent of its maxhealth, up to a total of 4 extra times depending on the owner's health