diff --git a/code/__defines/mobs.dm b/code/__defines/mobs.dm
index da9220b3af..ca0e186ac9 100644
--- a/code/__defines/mobs.dm
+++ b/code/__defines/mobs.dm
@@ -214,6 +214,13 @@
#define O_AUG_SPINE "spinal augment"
#define O_AUG_PELVIC "pelvic augment"
+// FBP components.
+
+#define O_PUMP "hydraulic hub"
+#define O_CYCLER "reagent cycler"
+#define O_HEATSINK "thermal regulator"
+#define O_DIAGNOSTIC "diagnostic controller"
+
// Non-Standard organs
#define O_MOUTH "mouth"
#define O_CELL "cell"
diff --git a/code/game/objects/effects/decals/Cleanable/humans.dm b/code/game/objects/effects/decals/Cleanable/humans.dm
index ee02464c1e..2a37edf708 100644
--- a/code/game/objects/effects/decals/Cleanable/humans.dm
+++ b/code/game/objects/effects/decals/Cleanable/humans.dm
@@ -53,7 +53,11 @@ var/global/list/image/splatter_cache=list()
/obj/effect/decal/cleanable/blood/update_icon()
if(basecolor == "rainbow") basecolor = "#[get_random_colour(1)]"
color = basecolor
- if(synthblood)
+
+ if(basecolor == SYNTH_BLOOD_COLOUR)
+ name = "oil"
+ desc = "It's quite oily."
+ else if(synthblood)
name = "synthetic blood"
desc = "It's quite greasy."
else
diff --git a/code/modules/mob/living/carbon/human/human_powers.dm b/code/modules/mob/living/carbon/human/human_powers.dm
index 9c1a2ef398..9ce0d7a2c1 100644
--- a/code/modules/mob/living/carbon/human/human_powers.dm
+++ b/code/modules/mob/living/carbon/human/human_powers.dm
@@ -209,32 +209,45 @@
if(stat == DEAD) return
to_chat(src, "Performing self-diagnostic, please wait...")
- sleep(50)
- var/output = "Self-Diagnostic Results:\n"
- output += "Internal Temperature: [convert_k2c(bodytemperature)] Degrees Celsius\n"
+ spawn(50)
+ var/output = "Self-Diagnostic Results:\n"
- output += "Current Battery Charge: [nutrition]\n"
+ output += "Internal Temperature: [convert_k2c(bodytemperature)] Degrees Celsius\n"
- var/toxDam = getToxLoss()
- if(toxDam)
- output += "System Instability: [toxDam > 25 ? "Severe" : "Moderate"]. Seek charging station for cleanup.\n"
- else
- output += "System Instability: OK\n"
+ if(isSynthetic())
+ output += "Current Battery Charge: [nutrition]\n"
+<<<<<<< HEAD
for(var/obj/item/organ/external/EO in organs)
if(EO.brute_dam || EO.burn_dam)
output += "[EO.name] - [EO.burn_dam + EO.brute_dam > EO.min_broken_damage ? "Heavy Damage" : "Light Damage"]\n" //VOREStation Edit - Makes robotic limb damage scalable
else
output += "[EO.name] - OK\n"
+=======
+ if(isSynthetic())
+ var/toxDam = getToxLoss()
+ if(toxDam)
+ output += "System Instability: [toxDam > 25 ? "Severe" : "Moderate"]. Seek charging station for cleanup.\n"
+ else
+ output += "System Instability: OK\n"
+>>>>>>> 85d1338... FBP Internal Components (#7445)
- for(var/obj/item/organ/IO in internal_organs)
- if(IO.damage)
- output += "[IO.name] - [IO.damage > 10 ? "Heavy Damage" : "Light Damage"]\n"
- else
- output += "[IO.name] - OK\n"
+ for(var/obj/item/organ/external/EO in organs)
+ if(EO.robotic >= ORGAN_ASSISTED)
+ if(EO.brute_dam || EO.burn_dam)
+ output += "[EO.name] - [EO.burn_dam + EO.brute_dam > ROBOLIMB_REPAIR_CAP ? "Heavy Damage" : "Light Damage"]\n"
+ else
+ output += "[EO.name] - OK\n"
- to_chat(src,output)
+ for(var/obj/item/organ/IO in internal_organs)
+ if(IO.robotic >= ORGAN_ASSISTED)
+ if(IO.damage)
+ output += "[IO.name] - [IO.damage > 10 ? "Heavy Damage" : "Light Damage"]\n"
+ else
+ output += "[IO.name] - OK\n"
+
+ to_chat(src,output)
/mob/living/carbon/human
var/next_sonar_ping = 0
diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm
index 479874b185..13b0a1b218 100644
--- a/code/modules/mob/living/carbon/human/life.dm
+++ b/code/modules/mob/living/carbon/human/life.dm
@@ -784,10 +784,19 @@
if (species.body_temperature == null)
return //this species doesn't have metabolic thermoregulation
+<<<<<<< HEAD
// FBPs will overheat, prosthetic limbs are fine.
if(robobody_count)
if(!nif || !nif.flag_check(NIF_O_HEATSINKS,NIF_FLAGS_OTHER)) //VOREStation Edit - NIF heatsinks
bodytemperature += round(robobody_count*1.75)
+=======
+ // FBPs will overheat when alive, prosthetic limbs are fine.
+ if(stat != DEAD && robobody_count)
+ bodytemperature += round(robobody_count*1.15)
+ var/obj/item/organ/internal/robotic/heatsink/HS = internal_organs_by_name[O_HEATSINK]
+ if(!HS || HS.is_broken())
+ bodytemperature += round(robobody_count*0.5)
+>>>>>>> 85d1338... FBP Internal Components (#7445)
var/body_temperature_difference = species.body_temperature - bodytemperature
@@ -906,14 +915,14 @@
if(reagents)
chem_effects.Cut()
- if(!isSynthetic())
+ if(touching)
+ touching.metabolize()
+ if(ingested)
+ ingested.metabolize()
+ if(bloodstr)
+ bloodstr.metabolize()
- if(touching)
- touching.metabolize()
- if(ingested)
- ingested.metabolize()
- if(bloodstr)
- bloodstr.metabolize()
+ if(!isSynthetic())
var/total_phoronloss = 0
for(var/obj/item/I in src)
@@ -1454,7 +1463,7 @@
if(prob(5))
to_chat(src, "You lose directional control!")
Confuse(10)
- if (getToxLoss() >= 45)
+ if (getToxLoss() >= 45 && !isSynthetic())
spawn vomit()
diff --git a/code/modules/mob/living/carbon/human/species/species.dm b/code/modules/mob/living/carbon/human/species/species.dm
index 2157bce759..d4086e1442 100644
--- a/code/modules/mob/living/carbon/human/species/species.dm
+++ b/code/modules/mob/living/carbon/human/species/species.dm
@@ -41,6 +41,7 @@
var/show_ssd = "fast asleep"
var/virus_immune
var/short_sighted // Permanent weldervision.
+ var/blood_name = "blood" // Name for the species' blood.
var/blood_volume = 560 // Initial blood volume.
var/bloodloss_rate = 1 // Multiplier for how fast a species bleeds out. Higher = Faster
var/blood_level_safe = 0.85 //"Safe" blood level; above this, you're OK
diff --git a/code/modules/mob/living/carbon/human/species/species_getters.dm b/code/modules/mob/living/carbon/human/species/species_getters.dm
index 8fe3f80a13..0eeea4f9d4 100644
--- a/code/modules/mob/living/carbon/human/species/species_getters.dm
+++ b/code/modules/mob/living/carbon/human/species/species_getters.dm
@@ -63,6 +63,14 @@
else
return blood_color
+/datum/species/proc/get_blood_name(var/mob/living/carbon/human/H)
+ if(H)
+ var/datum/robolimb/company = H.isSynthetic()
+ if(company)
+ return company.blood_name
+ else
+ return blood_name
+
/datum/species/proc/get_virus_immune(var/mob/living/carbon/human/H)
return ((H && H.isSynthetic()) ? 1 : virus_immune)
diff --git a/code/modules/mob/living/carbon/human/species/station/prometheans.dm b/code/modules/mob/living/carbon/human/species/station/prometheans.dm
index 6f7615c6fd..bfb1b7d5e3 100644
--- a/code/modules/mob/living/carbon/human/species/station/prometheans.dm
+++ b/code/modules/mob/living/carbon/human/species/station/prometheans.dm
@@ -34,6 +34,8 @@ var/datum/species/shapeshifter/promethean/prometheans
secondary_langs = list(LANGUAGE_PROMETHEAN, LANGUAGE_SOL_COMMON) // For some reason, having this as their species language does not allow it to be chosen.
assisted_langs = list(LANGUAGE_ROOTGLOBAL, LANGUAGE_VOX) // Prometheans are weird, let's just assume they can use basically any language.
+ blood_name = "gelatinous ooze"
+
breath_type = null
poison_type = null
diff --git a/code/modules/organs/blood.dm b/code/modules/organs/blood.dm
index 49f9d5b6a4..f1214708f1 100644
--- a/code/modules/organs/blood.dm
+++ b/code/modules/organs/blood.dm
@@ -36,8 +36,13 @@ var/const/CE_STABLE_THRESHOLD = 0.5
for(var/datum/reagent/blood/B in vessel.reagent_list)
if(B.id == "blood")
B.data = list( "donor"=src,"viruses"=null,"species"=species.name,"blood_DNA"=dna.unique_enzymes,"blood_colour"= species.get_blood_colour(src),"blood_type"=dna.b_type, \
- "resistances"=null,"trace_chem"=null, "virus2" = null, "antibodies" = list())
+ "resistances"=null,"trace_chem"=null, "virus2" = null, "antibodies" = list(), "blood_name" = species.get_blood_name(src))
+
+ if(isSynthetic())
+ B.data["species"] = "synthetic"
+
B.color = B.data["blood_colour"]
+ B.name = B.data["blood_name"]
// Takes care blood loss and regeneration
/mob/living/carbon/human/handle_blood()
@@ -369,6 +374,9 @@ proc/blood_splatter(var/target,var/datum/reagent/blood/source,var/large)
B.synthblood = synth
B.update_icon()
+ if(source.data["blood_name"])
+ B.name = source.data["blood_name"]
+
// Update blood information.
if(source.data["blood_DNA"])
B.blood_DNA = list()
diff --git a/code/modules/organs/internal/heart.dm b/code/modules/organs/internal/heart.dm
index 62e5fd16d2..9f015bcdc9 100644
--- a/code/modules/organs/internal/heart.dm
+++ b/code/modules/organs/internal/heart.dm
@@ -37,3 +37,19 @@
if(ishuman(owner))
H = owner
color = H.species.blood_color
+
+/obj/item/organ/internal/heart/machine
+ name = "hydraulic hub"
+ icon_state = "pump-on"
+ organ_tag = O_PUMP
+ dead_icon = "pump-off"
+ robotic = ORGAN_ROBOT
+
+ standard_pulse_level = PULSE_NONE
+
+/obj/item/organ/internal/stomach/machine/handle_organ_proc_special()
+ ..()
+ if(owner && owner.stat != DEAD)
+ owner.bodytemperature += round(owner.robobody_count * 0.25, 0.1)
+
+ return
diff --git a/code/modules/organs/internal/robotic/diagnostic.dm b/code/modules/organs/internal/robotic/diagnostic.dm
new file mode 100644
index 0000000000..7d915fa332
--- /dev/null
+++ b/code/modules/organs/internal/robotic/diagnostic.dm
@@ -0,0 +1,14 @@
+/*
+ * Controls the ability to do a scan for internal damage / temperature.
+ */
+
+/obj/item/organ/internal/robotic/diagnostic
+ name = "diagnostic processor"
+
+ icon_state = "diagnostic"
+
+ organ_tag = O_DIAGNOSTIC
+
+ organ_verbs = list(
+ /mob/living/carbon/human/proc/self_diagnostics
+ )
diff --git a/code/modules/organs/internal/robotic/heatsink.dm b/code/modules/organs/internal/robotic/heatsink.dm
new file mode 100644
index 0000000000..4db6e41922
--- /dev/null
+++ b/code/modules/organs/internal/robotic/heatsink.dm
@@ -0,0 +1,58 @@
+
+/obj/item/organ/internal/robotic/heatsink
+ name = "heatsink"
+ icon_state = "heatsink"
+
+ organ_tag = O_HEATSINK
+
+/obj/item/organ/internal/robotic/heatsink/handle_organ_proc_special()
+ if(owner && owner.stat != DEAD)
+ owner.bodytemperature += round(owner.robobody_count * 0.75, 0.1)
+
+ var/thermostat = owner.species.body_temperature
+ var/turf/T = get_turf(src)
+ var/datum/gas_mixture/environment = T.return_air()
+ var/efficiency = max(0,(1 - owner.get_pressure_weakness(environment.return_pressure())) * (1 - damage / max_damage))
+ var/temp_adj = 0
+ var/env_temp = get_environment_temperature()
+ var/thermal_protection = owner.get_heat_protection(env_temp)
+
+ if(thermal_protection < 1)
+ temp_adj = min(owner.bodytemperature - max(thermostat, env_temp), owner.robobody_count * 2)
+ else
+ temp_adj = min(owner.bodytemperature - thermostat, owner.robobody_count * 2)
+
+ if(temp_adj < 0)
+ return
+
+ owner.bodytemperature -= temp_adj*efficiency
+
+ if(owner.bodytemperature > owner.species.heat_level_2) // If you're already overheating to the point of melting, the heatsink starts causing problems.
+ owner.adjustToxLoss(2 * damage / max_damage)
+ take_damage(max(0.5,round(damage / max_damage, 0.1)))
+
+ return
+
+/obj/item/organ/internal/robotic/heatsink/proc/get_environment_temperature()
+ if(istype(owner.loc, /obj/mecha))
+ var/obj/mecha/M = owner.loc
+ return M.return_temperature()
+ else if(istype(owner.loc, /obj/machinery/atmospherics/unary/cryo_cell))
+ return owner.loc:air_contents.temperature
+
+ var/turf/T = get_turf(src)
+
+ var/datum/gas_mixture/environment = T.return_air()
+
+ var/efficiency = 1
+
+ if(environment)
+ efficiency = (1 - owner.get_pressure_weakness(environment.return_pressure())) * (1 - damage / max_damage)
+
+ if(istype(T, /turf/space))
+ return owner.species.heat_level_2 * efficiency
+
+ if(!environment)
+ return owner.species.heat_level_2 * efficiency
+
+ return environment.temperature
diff --git a/code/modules/organs/internal/robotic/robotic.dm b/code/modules/organs/internal/robotic/robotic.dm
new file mode 100644
index 0000000000..7a40ab8101
--- /dev/null
+++ b/code/modules/organs/internal/robotic/robotic.dm
@@ -0,0 +1,11 @@
+
+/obj/item/organ/internal/robotic
+ name = "FBP component"
+ desc = "A complex piece of a much more complex machine."
+
+ icon_state = "eyes-prosthetic"
+
+ can_reject = FALSE // It's a robotic part. Why would it reject.
+ decays = FALSE // Ditto. Rust takes a while.
+
+ robotic = ORGAN_ROBOT
diff --git a/code/modules/organs/internal/stomach.dm b/code/modules/organs/internal/stomach.dm
index 02cf7cb31d..c8e90d9f78 100644
--- a/code/modules/organs/internal/stomach.dm
+++ b/code/modules/organs/internal/stomach.dm
@@ -48,3 +48,20 @@
/obj/item/organ/internal/stomach/xeno
color = "#555555"
+ acidtype = "pacid"
+
+/obj/item/organ/internal/stomach/machine
+ name = "reagent cycler"
+ icon_state = "cycler"
+ organ_tag = O_CYCLER
+
+ robotic = ORGAN_ROBOT
+
+ acidtype = "sacid"
+
+/obj/item/organ/internal/stomach/machine/handle_organ_proc_special()
+ ..()
+ if(owner && owner.stat != DEAD)
+ owner.bodytemperature += round(owner.robobody_count * 0.25, 0.1)
+
+ return
diff --git a/code/modules/organs/robolimbs.dm b/code/modules/organs/robolimbs.dm
index 8a06b043d0..82f77eb229 100644
--- a/code/modules/organs/robolimbs.dm
+++ b/code/modules/organs/robolimbs.dm
@@ -51,7 +51,12 @@ var/const/standard_monitor_styles = "blank=ipc_blank;\
var/skin_tone // If set, applies skin tone rather than part color Overrides color.
var/skin_color // If set, applies skin color rather than part color.
var/blood_color = "#030303"
+<<<<<<< HEAD
var/list/species_cannot_use = list(SPECIES_TESHARI, SPECIES_PROMETHEAN, SPECIES_DIONA, SPECIES_XENOCHIMERA) //VOREStation Edit
+=======
+ var/blood_name = "oil"
+ var/list/species_cannot_use = list(SPECIES_TESHARI, SPECIES_PROMETHEAN, SPECIES_DIONA)
+>>>>>>> 85d1338... FBP Internal Components (#7445)
var/list/species_alternates = list(SPECIES_TAJ = "Unbranded - Tajaran", SPECIES_UNATHI = "Unbranded - Unathi") //"Species Name" = "Robolimb Company" , List, when initialized, will become "Species Name" = RobolimbDatum, used for alternate species sprites.
var/list/monitor_styles //If empty, the model of limbs offers a head compatible with monitors.
var/parts = BP_ALL //Defines what parts said brand can replace on a body.
@@ -171,6 +176,7 @@ var/const/standard_monitor_styles = "blank=ipc_blank;\
desc = "This limb looks to be more like a strange.. puppet, than a prosthetic."
icon = 'icons/mob/human_races/cyberlimbs/veymed/dionaea/skrellian.dmi'
blood_color = "#63b521"
+ blood_name = "synthetic ichor"
speech_bubble_appearance = "machine"
unavailable_to_build = 1
species_cannot_use = list(SPECIES_TESHARI, SPECIES_PROMETHEAN, SPECIES_TAJ, SPECIES_HUMAN, SPECIES_VOX, SPECIES_HUMAN_VATBORN, SPECIES_UNATHI, SPECIES_SKRELL, SPECIES_ZADDAT)
@@ -307,6 +313,7 @@ var/const/standard_monitor_styles = "blank=ipc_blank;\
skin_tone = 1
species_alternates = list(SPECIES_SKRELL = "Vey-Med - Skrell")
blood_color = "#CCCCCC"
+ blood_name = "coolant"
speech_bubble_appearance = "normal"
//robo_brute_mod = 1.1 //VOREStation Edit
//robo_burn_mod = 1.1 //VOREStation Edit
@@ -320,6 +327,7 @@ var/const/standard_monitor_styles = "blank=ipc_blank;\
skin_color = TRUE
species_cannot_use = list(SPECIES_TESHARI, SPECIES_PROMETHEAN, SPECIES_TAJ, SPECIES_HUMAN, SPECIES_VOX, SPECIES_HUMAN_VATBORN, SPECIES_UNATHI, SPECIES_DIONA, SPECIES_ZADDAT)
blood_color = "#4451cf"
+ blood_name = "coolant"
speech_bubble_appearance = "normal"
robo_brute_mod = 1.05
robo_burn_mod = 1.05
diff --git a/code/modules/organs/subtypes/machine.dm b/code/modules/organs/subtypes/machine.dm
index 6cefcfcee6..8624a71453 100644
--- a/code/modules/organs/subtypes/machine.dm
+++ b/code/modules/organs/subtypes/machine.dm
@@ -22,6 +22,13 @@
..()
owner.adjust_nutrition(-rand(10 / severity, 50 / severity))
+/obj/item/organ/internal/cell/machine/handle_organ_proc_special()
+ ..()
+ if(owner && owner.stat != DEAD)
+ owner.bodytemperature += round(owner.robobody_count * 0.5, 0.1)
+
+ return
+
// Used for an MMI or posibrain being installed into a human.
/obj/item/organ/internal/mmi_holder
name = "brain interface"
@@ -51,6 +58,11 @@
/obj/item/organ/internal/mmi_holder/proc/tick_defib_timer()
return
+/obj/item/organ/internal/mmi_holder/proc/get_control_efficiency()
+ . = max(0, 1 - round(damage / max_damage, 0.1))
+
+ return .
+
/obj/item/organ/internal/mmi_holder/proc/update_from_mmi()
if(!stored_mmi.brainmob)
diff --git a/code/modules/organs/subtypes/standard.dm b/code/modules/organs/subtypes/standard.dm
index 63e4c4a7d2..bb4a9c7a13 100644
--- a/code/modules/organs/subtypes/standard.dm
+++ b/code/modules/organs/subtypes/standard.dm
@@ -28,6 +28,10 @@
// Give them fancy new organs.
owner.internal_organs_by_name[O_CELL] = new /obj/item/organ/internal/cell(owner,1)
owner.internal_organs_by_name[O_VOICE] = new /obj/item/organ/internal/voicebox/robot(owner, 1)
+ owner.internal_organs_by_name[O_PUMP] = new /obj/item/organ/internal/heart/machine(owner,1)
+ owner.internal_organs_by_name[O_CYCLER] = new /obj/item/organ/internal/stomach/machine(owner,1)
+ owner.internal_organs_by_name[O_HEATSINK] = new /obj/item/organ/internal/robotic/heatsink(owner,1)
+ owner.internal_organs_by_name[O_DIAGNOSTIC] = new /obj/item/organ/internal/robotic/diagnostic(owner,1)
/obj/item/organ/external/chest/handle_germ_effects()
. = ..() //Should return an infection level
diff --git a/code/modules/reagents/Chemistry-Holder.dm b/code/modules/reagents/Chemistry-Holder.dm
index 11f6d01cdb..8598d54115 100644
--- a/code/modules/reagents/Chemistry-Holder.dm
+++ b/code/modules/reagents/Chemistry-Holder.dm
@@ -114,6 +114,10 @@
for(var/datum/reagent/current in reagent_list)
if(current.id == id)
+ if(current.id == "blood")
+ if(!isnull(data["species"]) && !isnull(current.data["species"]) && data["species"] != current.data["species"]) // Species bloodtypes are already incompatible, this just stops it from mixing into the one already in a container.
+ continue
+
current.volume += amount
if(!isnull(data)) // For all we know, it could be zero or empty string and meaningful
current.mix_data(data, amount)
diff --git a/code/modules/reagents/Chemistry-Reagents.dm b/code/modules/reagents/Chemistry-Reagents.dm
index a7239281c2..1f85009836 100644
--- a/code/modules/reagents/Chemistry-Reagents.dm
+++ b/code/modules/reagents/Chemistry-Reagents.dm
@@ -22,7 +22,10 @@
var/overdose_mod = 1 //Modifier to overdose damage
var/can_overdose_touch = FALSE // Can the chemical OD when processing on touch?
var/scannable = 0 // Shows up on health analyzers.
- var/affects_dead = 0
+
+ var/affects_dead = 0 // Does this chem process inside a corpse?
+ var/affects_robots = 0 // Does this chem process inside a Synth?
+
var/cup_icon_state = null
var/cup_name = null
var/cup_desc = null
@@ -55,6 +58,8 @@
return
if(!affects_dead && M.stat == DEAD)
return
+ if(!affects_robots && M.isSynthetic())
+ return
if(!istype(location))
return
@@ -79,28 +84,55 @@
if(ishuman(M))
var/mob/living/carbon/human/H = M
- if(H.species.has_organ[O_HEART] && (active_metab.metabolism_class == CHEM_BLOOD))
- var/obj/item/organ/internal/heart/Pump = H.internal_organs_by_name[O_HEART]
- if(!Pump)
- removed *= 0.1
- else if(Pump.standard_pulse_level == PULSE_NONE) // No pulse normally means chemicals process a little bit slower than normal.
- removed *= 0.8
- else // Otherwise, chemicals process as per percentage of your current pulse, or, if you have no pulse but are alive, by a miniscule amount.
- removed *= max(0.1, H.pulse / Pump.standard_pulse_level)
+ if(!H.isSynthetic())
+ if(H.species.has_organ[O_HEART] && (active_metab.metabolism_class == CHEM_BLOOD))
+ var/obj/item/organ/internal/heart/Pump = H.internal_organs_by_name[O_HEART]
+ if(!Pump)
+ removed *= 0.1
+ else if(Pump.standard_pulse_level == PULSE_NONE) // No pulse normally means chemicals process a little bit slower than normal.
+ removed *= 0.8
+ else // Otherwise, chemicals process as per percentage of your current pulse, or, if you have no pulse but are alive, by a miniscule amount.
+ removed *= max(0.1, H.pulse / Pump.standard_pulse_level)
- if(H.species.has_organ[O_STOMACH] && (active_metab.metabolism_class == CHEM_INGEST))
- var/obj/item/organ/internal/stomach/Chamber = H.internal_organs_by_name[O_STOMACH]
- if(Chamber)
- ingest_rem_mult *= max(0.1, 1 - (Chamber.damage / Chamber.max_damage))
- else
- ingest_rem_mult = 0.1
+ if(H.species.has_organ[O_STOMACH] && (active_metab.metabolism_class == CHEM_INGEST))
+ var/obj/item/organ/internal/stomach/Chamber = H.internal_organs_by_name[O_STOMACH]
+ if(Chamber)
+ ingest_rem_mult *= max(0.1, 1 - (Chamber.damage / Chamber.max_damage))
+ else
+ ingest_rem_mult = 0.1
- if(H.species.has_organ[O_INTESTINE] && (active_metab.metabolism_class == CHEM_INGEST))
- var/obj/item/organ/internal/intestine/Tube = H.internal_organs_by_name[O_INTESTINE]
- if(Tube)
- ingest_abs_mult *= max(0.1, 1 - (Tube.damage / Tube.max_damage))
- else
- ingest_abs_mult = 0.1
+ if(H.species.has_organ[O_INTESTINE] && (active_metab.metabolism_class == CHEM_INGEST))
+ var/obj/item/organ/internal/intestine/Tube = H.internal_organs_by_name[O_INTESTINE]
+ if(Tube)
+ ingest_abs_mult *= max(0.1, 1 - (Tube.damage / Tube.max_damage))
+ else
+ ingest_abs_mult = 0.1
+
+ else
+ var/obj/item/organ/internal/heart/machine/Pump = H.internal_organs_by_name[O_PUMP]
+ var/obj/item/organ/internal/stomach/machine/Cycler = H.internal_organs_by_name[O_CYCLER]
+
+ if(active_metab.metabolism_class == CHEM_BLOOD)
+ if(Pump)
+ removed *= 1.1 - Pump.damage / Pump.max_damage
+ else
+ removed *= 0.1
+
+ else if(active_metab.metabolism_class == CHEM_INGEST) // If the pump is damaged, we waste chems from the tank.
+ if(Pump)
+ ingest_abs_mult *= max(0.25, 1 - Pump.damage / Pump.max_damage)
+
+ else
+ ingest_abs_mult *= 0.2
+
+ if(Cycler) // If we're damaged, we empty our tank slower.
+ ingest_rem_mult = max(0.1, 1 - (Cycler.damage / Cycler.max_damage))
+
+ else
+ ingest_rem_mult = 0.1
+
+ else if(active_metab.metabolism_class == CHEM_TOUCH) // Machines don't exactly absorb chemicals.
+ removed *= 0.5
if(filtered_organs && filtered_organs.len)
for(var/organ_tag in filtered_organs)
diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Core.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Core.dm
index cd011cc362..b8f8732bf2 100644
--- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Core.dm
+++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Core.dm
@@ -18,6 +18,7 @@
..()
if(data && data["blood_colour"])
color = data["blood_colour"]
+
return
/datum/reagent/blood/get_data() // Just in case you have a reagent that handles data differently.
@@ -49,6 +50,11 @@
H.adjust_nutrition(removed)
is_vampire = 1 //VOREStation Edit END
if(alien == IS_SLIME) // Treat it like nutriment for the jello, but not equivalent.
+ if(data["species"] == M.species.name) // Unless it's Promethean goo, then refill this one's goo.
+ M.inject_blood(src, volume * volume_mod)
+ remove_self(volume)
+ return
+
M.heal_organ_damage(0.2 * removed * volume_mod, 0) // More 'effective' blood means more usable material.
M.adjust_nutrition(20 * removed * volume_mod)
M.add_chemical_effect(CE_BLOODRESTORE, 4 * removed)
@@ -91,6 +97,23 @@
if(alien == IS_SLIME) //They don't have blood, so it seems weird that they would instantly 'process' the chemical like another species does.
affect_ingest(M, alien, removed)
return
+
+ if(M.isSynthetic())
+ return
+
+ if(ishuman(M))
+ var/mob/living/carbon/human/H = M
+
+ var/datum/reagent/blood/recipient = H.get_blood(H.vessel)
+
+ if(recipient && blood_incompatible(data["blood_type"], recipient.data["blood_type"], data["species"], recipient.data["species"]))
+ H.inject_blood(src, removed * volume_mod)
+
+ if(!H.isSynthetic() && data["species"] == "synthetic") // Remember not to inject oil into your veins, it's bad for you.
+ H.reagents.add_reagent("toxin", removed * 1.5)
+
+ return
+
M.inject_blood(src, volume * volume_mod)
remove_self(volume)
diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Medicine.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Medicine.dm
index 681929691a..ea23d01a0a 100644
--- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Medicine.dm
+++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Medicine.dm
@@ -1481,6 +1481,7 @@
color = "#555555"
metabolism = REM * 4 // Nanomachines gotta go fast.
scannable = 1
+ affects_robots = TRUE
/datum/reagent/healing_nanites/affect_blood(var/mob/living/carbon/M, var/alien, var/removed)
M.heal_organ_damage(2 * removed, 2 * removed)
diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Other.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Other.dm
index ba7dc93d63..1c33de0cb6 100644
--- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Other.dm
+++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Other.dm
@@ -487,6 +487,24 @@
reagent_state = LIQUID
color = "#C8A5DC"
+ affects_robots = TRUE
+
+/datum/reagent/coolant/affect_blood(var/mob/living/carbon/M, var/alien, var/removed)
+ if(M.isSynthetic() && ishuman(M))
+ var/mob/living/carbon/human/H = M
+
+ var/datum/reagent/blood/coolant = H.get_blood(H.vessel)
+
+ if(coolant)
+ H.vessel.add_reagent("blood", removed, coolant.data)
+
+ else
+ H.vessel.add_reagent("blood", removed)
+ H.fixblood()
+
+ else
+ ..()
+
/datum/reagent/ultraglue
name = "Ultra Glue"
id = "glue"
diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Toxins.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Toxins.dm
index e18c2e56d9..dd0ea4c08f 100644
--- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Toxins.dm
+++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Toxins.dm
@@ -1013,6 +1013,7 @@ datum/reagent/talum_quem/affect_blood(var/mob/living/carbon/M, var/alien, var/re
reagent_state = SOLID
color = "#555555"
metabolism = REM * 4 // Nanomachines. Fast.
+ affects_robots = TRUE
/datum/reagent/shredding_nanites/affect_blood(var/mob/living/carbon/M, var/alien, var/removed)
M.adjustBruteLoss(4 * removed)
@@ -1026,6 +1027,7 @@ datum/reagent/talum_quem/affect_blood(var/mob/living/carbon/M, var/alien, var/re
reagent_state = SOLID
color = "#555555"
metabolism = REM * 4
+ affects_robots = TRUE
/datum/reagent/irradiated_nanites/affect_blood(var/mob/living/carbon/M, var/alien, var/removed)
SSradiation.radiate(get_turf(M), 20) // Irradiate people around you.
@@ -1040,6 +1042,7 @@ datum/reagent/talum_quem/affect_blood(var/mob/living/carbon/M, var/alien, var/re
color = "#555555"
metabolism = REM * 4
filtered_organs = list(O_SPLEEN)
+ affects_robots = TRUE
/datum/reagent/neurophage_nanites/affect_blood(var/mob/living/carbon/M, var/alien, var/removed)
M.adjustBrainLoss(2 * removed) // Their job is to give you a bad time.
diff --git a/code/modules/research/prosfab_designs.dm b/code/modules/research/prosfab_designs.dm
index da9cc05509..7882be40b5 100644
--- a/code/modules/research/prosfab_designs.dm
+++ b/code/modules/research/prosfab_designs.dm
@@ -193,6 +193,34 @@
materials = list(DEFAULT_WALL_MATERIAL = 5625, "glass" = 5625)
// req_tech = list(TECH_ENGINEERING = 2, TECH_MATERIAL = 2)
+/datum/design/item/prosfab/pros/internal/hydraulic
+ name = "Hydraulic Hub"
+ id = "pros_hydraulic"
+ build_path = /obj/item/organ/internal/heart/machine
+ time = 15
+ materials = list(DEFAULT_WALL_MATERIAL = 7500, MAT_PLASTIC = 3000)
+
+/datum/design/item/prosfab/pros/internal/reagcycler
+ name = "Reagent Cycler"
+ id = "pros_reagcycler"
+ build_path = /obj/item/organ/internal/stomach/machine
+ time = 15
+ materials = list(DEFAULT_WALL_MATERIAL = 7500, MAT_PLASTIC = 3000)
+
+/datum/design/item/prosfab/pros/internal/heatsink
+ name = "Heatsink"
+ id = "pros_heatsink"
+ build_path = /obj/item/organ/internal/robotic/heatsink
+ time = 15
+ materials = list(DEFAULT_WALL_MATERIAL = 7500, MAT_PLASTIC = 3000)
+
+/datum/design/item/prosfab/pros/internal/diagnostic
+ name = "Diagnostic Controller"
+ id = "pros_diagnostic"
+ build_path = /obj/item/organ/internal/robotic/diagnostic
+ time = 15
+ materials = list(DEFAULT_WALL_MATERIAL = 7500, MAT_PLASTIC = 3000)
+
/datum/design/item/prosfab/pros/internal/heart
name = "Prosthetic Heart"
id = "pros_heart"
diff --git a/vorestation.dme b/vorestation.dme
index c860cdab61..9fab99a66c 100644
--- a/vorestation.dme
+++ b/vorestation.dme
@@ -2985,6 +2985,9 @@
#include "code\modules\organs\internal\voicebox.dm"
#include "code\modules\organs\internal\augment\armmounted.dm"
#include "code\modules\organs\internal\augment\bio.dm"
+#include "code\modules\organs\internal\robotic\diagnostic.dm"
+#include "code\modules\organs\internal\robotic\heatsink.dm"
+#include "code\modules\organs\internal\robotic\robotic.dm"
#include "code\modules\organs\subtypes\diona.dm"
#include "code\modules\organs\subtypes\indestructible.dm"
#include "code\modules\organs\subtypes\machine.dm"