mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 03:27:05 +01:00
@@ -84,7 +84,7 @@
|
||||
/proc/get_pain_modifier(mob/living/carbon/human/M) //returns modfier to make surgery harder if patient is conscious and feels pain
|
||||
if(M.stat) //stat=0 if CONSCIOUS, 1=UNCONSCIOUS and 2=DEAD. Operating on dead people is easy, too. Just sleeping won't work, though.
|
||||
return 1
|
||||
if(NO_PAIN in M.species.species_traits)//if you don't feel pain, you can hold still
|
||||
if(NO_PAIN in M.dna.species.species_traits)//if you don't feel pain, you can hold still
|
||||
return 1
|
||||
if(M.reagents.has_reagent("hydrocodone"))//really good pain killer
|
||||
return 0.99
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
if(ishuman(target))
|
||||
var/mob/living/carbon/human/H = target
|
||||
var/obj/item/organ/external/affected = H.get_organ(user.zone_sel.selecting)
|
||||
if(target.get_species() == "Machine")
|
||||
if(ismachine(target))
|
||||
// RIP bi-centennial man
|
||||
return 0
|
||||
if(!affected)
|
||||
@@ -76,7 +76,7 @@
|
||||
var/obj/item/organ/external/affected = target.get_organ(target_zone)
|
||||
if(affected)
|
||||
return 0
|
||||
var/list/organ_data = target.species.has_limbs["[target_zone]"]
|
||||
var/list/organ_data = target.dna.species.has_limbs["[target_zone]"]
|
||||
return !isnull(organ_data)
|
||||
|
||||
/datum/surgery_step/limb/attach
|
||||
@@ -233,7 +233,7 @@
|
||||
for(var/part_name in L.part)
|
||||
if(!isnull(target.get_organ(part_name)))
|
||||
continue
|
||||
var/list/organ_data = target.species.has_limbs["[part_name]"]
|
||||
var/list/organ_data = target.dna.species.has_limbs["[part_name]"]
|
||||
if(!organ_data)
|
||||
continue
|
||||
// This will break if there's more than one stump ever
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
var/mob/living/carbon/human/H = HA
|
||||
if(!istype(H))
|
||||
H = owner
|
||||
var/icon/cybereyes_icon = new /icon('icons/mob/human_face.dmi', H.species.eyes)
|
||||
var/icon/cybereyes_icon = new /icon('icons/mob/human_face.dmi', H.dna.species.eyes)
|
||||
cybereyes_icon.Blend(eye_colour, ICON_ADD) // Eye implants override native DNA eye color
|
||||
|
||||
return cybereyes_icon
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
/mob/living/carbon/human/handle_blood()
|
||||
var/list/blood_data = get_blood_data(get_blood_id())//PROCCEPTION
|
||||
|
||||
if(NO_BLOOD in species.species_traits)
|
||||
if(NO_BLOOD in dna.species.species_traits)
|
||||
bleed_rate = 0
|
||||
return
|
||||
|
||||
@@ -43,14 +43,14 @@
|
||||
if(BLOOD_VOLUME_OKAY to BLOOD_VOLUME_SAFE)
|
||||
if(prob(5))
|
||||
to_chat(src, "<span class='warning'>You feel [word].</span>")
|
||||
apply_damage_type(round((BLOOD_VOLUME_NORMAL - blood_volume) * 0.01, 1), species.blood_damage_type)
|
||||
apply_damage_type(round((BLOOD_VOLUME_NORMAL - blood_volume) * 0.01, 1), dna.species.blood_damage_type)
|
||||
if(BLOOD_VOLUME_BAD to BLOOD_VOLUME_OKAY)
|
||||
apply_damage_type(round((BLOOD_VOLUME_NORMAL - blood_volume) * 0.02, 1), species.blood_damage_type)
|
||||
apply_damage_type(round((BLOOD_VOLUME_NORMAL - blood_volume) * 0.02, 1), dna.species.blood_damage_type)
|
||||
if(prob(5))
|
||||
EyeBlurry(6)
|
||||
to_chat(src, "<span class='warning'>You feel very [word].</span>")
|
||||
if(BLOOD_VOLUME_SURVIVE to BLOOD_VOLUME_BAD)
|
||||
apply_damage_type(5, species.blood_damage_type)
|
||||
apply_damage_type(5, dna.species.blood_damage_type)
|
||||
if(prob(15))
|
||||
Paralyse(rand(1,3))
|
||||
to_chat(src, "<span class='warning'>You feel extremely [word].</span>")
|
||||
@@ -99,9 +99,9 @@
|
||||
add_splatter_floor(loc, 1)
|
||||
|
||||
/mob/living/carbon/human/bleed(amt)
|
||||
if(!(NO_BLOOD in species.species_traits))
|
||||
if(!(NO_BLOOD in dna.species.species_traits))
|
||||
..()
|
||||
if(species.exotic_blood)
|
||||
if(dna.species.exotic_blood)
|
||||
var/datum/reagent/R = chemical_reagents_list[get_blood_id()]
|
||||
if(istype(R) && isturf(loc))
|
||||
R.reaction_turf(get_turf(src), amt)
|
||||
@@ -186,7 +186,7 @@
|
||||
blood_data["blood_type"] = copytext(src.dna.b_type,1,0)
|
||||
blood_data["gender"] = gender
|
||||
blood_data["real_name"] = real_name
|
||||
blood_data["blood_color"] = species.blood_color
|
||||
blood_data["blood_color"] = dna.species.blood_color
|
||||
blood_data["factions"] = faction
|
||||
return blood_data
|
||||
|
||||
@@ -199,9 +199,9 @@
|
||||
return "blood"
|
||||
|
||||
/mob/living/carbon/human/get_blood_id()
|
||||
if(species.exotic_blood)//some races may bleed water..or kethcup..
|
||||
return species.exotic_blood
|
||||
else if((NO_BLOOD in species.species_traits) || (NOCLONE in mutations))
|
||||
if(dna.species.exotic_blood)//some races may bleed water..or kethcup..
|
||||
return dna.species.exotic_blood
|
||||
else if((NO_BLOOD in dna.species.species_traits) || (NOCLONE in mutations))
|
||||
return
|
||||
return "blood"
|
||||
|
||||
@@ -279,7 +279,7 @@
|
||||
B.layer = BELOW_MOB_LAYER //So the blood lands ontop of things like posters, windows, etc.
|
||||
|
||||
/mob/living/carbon/human/add_splatter_floor(turf/T, small_drip, shift_x, shift_y)
|
||||
if(!(NO_BLOOD in species.species_traits))
|
||||
if(!(NO_BLOOD in dna.species.species_traits))
|
||||
..()
|
||||
|
||||
/mob/living/carbon/alien/add_splatter_floor(turf/T, small_drip, shift_x, shift_y)
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
var/mob/living/carbon/human/H = HA
|
||||
if(!istype(H))
|
||||
H = owner
|
||||
var/icon/eyes_icon = new /icon('icons/mob/human_face.dmi', H.species.eyes)
|
||||
var/icon/eyes_icon = new /icon('icons/mob/human_face.dmi', H.dna.species.eyes)
|
||||
eyes_icon.Blend(eye_colour, ICON_ADD)
|
||||
|
||||
return eyes_icon
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
|
||||
/obj/item/organ/internal/heart/cursed/attack(mob/living/carbon/human/H, mob/living/carbon/human/user, obj/target)
|
||||
if(H == user && istype(H))
|
||||
if(NO_BLOOD in H.species.species_traits)
|
||||
if(NO_BLOOD in H.dna.species.species_traits)
|
||||
to_chat(H, "<span class = 'userdanger'>\The [src] is not compatible with your form!</span>")
|
||||
return
|
||||
playsound(user,'sound/effects/singlebeat.ogg', 40, 1)
|
||||
@@ -98,7 +98,7 @@
|
||||
if(world.time > (last_pump + pump_delay))
|
||||
if(ishuman(owner) && owner.client) //While this entire item exists to make people suffer, they can't control disconnects.
|
||||
var/mob/living/carbon/human/H = owner
|
||||
if(!(NO_BLOOD in H.species.species_traits))
|
||||
if(!(NO_BLOOD in H.dna.species.species_traits))
|
||||
H.blood_volume = max(H.blood_volume - blood_loss, 0)
|
||||
to_chat(H, "<span class='userdanger'>You have to keep pumping your blood!</span>")
|
||||
if(H.client)
|
||||
@@ -131,7 +131,7 @@
|
||||
|
||||
var/mob/living/carbon/human/H = owner
|
||||
if(istype(H))
|
||||
if(!(NO_BLOOD in H.species.species_traits))
|
||||
if(!(NO_BLOOD in H.dna.species.species_traits))
|
||||
H.blood_volume = min(H.blood_volume + cursed_heart.blood_loss*0.5, BLOOD_VOLUME_NORMAL)
|
||||
if(owner.client)
|
||||
owner.client.color = ""
|
||||
|
||||
@@ -154,12 +154,12 @@
|
||||
if(safe_nitro_min)
|
||||
if(N2_pp < safe_nitro_min)
|
||||
gas_breathed = handle_too_little_breath(H, N2_pp, safe_nitro_min, breath.nitrogen)
|
||||
H.throw_alert("nitro", /obj/screen/alert/not_enough_nitro)
|
||||
H.throw_alert("not_enough_nitro", /obj/screen/alert/not_enough_nitro)
|
||||
else
|
||||
H.failed_last_breath = FALSE
|
||||
H.adjustOxyLoss(-5)
|
||||
gas_breathed = breath.nitrogen
|
||||
H.clear_alert("nitro")
|
||||
H.clear_alert("not_enough_nitro")
|
||||
|
||||
//Exhale
|
||||
breath.nitrogen -= gas_breathed
|
||||
@@ -271,11 +271,11 @@
|
||||
var/breath_temperature = breath.temperature
|
||||
|
||||
var/species_traits = list()
|
||||
if(H && H.species && H.species.species_traits)
|
||||
species_traits = H.species.species_traits
|
||||
if(H && H.dna.species && H.dna.species.species_traits)
|
||||
species_traits = H.dna.species.species_traits
|
||||
|
||||
if(!(COLDRES in H.mutations) && !(RESISTCOLD in species_traits)) // COLD DAMAGE
|
||||
var/CM = abs(H.species.coldmod)
|
||||
var/CM = abs(H.dna.species.coldmod)
|
||||
var/TC = 0
|
||||
if(breath_temperature < cold_level_3_threshold)
|
||||
TC = cold_level_3_damage
|
||||
@@ -291,7 +291,7 @@
|
||||
to_chat(H, "<span class='warning'>You feel [cold_message] in your [name]!</span>")
|
||||
|
||||
if(!(HEATRES in H.mutations) && !(RESISTHOT in species_traits)) // HEAT DAMAGE
|
||||
var/HM = abs(H.species.heatmod)
|
||||
var/HM = abs(H.dna.species.heatmod)
|
||||
var/TH = 0
|
||||
if(breath_temperature > heat_level_1_threshold && breath_temperature < heat_level_2_threshold)
|
||||
TH = heat_level_1_damage
|
||||
@@ -315,7 +315,6 @@
|
||||
name = "plasma filter"
|
||||
desc = "A spongy rib-shaped mass for filtering plasma from the air."
|
||||
icon_state = "lungs-plasma"
|
||||
species = "Plasmaman"
|
||||
|
||||
safe_oxygen_min = 0 //We don't breath this
|
||||
safe_toxins_min = 16 //We breathe THIS!
|
||||
@@ -324,7 +323,6 @@
|
||||
/obj/item/organ/internal/lungs/vox
|
||||
name = "Vox lungs"
|
||||
desc = "They're filled with dust....wow."
|
||||
species = "Vox"
|
||||
|
||||
safe_oxygen_min = 0 //We don't breathe this
|
||||
safe_oxygen_max = 1 //This is toxic to us
|
||||
@@ -333,7 +331,6 @@
|
||||
|
||||
/obj/item/organ/internal/lungs/drask
|
||||
icon = 'icons/obj/surgery_drask.dmi'
|
||||
species = "Drask"
|
||||
|
||||
cold_message = "an invigorating coldness"
|
||||
cold_level_3_threshold = 60
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
// Used for an MMI or robotic brain being installed into a human.
|
||||
/obj/item/organ/internal/brain/mmi_holder
|
||||
name = "Man-Machine Interface"
|
||||
parent_organ = "chest"
|
||||
status = ORGAN_ROBOT
|
||||
var/obj/item/mmi/stored_mmi
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/Destroy()
|
||||
QDEL_NULL(stored_mmi)
|
||||
return ..()
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/insert(mob/living/target, special = 0)
|
||||
..()
|
||||
// To supersede the over-writing of the MMI's name from `insert`
|
||||
update_from_mmi()
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/remove(mob/living/user, special = 0)
|
||||
if(!special)
|
||||
if(stored_mmi)
|
||||
. = stored_mmi
|
||||
if(owner.mind)
|
||||
owner.mind.transfer_to(stored_mmi.brainmob)
|
||||
stored_mmi.forceMove(get_turf(owner))
|
||||
stored_mmi = null
|
||||
..()
|
||||
if(!QDELETED(src))
|
||||
qdel(src)
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/proc/update_from_mmi()
|
||||
if(!stored_mmi)
|
||||
return
|
||||
name = initial(stored_mmi.name)
|
||||
desc = stored_mmi.desc
|
||||
icon = stored_mmi.icon
|
||||
icon_state = stored_mmi.icon_state
|
||||
set_dna(stored_mmi.brainmob.dna)
|
||||
@@ -19,7 +19,6 @@
|
||||
// links chemical IDs to number of ticks for which they'll stay in the blood
|
||||
germ_level = 0
|
||||
var/datum/dna/dna
|
||||
var/datum/species/species = "Human"
|
||||
|
||||
// Stuff for tracking if this is on a tile with an open freezer or not
|
||||
var/last_freezer_update_time = 0
|
||||
@@ -30,6 +29,7 @@
|
||||
var/tough = FALSE //can organ be easily damaged?
|
||||
var/emp_proof = FALSE //is the organ immune to EMPs?
|
||||
var/hidden_pain = FALSE //will it skip pain messages?
|
||||
var/requires_robotic_bodypart = FALSE
|
||||
|
||||
|
||||
/obj/item/organ/Destroy()
|
||||
@@ -43,15 +43,13 @@
|
||||
/obj/item/organ/proc/update_health()
|
||||
return
|
||||
|
||||
/obj/item/organ/New(var/mob/living/carbon/holder)
|
||||
/obj/item/organ/New(mob/living/carbon/holder, datum/species/species_override = null)
|
||||
..(holder)
|
||||
if(!max_damage)
|
||||
max_damage = min_broken_damage * 2
|
||||
if(istype(holder))
|
||||
species = all_species["Human"]
|
||||
if(holder.dna)
|
||||
dna = holder.dna.Clone()
|
||||
species = all_species[dna.species]
|
||||
else
|
||||
log_runtime(EXCEPTION("[holder] spawned without a proper DNA."), holder)
|
||||
var/mob/living/carbon/human/H = holder
|
||||
@@ -61,8 +59,9 @@
|
||||
blood_DNA = list()
|
||||
blood_DNA[dna.unique_enzymes] = dna.b_type
|
||||
else
|
||||
if(istext(species))
|
||||
species = all_species[species]
|
||||
dna = new /datum/dna(null)
|
||||
if(species_override)
|
||||
dna.species = new species_override
|
||||
|
||||
/obj/item/organ/proc/set_dna(var/datum/dna/new_dna)
|
||||
if(new_dna)
|
||||
@@ -92,7 +91,7 @@
|
||||
return
|
||||
|
||||
//Process infections
|
||||
if(is_robotic() || sterile || (owner && (IS_PLANT in owner.species.species_traits)))
|
||||
if(is_robotic() || sterile || (owner && (IS_PLANT in owner.dna.species.species_traits)))
|
||||
germ_level = 0
|
||||
return
|
||||
|
||||
@@ -154,7 +153,7 @@
|
||||
germ_level++
|
||||
|
||||
if(germ_level >= INFECTION_LEVEL_ONE)
|
||||
var/fever_temperature = (owner.species.heat_level_1 - owner.species.body_temperature - 5)* min(germ_level/INFECTION_LEVEL_TWO, 1) + owner.species.body_temperature
|
||||
var/fever_temperature = (owner.dna.species.heat_level_1 - owner.dna.species.body_temperature - 5)* min(germ_level/INFECTION_LEVEL_TWO, 1) + owner.dna.species.body_temperature
|
||||
owner.bodytemperature += between(0, (fever_temperature - T20C)/BODYTEMP_COLD_DIVISOR + 1, fever_temperature - owner.bodytemperature)
|
||||
|
||||
if(germ_level >= INFECTION_LEVEL_TWO)
|
||||
|
||||
@@ -105,13 +105,12 @@
|
||||
/obj/item/organ/external/New(var/mob/living/carbon/holder)
|
||||
..()
|
||||
var/mob/living/carbon/human/H = holder
|
||||
icobase = species.icobase
|
||||
deform = species.deform
|
||||
icobase = dna.species.icobase
|
||||
deform = dna.species.deform
|
||||
if(istype(H))
|
||||
replaced(H)
|
||||
sync_colour_to_human(H)
|
||||
spawn(1)
|
||||
get_icon()
|
||||
get_icon()
|
||||
|
||||
/obj/item/organ/external/replaced(var/mob/living/carbon/human/target)
|
||||
owner = target
|
||||
@@ -279,7 +278,8 @@ This function completely restores a damaged organ to perfect condition.
|
||||
for(var/obj/item/organ/external/EO in contents)
|
||||
EO.rejuvenate()
|
||||
|
||||
owner.updatehealth()
|
||||
if(owner)
|
||||
owner.updatehealth()
|
||||
update_icon()
|
||||
if(!owner)
|
||||
processing_objects |= src
|
||||
@@ -328,7 +328,7 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
*/
|
||||
/obj/item/organ/external/proc/update_germs()
|
||||
|
||||
if(is_robotic() || (IS_PLANT in owner.species.species_traits)) //Robotic limbs shouldn't be infected, nor should nonexistant limbs.
|
||||
if(is_robotic() || (IS_PLANT in owner.dna.species.species_traits)) //Robotic limbs shouldn't be infected, nor should nonexistant limbs.
|
||||
germ_level = 0
|
||||
return
|
||||
|
||||
@@ -400,7 +400,7 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
fracture()
|
||||
|
||||
/obj/item/organ/external/proc/check_for_internal_bleeding(damage)
|
||||
if(NO_BLOOD in owner.species.species_traits)
|
||||
if(NO_BLOOD in owner.dna.species.species_traits)
|
||||
return
|
||||
var/local_damage = brute_dam + damage
|
||||
if(damage > 15 && local_damage > 30 && prob(damage) && !is_robotic())
|
||||
@@ -449,7 +449,7 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
****************************************************/
|
||||
|
||||
//Handles dismemberment
|
||||
/obj/item/organ/external/proc/droplimb(var/clean, var/disintegrate, var/ignore_children, var/nodamage)
|
||||
/obj/item/organ/external/proc/droplimb(clean, disintegrate, ignore_children, nodamage)
|
||||
|
||||
if(cannot_amputate || !owner)
|
||||
return
|
||||
@@ -494,16 +494,17 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
parent.receive_damage(total_brute, total_burn, ignore_resists = TRUE) //Transfer the full damage to the parent, bypass limb damage reduction.
|
||||
parent = null
|
||||
|
||||
spawn(1)
|
||||
if(victim)
|
||||
victim.updatehealth()
|
||||
victim.UpdateDamageIcon()
|
||||
victim.regenerate_icons()
|
||||
dir = 2
|
||||
|
||||
if(victim)
|
||||
victim.updatehealth()
|
||||
victim.UpdateDamageIcon()
|
||||
victim.regenerate_icons()
|
||||
|
||||
switch(disintegrate)
|
||||
if(DROPLIMB_SHARP)
|
||||
compile_icon()
|
||||
add_blood(victim.blood_DNA, victim.species.blood_color)
|
||||
add_blood(victim.blood_DNA, victim.dna.species.blood_color)
|
||||
var/matrix/M = matrix()
|
||||
M.Turn(rand(180))
|
||||
src.transform = M
|
||||
@@ -513,7 +514,7 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
dropped_part.throw_at(get_edge_target_turf(src,pick(alldirs)),rand(1,3),30)
|
||||
dir = 2
|
||||
brute_dam = 0
|
||||
burn_dam = 0 //Reset the damage on the limb; the damage should have transferred to the parent; we don't want extra damage being re-applie when then limb is re-attached
|
||||
burn_dam = 0 //Reset the damage on the limb; the damage should have transferred to the parent; we don't want extra damage being re-applied when then limb is re-attached
|
||||
return dropped_part
|
||||
else
|
||||
qdel(src) // If you flashed away to ashes, YOU FLASHED AWAY TO ASHES
|
||||
@@ -606,7 +607,7 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
"<span class='warning'>You hear a loud cracking sound coming from \the [owner].</span>",\
|
||||
"<span class='danger'>Something feels like it shattered in your [name]!</span>",\
|
||||
"You hear a sickening crack.")
|
||||
if(owner.species && !(NO_PAIN in owner.species.species_traits))
|
||||
if(owner.dna.species && !(NO_PAIN in owner.dna.species.species_traits))
|
||||
owner.emote("scream")
|
||||
|
||||
status |= ORGAN_BROKEN
|
||||
|
||||
@@ -16,7 +16,7 @@ var/global/list/limb_icon_cache = list()
|
||||
|
||||
/obj/item/organ/external/proc/change_organ_icobase(var/new_icobase, var/new_deform, var/owner_sensitive) //Change the icobase/deform of this organ. If owner_sensitive is set, that means the proc won't mess with frankenstein limbs.
|
||||
if(owner_sensitive) //This and the below statements mean that the icobase/deform will only get updated if the limb is the same species as and is owned by the mob it's attached to.
|
||||
if(species && owner.species && species.name != owner.species.name)
|
||||
if(dna.species && owner.dna.species && dna.species.name != owner.dna.species.name)
|
||||
return
|
||||
if(dna.unique_enzymes != owner.dna.unique_enzymes) // This isn't MY arm
|
||||
return
|
||||
@@ -25,31 +25,31 @@ var/global/list/limb_icon_cache = list()
|
||||
deform = new_deform ? new_deform : deform
|
||||
|
||||
/obj/item/organ/external/proc/sync_colour_to_human(var/mob/living/carbon/human/H)
|
||||
if(is_robotic() && !(species && species.name == "Machine")) //machine people get skin color
|
||||
if(is_robotic() && !istype(dna.species, /datum/species/machine)) //machine people get skin color
|
||||
return
|
||||
if(species && H.species && species.name != H.species.name)
|
||||
if(dna.species && H.dna.species && dna.species.name != H.dna.species.name)
|
||||
return
|
||||
if(dna.unique_enzymes != H.dna.unique_enzymes) // This isn't MY arm
|
||||
if(!(H.species.bodyflags & HAS_ICON_SKIN_TONE))
|
||||
if(!(H.dna.species.bodyflags & HAS_ICON_SKIN_TONE))
|
||||
sync_colour_to_dna()
|
||||
return
|
||||
if(!isnull(H.s_tone) && ((H.species.bodyflags & HAS_SKIN_TONE) || (H.species.bodyflags & HAS_ICON_SKIN_TONE)))
|
||||
if(!isnull(H.s_tone) && ((H.dna.species.bodyflags & HAS_SKIN_TONE) || (H.dna.species.bodyflags & HAS_ICON_SKIN_TONE)))
|
||||
s_col = null
|
||||
s_tone = H.s_tone
|
||||
if(H.species.bodyflags & HAS_SKIN_COLOR)
|
||||
if(H.dna.species.bodyflags & HAS_SKIN_COLOR)
|
||||
s_tone = null
|
||||
s_col = H.skin_colour
|
||||
if(H.species.bodyflags & HAS_ICON_SKIN_TONE)
|
||||
if(H.dna.species.bodyflags & HAS_ICON_SKIN_TONE)
|
||||
var/obj/item/organ/external/chest/C = H.get_organ("chest")
|
||||
change_organ_icobase(C.icobase, C.deform)
|
||||
|
||||
/obj/item/organ/external/proc/sync_colour_to_dna()
|
||||
if(is_robotic())
|
||||
return
|
||||
if(!isnull(dna.GetUIValue(DNA_UI_SKIN_TONE)) && ((species.bodyflags & HAS_SKIN_TONE) || (species.bodyflags & HAS_ICON_SKIN_TONE)))
|
||||
if(!isnull(dna.GetUIValue(DNA_UI_SKIN_TONE)) && ((dna.species.bodyflags & HAS_SKIN_TONE) || (dna.species.bodyflags & HAS_ICON_SKIN_TONE)))
|
||||
s_col = null
|
||||
s_tone = dna.GetUIValue(DNA_UI_SKIN_TONE)
|
||||
if(species.bodyflags & HAS_SKIN_COLOR)
|
||||
if(dna.species.bodyflags & HAS_SKIN_COLOR)
|
||||
s_tone = null
|
||||
s_col = rgb(dna.GetUIValue(DNA_UI_SKIN_R), dna.GetUIValue(DNA_UI_SKIN_G), dna.GetUIValue(DNA_UI_SKIN_B))
|
||||
|
||||
@@ -64,11 +64,9 @@ var/global/list/limb_icon_cache = list()
|
||||
|
||||
/obj/item/organ/external/proc/get_icon(skeletal, fat)
|
||||
// Kasparrov, you monster
|
||||
if(istext(species))
|
||||
species = all_species[species]
|
||||
if(force_icon)
|
||||
mob_icon = new /icon(force_icon, "[icon_name]")
|
||||
if(species && species.name == "Machine") //snowflake for IPC's, sorry.
|
||||
if(istype(dna.species, /datum/species/machine)) //snowflake for IPC's, sorry.
|
||||
if(s_col)
|
||||
mob_icon.Blend(s_col, ICON_ADD)
|
||||
else
|
||||
@@ -101,13 +99,13 @@ var/global/list/limb_icon_cache = list()
|
||||
if(!owner)
|
||||
return
|
||||
|
||||
if(species.has_organ["eyes"])
|
||||
if(dna.species.has_organ["eyes"])
|
||||
var/icon/eyes_icon = owner.get_eyecon()
|
||||
if(eyes_icon)
|
||||
mob_icon.Blend(eyes_icon, ICON_OVERLAY)
|
||||
overlays |= eyes_icon
|
||||
|
||||
if(owner.lip_style && (LIPS in species.species_traits))
|
||||
if(owner.lip_style && (LIPS in dna.species.species_traits))
|
||||
var/icon/lip_icon = new/icon('icons/mob/human_face.dmi', "lips_[owner.lip_style]_s")
|
||||
overlays |= lip_icon
|
||||
mob_icon.Blend(lip_icon, ICON_OVERLAY)
|
||||
@@ -115,7 +113,7 @@ var/global/list/limb_icon_cache = list()
|
||||
var/head_marking = owner.m_styles["head"]
|
||||
if(head_marking && head_marking != "None")
|
||||
var/datum/sprite_accessory/head_marking_style = marking_styles_list[head_marking]
|
||||
if(head_marking_style && head_marking_style.species_allowed && (species.name in head_marking_style.species_allowed) && head_marking_style.marking_location == "head")
|
||||
if(head_marking_style && head_marking_style.species_allowed && (dna.species.name in head_marking_style.species_allowed) && head_marking_style.marking_location == "head")
|
||||
var/icon/h_marking_s = new/icon("icon" = head_marking_style.icon, "icon_state" = "[head_marking_style.icon_state]_s")
|
||||
if(head_marking_style.do_colouration)
|
||||
h_marking_s.Blend(owner.m_colours["head"], ICON_ADD)
|
||||
@@ -123,7 +121,7 @@ var/global/list/limb_icon_cache = list()
|
||||
|
||||
if(ha_style)
|
||||
var/datum/sprite_accessory/head_accessory_style = head_accessory_styles_list[ha_style]
|
||||
if(head_accessory_style && head_accessory_style.species_allowed && (species.name in head_accessory_style.species_allowed))
|
||||
if(head_accessory_style && head_accessory_style.species_allowed && (dna.species.name in head_accessory_style.species_allowed))
|
||||
var/icon/head_accessory_s = new/icon("icon" = head_accessory_style.icon, "icon_state" = "[head_accessory_style.icon_state]_s")
|
||||
if(head_accessory_style.do_colouration)
|
||||
head_accessory_s.Blend(headacc_colour, ICON_ADD)
|
||||
@@ -131,9 +129,9 @@ var/global/list/limb_icon_cache = list()
|
||||
|
||||
if(f_style)
|
||||
var/datum/sprite_accessory/facial_hair_style = facial_hair_styles_list[f_style]
|
||||
if(facial_hair_style && ((facial_hair_style.species_allowed && (species.name in facial_hair_style.species_allowed)) || (src.species.bodyflags & ALL_RPARTS)))
|
||||
if(facial_hair_style && ((facial_hair_style.species_allowed && (dna.species.name in facial_hair_style.species_allowed)) || (dna.species.bodyflags & ALL_RPARTS)))
|
||||
var/icon/facial_s = new/icon("icon" = facial_hair_style.icon, "icon_state" = "[facial_hair_style.icon_state]_s")
|
||||
if(species.name == "Slime People") // I am el worstos
|
||||
if(istype(dna.species, /datum/species/slime)) // I am el worstos
|
||||
facial_s.Blend("[owner.skin_colour]A0", ICON_AND) //A0 = 160 alpha.
|
||||
else if(facial_hair_style.do_colouration)
|
||||
facial_s.Blend(facial_colour, ICON_ADD)
|
||||
@@ -141,9 +139,9 @@ var/global/list/limb_icon_cache = list()
|
||||
|
||||
if(h_style && !(owner.head && (owner.head.flags & BLOCKHEADHAIR)))
|
||||
var/datum/sprite_accessory/hair_style = hair_styles_full_list[h_style]
|
||||
if(hair_style && ((species.name in hair_style.species_allowed) || (src.species.bodyflags & ALL_RPARTS)))
|
||||
if(hair_style && ((dna.species.name in hair_style.species_allowed) || (dna.species.bodyflags & ALL_RPARTS)))
|
||||
var/icon/hair_s = new/icon("icon" = hair_style.icon, "icon_state" = "[hair_style.icon_state]_s")
|
||||
if(species.name == "Slime People") // I am el worstos
|
||||
if(istype(dna.species, /datum/species/slime)) // I am el worstos
|
||||
hair_s.Blend("[owner.skin_colour]A0", ICON_AND) //A0 = 160 alpha.
|
||||
else if(hair_style.do_colouration)
|
||||
hair_s.Blend(hair_colour, ICON_ADD)
|
||||
@@ -184,7 +182,7 @@ var/global/list/limb_icon_cache = list()
|
||||
|
||||
/obj/item/organ/external/chest/get_icon_state(skeletal)
|
||||
var/result = ..()
|
||||
if(fat && !skeletal && !is_robotic() && (CAN_BE_FAT in species.species_traits))
|
||||
if(fat && !skeletal && !is_robotic() && (CAN_BE_FAT in dna.species.species_traits))
|
||||
result[2] += "_fat"
|
||||
return result
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ mob/living/carbon/human/proc/custom_pain(message)
|
||||
if(stat >= UNCONSCIOUS)
|
||||
return
|
||||
|
||||
if(NO_PAIN in species.species_traits)
|
||||
if(NO_PAIN in dna.species.species_traits)
|
||||
return
|
||||
if(reagents.has_reagent("morphine"))
|
||||
return
|
||||
@@ -54,7 +54,7 @@ mob/living/carbon/human/proc/handle_pain()
|
||||
|
||||
if(stat >= UNCONSCIOUS)
|
||||
return
|
||||
if(NO_PAIN in species.species_traits)
|
||||
if(NO_PAIN in dna.species.species_traits)
|
||||
return
|
||||
if(reagents.has_reagent("morphine"))
|
||||
return
|
||||
|
||||
@@ -35,7 +35,8 @@
|
||||
/obj/item/organ/internal/body_egg/spider_eggs/remove(var/mob/living/carbon/M, var/special = 0)
|
||||
..()
|
||||
M.reagents.del_reagent("spidereggs") //purge all remaining spider eggs reagent if caught, in time.
|
||||
qdel(src) //We don't want people re-implanting these for near instant gibbings.
|
||||
if(!QDELETED(src))
|
||||
qdel(src) // prevent people re-implanting them into others
|
||||
return null
|
||||
|
||||
|
||||
@@ -114,5 +115,6 @@
|
||||
|
||||
/obj/item/organ/internal/body_egg/terror_eggs/remove(var/mob/living/carbon/M, var/special = 0)
|
||||
..()
|
||||
qdel(src) // prevent people re-implanting them into others
|
||||
if(!QDELETED(src))
|
||||
qdel(src) // prevent people re-implanting them into others
|
||||
return null
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
/obj/item/organ/internal/eyes/abductor
|
||||
name = "abductor eyeballs"
|
||||
dark_view = 3
|
||||
species = "Abductor"
|
||||
dark_view = 3
|
||||
@@ -6,7 +6,6 @@
|
||||
amputation_point = "trunk"
|
||||
encased = null
|
||||
gendered_icon = 0
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/groin/diona
|
||||
name = "fork"
|
||||
@@ -14,7 +13,6 @@
|
||||
cannot_break = 1
|
||||
amputation_point = "lower trunk"
|
||||
gendered_icon = 0
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/arm/diona
|
||||
name = "left upper tendril"
|
||||
@@ -22,7 +20,6 @@
|
||||
min_broken_damage = 20
|
||||
cannot_break = 1
|
||||
amputation_point = "upper left trunk"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/arm/right/diona
|
||||
name = "right upper tendril"
|
||||
@@ -30,7 +27,6 @@
|
||||
min_broken_damage = 20
|
||||
cannot_break = 1
|
||||
amputation_point = "upper right trunk"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/leg/diona
|
||||
name = "left lower tendril"
|
||||
@@ -38,7 +34,6 @@
|
||||
min_broken_damage = 20
|
||||
cannot_break = 1
|
||||
amputation_point = "lower left fork"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/leg/right/diona
|
||||
name = "right lower tendril"
|
||||
@@ -46,7 +41,6 @@
|
||||
min_broken_damage = 20
|
||||
cannot_break = 1
|
||||
amputation_point = "lower right fork"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/foot/diona
|
||||
name = "left foot"
|
||||
@@ -54,7 +48,6 @@
|
||||
min_broken_damage = 10
|
||||
cannot_break = 1
|
||||
amputation_point = "branch"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/foot/right/diona
|
||||
name = "right foot"
|
||||
@@ -62,19 +55,16 @@
|
||||
min_broken_damage = 10
|
||||
cannot_break = 1
|
||||
amputation_point = "branch"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/hand/diona
|
||||
name = "left grasper"
|
||||
cannot_break = 1
|
||||
amputation_point = "branch"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/hand/right/diona
|
||||
name = "right grasper"
|
||||
cannot_break = 1
|
||||
amputation_point = "branch"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/external/head/diona
|
||||
max_damage = 50
|
||||
@@ -83,16 +73,6 @@
|
||||
encased = null
|
||||
amputation_point = "upper trunk"
|
||||
gendered_icon = 0
|
||||
species = "Diona"
|
||||
|
||||
//DIONA ORGANS.
|
||||
/* /obj/item/organ/external/diona/removed()
|
||||
var/mob/living/carbon/human/H = owner
|
||||
..()
|
||||
if(!istype(H) || !H.bodyparts || !H.bodyparts.len)
|
||||
H.death()
|
||||
if(prob(50) && spawn_diona_nymph_from_organ(src))
|
||||
qdel(src) */
|
||||
|
||||
/obj/item/organ/diona/process()
|
||||
return
|
||||
@@ -101,31 +81,26 @@
|
||||
name = "neural strata"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "nymph"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/internal/brain/diona // Turns into a nymph instantly, no transplanting possible.
|
||||
name = "gas bladder"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "nymph"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/internal/kidneys/diona // Turns into a nymph instantly, no transplanting possible.
|
||||
name = "polyp segment"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "nymph"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/internal/appendix/diona // Turns into a nymph instantly, no transplanting possible.
|
||||
name = "anchoring ligament"
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "nymph"
|
||||
species = "Diona"
|
||||
|
||||
/obj/item/organ/internal/eyes/diona // Turns into a nymph instantly, no transplanting possible.
|
||||
name = "receptor node"
|
||||
icon = 'icons/mob/alien.dmi'
|
||||
icon_state = "claw"
|
||||
species = "Diona"
|
||||
|
||||
//TODO:Make absorb rads on insert
|
||||
|
||||
@@ -133,15 +108,4 @@
|
||||
name = "nutrient vessel"
|
||||
icon = 'icons/mob/alien.dmi'
|
||||
icon_state = "claw"
|
||||
alcohol_intensity = 0.5
|
||||
species = "Diona"
|
||||
|
||||
//TODO:Make absorb light on insert.
|
||||
|
||||
/*/obj/item/organ/diona/removed(var/mob/living/user)
|
||||
var/mob/living/carbon/human/H = owner
|
||||
..()
|
||||
if(!istype(H) || !H.bodyparts || !H.bodyparts.len)
|
||||
H.death()
|
||||
if(prob(50) && spawn_diona_nymph_from_organ(src))
|
||||
qdel(src) */
|
||||
alcohol_intensity = 0.5
|
||||
@@ -4,31 +4,26 @@
|
||||
icon = 'icons/obj/surgery_drask.dmi'
|
||||
icon_state = "innards"
|
||||
desc = "A greenish, slightly translucent organ. It is extremely cold."
|
||||
species = "Drask"
|
||||
|
||||
/obj/item/organ/internal/heart/drask
|
||||
name = "drask heart"
|
||||
icon = 'icons/obj/surgery_drask.dmi'
|
||||
parent_organ = "head"
|
||||
species = "Drask"
|
||||
|
||||
/obj/item/organ/internal/liver/drask
|
||||
name = "metabolic strainer"
|
||||
icon = 'icons/obj/surgery_drask.dmi'
|
||||
icon_state = "kidneys"
|
||||
alcohol_intensity = 0.8
|
||||
species = "Drask"
|
||||
|
||||
/obj/item/organ/internal/brain/drask
|
||||
icon = 'icons/obj/surgery_drask.dmi'
|
||||
icon_state = "brain2"
|
||||
mmi_icon = 'icons/obj/surgery_drask.dmi'
|
||||
mmi_icon_state = "mmi_full"
|
||||
species = "Drask"
|
||||
|
||||
/obj/item/organ/internal/eyes/drask
|
||||
name = "drask eyeballs"
|
||||
icon = 'icons/obj/surgery_drask.dmi'
|
||||
desc = "Drask eyes. They look even stranger disembodied"
|
||||
dark_view = 5
|
||||
species = "Drask"
|
||||
dark_view = 5
|
||||
@@ -1,11 +1,9 @@
|
||||
/obj/item/organ/internal/liver/grey
|
||||
alcohol_intensity = 1.6
|
||||
species = "Grey"
|
||||
|
||||
/obj/item/organ/internal/brain/grey
|
||||
icon_state = "brain-x"
|
||||
mmi_icon_state = "mmi_alien"
|
||||
species = "Grey"
|
||||
|
||||
/obj/item/organ/internal/brain/grey/insert(var/mob/living/carbon/M, var/special = 0)
|
||||
..()
|
||||
@@ -17,5 +15,4 @@
|
||||
|
||||
/obj/item/organ/internal/eyes/grey
|
||||
name = "grey eyeballs"
|
||||
dark_view = 5
|
||||
species = "Grey"
|
||||
dark_view = 5
|
||||
@@ -1,6 +1,5 @@
|
||||
/obj/item/organ/internal/liver/kidan
|
||||
alcohol_intensity = 0.5
|
||||
species = "Kidan"
|
||||
|
||||
#define KIDAN_LANTERN_HUNGERCOST 0.5
|
||||
#define KIDAN_LANTERN_MINHUNGER 150
|
||||
|
||||
@@ -5,100 +5,90 @@
|
||||
min_broken_damage = 30
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/head/ipc/New()
|
||||
/obj/item/organ/external/head/ipc/New(mob/living/carbon/holder, datum/species/species_override = null)
|
||||
..(holder, /datum/species/machine) // IPC heads need to be explicitly set to this since you can print them
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
|
||||
/obj/item/organ/external/chest/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/chest/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/groin/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/groin/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/arm/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/arm/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/arm/right/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/arm/right/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/leg/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/leg/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/leg/right/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/leg/right/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/foot/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/foot/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/foot/right/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/foot/right/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/hand/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/hand/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/external/hand/right/ipc
|
||||
encased = null
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/external/hand/right/ipc/New()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
..()
|
||||
robotize("Morpheus Cyberkinetics")
|
||||
|
||||
/obj/item/organ/internal/cell
|
||||
name = "microbattery"
|
||||
@@ -110,84 +100,37 @@
|
||||
slot = "heart"
|
||||
vital = TRUE
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
|
||||
/obj/item/organ/internal/cell/New()
|
||||
robotize()
|
||||
..()
|
||||
|
||||
/obj/item/organ/internal/eyes/optical_sensor
|
||||
name = "optical sensor"
|
||||
icon = 'icons/obj/robot_component.dmi'
|
||||
icon_state = "camera"
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
// dead_icon = "camera_broken"
|
||||
weld_proof = 1
|
||||
|
||||
/obj/item/organ/internal/eyes/optical_sensor/New()
|
||||
robotize()
|
||||
..()
|
||||
|
||||
|
||||
/obj/item/organ/internal/eyes/optical_sensor/remove(var/mob/living/user,special = 0)
|
||||
if(!special)
|
||||
to_chat(owner, "Error 404:Optical Sensors not found.")
|
||||
|
||||
. = ..()
|
||||
|
||||
// Used for an MMI or posibrain being installed into a human.
|
||||
/obj/item/organ/internal/brain/mmi_holder
|
||||
name = "brain"
|
||||
organ_tag = "brain"
|
||||
parent_organ = "chest"
|
||||
vital = TRUE
|
||||
max_damage = 200
|
||||
slot = "brain"
|
||||
status = ORGAN_ROBOT
|
||||
species = "Machine"
|
||||
var/obj/item/mmi/stored_mmi
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/Destroy()
|
||||
QDEL_NULL(stored_mmi)
|
||||
return ..()
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/insert(var/mob/living/target,special = 0)
|
||||
..()
|
||||
// To supersede the over-writing of the MMI's name from `insert`
|
||||
update_from_mmi()
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/remove(var/mob/living/user,special = 0)
|
||||
if(!special)
|
||||
if(stored_mmi)
|
||||
. = stored_mmi
|
||||
if(owner.mind)
|
||||
owner.mind.transfer_to(stored_mmi.brainmob)
|
||||
stored_mmi.forceMove(get_turf(owner))
|
||||
stored_mmi = null
|
||||
..()
|
||||
qdel(src)
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/proc/update_from_mmi()
|
||||
if(!stored_mmi)
|
||||
return
|
||||
name = stored_mmi.name
|
||||
desc = stored_mmi.desc
|
||||
icon = stored_mmi.icon
|
||||
icon_state = stored_mmi.icon_state
|
||||
set_dna(stored_mmi.brainmob.dna)
|
||||
/obj/item/organ/internal/brain/mmi_holder/posibrain
|
||||
name = "positronic brain"
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/posibrain/New()
|
||||
robotize()
|
||||
stored_mmi = new /obj/item/mmi/posibrain/ipc(src)
|
||||
..()
|
||||
spawn(1)
|
||||
if(owner)
|
||||
stored_mmi.name = "positronic brain ([owner.real_name])"
|
||||
stored_mmi.brainmob.real_name = owner.real_name
|
||||
stored_mmi.brainmob.name = stored_mmi.brainmob.real_name
|
||||
stored_mmi.icon_state = "posibrain-occupied"
|
||||
update_from_mmi()
|
||||
else
|
||||
stored_mmi.loc = get_turf(src)
|
||||
qdel(src)
|
||||
stored_mmi = new /obj/item/mmi/robotic_brain/positronic(src)
|
||||
if(!owner)
|
||||
stored_mmi.forceMove(get_turf(src))
|
||||
qdel(src)
|
||||
|
||||
/obj/item/organ/internal/brain/mmi_holder/posibrain/remove(mob/living/user, special = 0)
|
||||
if(stored_mmi && dna)
|
||||
stored_mmi.name = "[initial(name)] ([dna.real_name])"
|
||||
stored_mmi.brainmob.real_name = dna.real_name
|
||||
stored_mmi.brainmob.name = stored_mmi.brainmob.real_name
|
||||
stored_mmi.icon_state = "posibrain-occupied"
|
||||
if(!stored_mmi.brainmob.dna)
|
||||
stored_mmi.brainmob.dna = dna.Clone()
|
||||
. = ..()
|
||||
@@ -3,7 +3,6 @@
|
||||
name = "nucleation organ"
|
||||
icon = 'icons/obj/surgery.dmi'
|
||||
desc = "A crystalized human organ. /red It has a strangely iridescent glow."
|
||||
species = "Nucleation"
|
||||
|
||||
/obj/item/organ/internal/nucleation/resonant_crystal
|
||||
name = "resonant crystal"
|
||||
@@ -11,7 +10,6 @@
|
||||
organ_tag = "resonant crystal"
|
||||
parent_organ = "head"
|
||||
slot = "res_crystal"
|
||||
species = "Nucleation"
|
||||
|
||||
/obj/item/organ/internal/nucleation/strange_crystal
|
||||
name = "strange crystal"
|
||||
@@ -19,14 +17,12 @@
|
||||
organ_tag = "strange crystal"
|
||||
parent_organ = "chest"
|
||||
slot = "heart"
|
||||
species = "Nucleation"
|
||||
|
||||
/obj/item/organ/internal/eyes/luminescent_crystal
|
||||
name = "luminescent eyes"
|
||||
icon_state = "crystal-eyes"
|
||||
organ_tag = "luminescent eyes"
|
||||
light_color = "#1C1C00"
|
||||
species = "Nucleation"
|
||||
|
||||
/obj/item/organ/internal/eyes/luminescent_crystal/New()
|
||||
set_light(2)
|
||||
@@ -35,5 +31,4 @@
|
||||
/obj/item/organ/internal/brain/crystal
|
||||
name = "crystallized brain"
|
||||
icon_state = "crystal-brain"
|
||||
organ_tag = "crystallized brain"
|
||||
species = "Nucleation"
|
||||
organ_tag = "crystallized brain"
|
||||
@@ -1,4 +1,3 @@
|
||||
/obj/item/organ/internal/eyes/shadow
|
||||
name = "dark orbs"
|
||||
dark_view = 8
|
||||
species = "Shadow"
|
||||
dark_view = 8
|
||||
@@ -1,6 +1,5 @@
|
||||
/obj/item/organ/internal/liver/skrell
|
||||
alcohol_intensity = 4
|
||||
species = "Skrell"
|
||||
|
||||
/obj/item/organ/internal/headpocket
|
||||
name = "headpocket"
|
||||
@@ -10,7 +9,6 @@
|
||||
w_class = WEIGHT_CLASS_TINY
|
||||
parent_organ = "head"
|
||||
slot = "headpocket"
|
||||
species = "Skrell"
|
||||
actions_types = list(/datum/action/item_action/organ_action/toggle)
|
||||
var/obj/item/storage/internal/pocket
|
||||
|
||||
|
||||
@@ -136,9 +136,9 @@
|
||||
if(owner.gloves)
|
||||
owner.unEquip(owner.gloves)
|
||||
if(owner.l_hand)
|
||||
owner.unEquip(owner.l_hand,1)
|
||||
owner.unEquip(owner.l_hand, TRUE)
|
||||
if(owner.r_hand)
|
||||
owner.unEquip(owner.r_hand,1)
|
||||
owner.unEquip(owner.r_hand, TRUE)
|
||||
|
||||
. = ..()
|
||||
|
||||
@@ -194,17 +194,14 @@
|
||||
owner.unEquip(owner.r_ear)
|
||||
if(owner.wear_mask)
|
||||
owner.unEquip(owner.wear_mask)
|
||||
spawn(1)
|
||||
if(owner)//runtimer no runtiming
|
||||
owner.update_hair()
|
||||
owner.update_fhair()
|
||||
owner.update_head_accessory()
|
||||
owner.update_markings()
|
||||
owner.update_hair()
|
||||
owner.update_fhair()
|
||||
owner.update_head_accessory()
|
||||
owner.update_markings()
|
||||
. = ..()
|
||||
|
||||
/obj/item/organ/external/head/replaced()
|
||||
name = limb_name
|
||||
|
||||
..()
|
||||
|
||||
/obj/item/organ/external/head/receive_damage(brute, burn, sharp, used_weapon = null, list/forbidden_limbs = list(), ignore_resists = FALSE)
|
||||
@@ -224,6 +221,11 @@
|
||||
alt_head = initial(alt_head)
|
||||
icon_name = initial(icon_name)
|
||||
|
||||
/obj/item/organ/external/head/robotize(company, make_tough = 0, convert_all = 1) //Undoes alt_head business to avoid getting in the way of robotization. Make sure we pass all args down the line...
|
||||
alt_head = initial(alt_head)
|
||||
icon_name = initial(icon_name)
|
||||
..()
|
||||
|
||||
/obj/item/organ/external/head/set_dna(datum/dna/new_dna)
|
||||
..()
|
||||
new_dna.write_head_attributes(src)
|
||||
|
||||
@@ -1,17 +1,14 @@
|
||||
/obj/item/organ/internal/liver/tajaran
|
||||
alcohol_intensity = 1.4
|
||||
species = "Tajaran"
|
||||
|
||||
/obj/item/organ/internal/eyes/tajaran
|
||||
name = "tajaran eyeballs"
|
||||
species = "Tajaran"
|
||||
colourblind_matrix = MATRIX_TAJ_CBLIND //The colour matrix and darksight parameters that the mob will recieve when they get the disability.
|
||||
replace_colours = LIST_TAJ_REPLACE
|
||||
dark_view = 8
|
||||
|
||||
/obj/item/organ/internal/eyes/tajaran/farwa //Being the lesser form of Tajara, Farwas have an utterly incurable version of their colourblindness.
|
||||
name = "farwa eyeballs"
|
||||
species = "Farwa"
|
||||
colourmatrix = MATRIX_TAJ_CBLIND
|
||||
dark_view = 8
|
||||
replace_colours = LIST_TAJ_REPLACE
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
/obj/item/organ/internal/liver/unathi
|
||||
alcohol_intensity = 0.8
|
||||
species = "Unathi"
|
||||
|
||||
/obj/item/organ/internal/eyes/unathi
|
||||
name = "unathi eyeballs"
|
||||
dark_view = 3
|
||||
species = "Unathi"
|
||||
dark_view = 3
|
||||
@@ -1,16 +1,12 @@
|
||||
/obj/item/organ/internal/liver/vox
|
||||
alcohol_intensity = 1.6
|
||||
species = "Vox"
|
||||
|
||||
|
||||
/obj/item/organ/internal/stack
|
||||
name = "cortical stack"
|
||||
name = "vox cortical stack"
|
||||
icon_state = "brain-prosthetic"
|
||||
parent_organ = "head"
|
||||
organ_tag = "stack"
|
||||
slot = "vox_stack"
|
||||
status = ORGAN_ROBOT
|
||||
vital = TRUE
|
||||
|
||||
/obj/item/organ/internal/stack/vox
|
||||
name = "vox cortical stack"
|
||||
vital = TRUE
|
||||
@@ -1,18 +1,14 @@
|
||||
/obj/item/organ/internal/liver/vulpkanin
|
||||
alcohol_intensity = 1.4
|
||||
species = "Vulpkanin"
|
||||
|
||||
|
||||
/obj/item/organ/internal/eyes/vulpkanin
|
||||
name = "vulpkanin eyeballs"
|
||||
species = "Vulpkanin"
|
||||
colourblind_matrix = MATRIX_VULP_CBLIND //The colour matrix and darksight parameters that the mob will recieve when they get the disability.
|
||||
replace_colours = LIST_VULP_REPLACE
|
||||
dark_view = 8
|
||||
|
||||
/obj/item/organ/internal/eyes/vulpkanin/wolpin //Being the lesser form of Vulpkanin, Wolpins have an utterly incurable version of their colourblindness.
|
||||
name = "wolpin eyeballs"
|
||||
species = "Wolpin"
|
||||
colourmatrix = MATRIX_VULP_CBLIND
|
||||
dark_view = 8
|
||||
replace_colours = LIST_VULP_REPLACE
|
||||
replace_colours = LIST_VULP_REPLACE
|
||||
@@ -6,8 +6,6 @@
|
||||
icon_state = "antennae"
|
||||
parent_organ = "head"
|
||||
slot = "hivenode"
|
||||
species = "Wryn"
|
||||
|
||||
/obj/item/organ/internal/eyes/wryn
|
||||
dark_view = 3
|
||||
species = "Wryn"
|
||||
dark_view = 3
|
||||
@@ -101,6 +101,9 @@
|
||||
if(is_int_organ(tool))
|
||||
current_type = "insert"
|
||||
I = tool
|
||||
if(I.requires_robotic_bodypart)
|
||||
to_chat(user, "<span class='warning'>[I] is an organ that requires a robotic interface[target].</span>")
|
||||
return -1
|
||||
if(target_zone != I.parent_organ || target.get_organ_slot(I.slot))
|
||||
to_chat(user, "<span class='notice'>There is no room for [I] in [target]'s [parse_zone(target_zone)]!</span>")
|
||||
return -1
|
||||
@@ -257,12 +260,14 @@
|
||||
|
||||
else if(current_type == "insert")
|
||||
I = tool
|
||||
user.drop_item()
|
||||
I.insert(target)
|
||||
spread_germs_to_organ(I, user, tool)
|
||||
if(!user.canUnEquip(I, 0))
|
||||
if(I.requires_robotic_bodypart)
|
||||
to_chat(user, "<span class='warning'>[I] is an organ that requires a robotic interface[target].</span>")
|
||||
return FALSE
|
||||
if(!user.drop_item())
|
||||
to_chat(user, "<span class='warning'>[I] is stuck to your hand, you can't put it in [target]!</span>")
|
||||
return 0
|
||||
I.insert(target)
|
||||
spread_germs_to_organ(I, user, tool)
|
||||
|
||||
if(affected)
|
||||
user.visible_message("<span class='notice'> [user] has transplanted [tool] into [target]'s [affected.name].</span>",
|
||||
|
||||
@@ -303,7 +303,7 @@
|
||||
..()
|
||||
|
||||
/datum/surgery_step/internal/dethrall/end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool,datum/surgery/surgery)
|
||||
if(target.get_species() == "Lesser Shadowling") //Empowered thralls cannot be deconverted
|
||||
if(isshadowlinglesser(target)) //Empowered thralls cannot be deconverted
|
||||
to_chat(target, "<span class='shadowling'><b><i>NOT LIKE THIS!</i></b></span>")
|
||||
user.visible_message("<span class='warning'>[target] suddenly slams upward and knocks down [user]!</span>", \
|
||||
"<span class='userdanger'>[target] suddenly bolts up and slams you with tremendous force!</span>")
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
/datum/surgery_step/reshape_face/end_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool, datum/surgery/surgery)
|
||||
var/obj/item/organ/external/head/head = target.get_organ(target_zone)
|
||||
var/species_names = target.get_species()
|
||||
var/species_names = target.dna.species.name
|
||||
if(head.disfigured)
|
||||
head.disfigured = FALSE
|
||||
user.visible_message("[user] successfully restores [target]'s appearance!", "<span class='notice'>You successfully restore [target]'s appearance.</span>")
|
||||
|
||||
@@ -347,12 +347,12 @@
|
||||
to_chat(user, "<span class='danger'>You cannot install a computer brain into a meat enclosure.</span>")
|
||||
return -1
|
||||
|
||||
if(!target.species)
|
||||
if(!target.dna.species)
|
||||
to_chat(user, "<span class='danger'>You have no idea what species this person is. Report this on the bug tracker.</span>")
|
||||
return -1
|
||||
|
||||
if(!target.species.has_organ["brain"])
|
||||
to_chat(user, "<span class='danger'>You're pretty sure [target.species.name_plural] don't normally have a brain.</span>")
|
||||
if(!target.dna.species.has_organ["brain"])
|
||||
to_chat(user, "<span class='danger'>You're pretty sure [target.dna.species.name_plural] don't normally have a brain.</span>")
|
||||
return -1
|
||||
|
||||
if(target.get_int_organ(/obj/item/organ/internal/brain/))
|
||||
@@ -541,3 +541,60 @@
|
||||
user.visible_message("<span class='warning'> [user]'s hand slips!</span>", \
|
||||
"<span class='warning'> Your hand slips!</span>")
|
||||
return 0
|
||||
|
||||
/datum/surgery/cybernetic_customization
|
||||
name = "Cybernetic Appearance Customization"
|
||||
steps = list(/datum/surgery_step/robotics/external/unscrew_hatch, /datum/surgery_step/robotics/external/customize_appearance)
|
||||
possible_locs = list("head", "chest", "l_arm", "r_arm", "r_leg", "l_leg")
|
||||
requires_organic_bodypart = FALSE
|
||||
|
||||
/datum/surgery/cybernetic_customization/can_start(mob/user, mob/living/carbon/human/target)
|
||||
if(ishuman(target))
|
||||
var/obj/item/organ/external/affected = target.get_organ(user.zone_sel.selecting)
|
||||
if(!affected)
|
||||
return FALSE
|
||||
if(!(affected.status & ORGAN_ROBOT))
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/datum/surgery_step/robotics/external/customize_appearance
|
||||
name = "reprogram limb"
|
||||
allowed_tools = list(/obj/item/multitool = 100)
|
||||
time = 48
|
||||
|
||||
/datum/surgery_step/robotics/external/customize_appearance/can_use(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool,datum/surgery/surgery)
|
||||
if(..())
|
||||
var/obj/item/organ/external/affected = target.get_organ(target_zone)
|
||||
if(!affected)
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/datum/surgery_step/robotics/external/customize_appearance/begin_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool,datum/surgery/surgery)
|
||||
var/obj/item/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("[user] begins to reprogram the appearance of [target]'s [affected.name] with [tool]." , \
|
||||
"You begin to reprogram the appearance of [target]'s [affected.name] with [tool].")
|
||||
..()
|
||||
|
||||
/datum/surgery_step/robotics/external/customize_appearance/end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool,datum/surgery/surgery)
|
||||
var/chosen_appearance = input(user, "Select the company appearance for this limb.", "Limb Company Selection") as null|anything in selectable_robolimbs
|
||||
if(!chosen_appearance)
|
||||
return FALSE
|
||||
var/obj/item/organ/external/affected = target.get_organ(target_zone)
|
||||
affected.robotize(chosen_appearance, convert_all = FALSE)
|
||||
if(istype(affected, /obj/item/organ/external/head))
|
||||
var/obj/item/organ/external/head/head = affected
|
||||
head.h_style = "Bald" // nearly all the appearance changes for heads are non-monitors; we want to get rid of a floating screen
|
||||
target.update_hair()
|
||||
target.update_body()
|
||||
target.updatehealth()
|
||||
target.UpdateDamageIcon()
|
||||
user.visible_message("<span class='notice'> [user] reprograms the appearance of [target]'s [affected.name] with [tool].</span>", \
|
||||
"<span class='notice'> You reprogram the appearance of [target]'s [affected.name] with [tool].</span>")
|
||||
affected.open = 0
|
||||
return TRUE
|
||||
|
||||
/datum/surgery_step/robotics/external/customize_appearance/fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool,datum/surgery/surgery)
|
||||
var/obj/item/organ/external/affected = target.get_organ(target_zone)
|
||||
user.visible_message("<span class='warning'> [user]'s [tool.name] slips, failing to reprogram [target]'s [affected.name].</span>",
|
||||
"<span class='warning'> Your [tool.name] slips, failing to reprogram [target]'s [affected.name].</span>")
|
||||
return FALSE
|
||||
@@ -67,10 +67,6 @@
|
||||
//How much blood this step can get on surgeon. 1 - hands, 2 - full body.
|
||||
var/blood_level = 0
|
||||
|
||||
var/list/allowed_mob = list()
|
||||
var/list/disallowed_mob = list()
|
||||
|
||||
|
||||
/datum/surgery_step/proc/try_op(mob/user, mob/living/carbon/target, target_zone, obj/item/tool, datum/surgery/surgery)
|
||||
var/success = 0
|
||||
if(accept_hand)
|
||||
@@ -146,19 +142,8 @@
|
||||
// Checks if this step applies to the user mob at all
|
||||
/datum/surgery_step/proc/is_valid_target(mob/living/carbon/human/target)
|
||||
if(!hasorgans(target))
|
||||
return 0
|
||||
|
||||
if(allowed_mob)//can i just remove this and/or change it?
|
||||
for(var/species in allowed_mob)
|
||||
if(target.get_species() == species)
|
||||
return 1
|
||||
|
||||
if(disallowed_mob)
|
||||
for(var/species in disallowed_mob)
|
||||
if(target.get_species() == species)
|
||||
return 0
|
||||
|
||||
return 1
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
// checks whether this step can be applied with the given user and target
|
||||
/datum/surgery_step/proc/can_use(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool,datum/surgery/surgery)
|
||||
@@ -195,7 +180,7 @@
|
||||
//germ spread from surgeon touching the patient
|
||||
if(user.gloves)
|
||||
germ_level = user.gloves.germ_level
|
||||
E.germ_level += germ_level
|
||||
E.germ_level = max(germ_level, E.germ_level)
|
||||
spread_germs_by_incision(E, tool) //germ spread from environement to patient
|
||||
|
||||
/proc/spread_germs_by_incision(obj/item/organ/external/E,obj/item/tool)
|
||||
@@ -206,7 +191,7 @@
|
||||
|
||||
for(var/mob/living/carbon/human/H in view(2, E.loc))//germs from people
|
||||
if(AStar(E.loc, H.loc, /turf/proc/Distance, 2, simulated_only = 0))
|
||||
if((!(BREATHLESS in H.mutations) || !(NO_BREATHE in H.species.species_traits)) && !H.wear_mask) //wearing a mask helps preventing people from breathing cooties into open incisions
|
||||
if((!(BREATHLESS in H.mutations) || !(NO_BREATHE in H.dna.species.species_traits)) && !H.wear_mask) //wearing a mask helps preventing people from breathing cooties into open incisions
|
||||
germs += H.germ_level * 0.25
|
||||
|
||||
for(var/obj/effect/decal/cleanable/M in view(2, E.loc))//germs from messes
|
||||
|
||||
Reference in New Issue
Block a user