Tweaks to previous commits.

More tweaks to IPC fixes.
Merge resolution/compile fixes.

Further work on properly integrating, updating and fixing prosthetic options.

Repathed internal organs to organ/internal.

More work on full synthetics, changelings, overheating.

Working on getting organs to qdel properly and spawn properly when robotized.

Finalized some overheating values, added remaining prosthetic icons.

Finalizing the testing version of the full prosthetic bodies branch.

Added suit cyclers to the autolathe and map.

Fixing runtime errors.

Fixing errors.

Changelog.

Replacing limb and organ strings with constants.

Prevented brainless species from becoming full cyborgs.

Fixed issues with brain/MMIs renaming themselves inappropriately.

Various fixes and oversights.
This commit is contained in:
Zuhayr
2015-12-04 16:49:21 +10:30
parent 87afd2feb2
commit f93ea6a78f
161 changed files with 1384 additions and 1352 deletions
+4 -1
View File
@@ -131,6 +131,9 @@
return ask_verb
return speech_verb
/datum/language/proc/can_speak_special(var/mob/speaker)
return 1
// Language handling.
/mob/proc/add_language(var/language)
@@ -155,7 +158,7 @@
// Can we speak this language, as opposed to just understanding it?
/mob/proc/can_speak(datum/language/speaking)
return (universal_speak || (speaking && speaking.flags & INNATE) || speaking in src.languages)
return (speaking.can_speak_special(src) && (universal_speak || (speaking && speaking.flags & INNATE) || speaking in src.languages))
/mob/proc/get_language_prefix()
if(client && client.prefs.language_prefixes && client.prefs.language_prefixes.len)
+1 -1
View File
@@ -24,7 +24,7 @@
var/mob/living/carbon/M = other
if(!istype(M))
return 1
if(locate(/obj/item/organ/xenos/hivenode) in M.internal_organs)
if(locate(/obj/item/organ/internal/xenos/hivenode) in M.internal_organs)
return 1
return 0
+5 -4
View File
@@ -106,13 +106,14 @@
syllables = list("beep","beep","beep","beep","beep","boop","boop","boop","bop","bop","dee","dee","doo","doo","hiss","hss","buzz","buzz","bzz","ksssh","keey","wurr","wahh","tzzz")
space_chance = 10
/datum/language/machine/can_speak_special(var/mob/speaker)
return speaker.isSynthetic()
/datum/language/machine/get_random_name()
var/new_name
if(prob(70))
new_name = "[pick(list("PBU","HIU","SINA","ARMA","OSI"))]-[rand(100, 999)]"
return "[pick(list("PBU","HIU","SINA","ARMA","OSI"))]-[rand(100, 999)]"
else
new_name = pick(ai_names)
return new_name
return pick(ai_names)
//Syllable Lists
/*
@@ -11,4 +11,4 @@
/mob/living/carbon/alien/larva/New()
..()
add_language("Xenomorph") //Bonus language.
internal_organs |= new /obj/item/organ/xenos/hivenode(src)
internal_organs |= new /obj/item/organ/internal/xenos/hivenode(src)
+16 -17
View File
@@ -31,25 +31,24 @@
var/locked = 0
var/mob/living/carbon/brain/brainmob = null//The current occupant.
var/obj/item/organ/brain/brainobj = null //The current brain organ.
var/obj/item/organ/internal/brain/brainobj = null //The current brain organ.
var/obj/mecha = null//This does not appear to be used outside of reference in mecha.dm.
attackby(var/obj/item/O as obj, var/mob/user as mob)
if(istype(O,/obj/item/organ/brain) && !brainmob) //Time to stick a brain in it --NEO
if(istype(O,/obj/item/organ/internal/brain) && !brainmob) //Time to stick a brain in it --NEO
var/obj/item/organ/brain/B = O
var/obj/item/organ/internal/brain/B = O
if(B.health <= 0)
user << "\red That brain is well and truly dead."
user << "<span class='warning'>That brain is well and truly dead.</span>"
return
else if(!B.brainmob)
user << "\red You aren't sure where this brain came from, but you're pretty sure it's a useless brain."
user << "<span class='warning'>You aren't sure where this brain came from, but you're pretty sure it's useless.</span>"
return
for(var/mob/V in viewers(src, null))
V.show_message(text("\blue [user] sticks \a [O] into \the [src]."))
user.visible_message("<span class='notice'>\The [user] sticks \a [O] into \the [src].</span>")
brainmob = O:brainmob
O:brainmob = null
brainmob = B.brainmob
B.brainmob = null
brainmob.loc = src
brainmob.container = src
brainmob.stat = 0
@@ -72,9 +71,9 @@
if((istype(O,/obj/item/weapon/card/id)||istype(O,/obj/item/device/pda)) && brainmob)
if(allowed(user))
locked = !locked
user << "\blue You [locked ? "lock" : "unlock"] the brain holder."
user << "<span class='notice'>You [locked ? "lock" : "unlock"] the brain holder.</span>"
else
user << "\red Access denied."
user << "<span class='warning'>Access denied.</span>"
return
if(brainmob)
O.attack(brainmob, user)//Oh noooeeeee
@@ -84,12 +83,12 @@
//TODO: ORGAN REMOVAL UPDATE. Make the brain remain in the MMI so it doesn't lose organ data.
attack_self(mob/user as mob)
if(!brainmob)
user << "\red You upend the MMI, but there's nothing in it."
user << "<span class='warning'>You upend the MMI, but there's nothing in it.</span>"
else if(locked)
user << "\red You upend the MMI, but the brain is clamped into place."
user << "<span class='warning'>You upend the MMI, but the brain is clamped into place.</span>"
else
user << "\blue You upend the MMI, spilling the brain onto the floor."
var/obj/item/organ/brain/brain
user << "<span class='notice'>You upend the MMI, spilling the brain onto the floor.</span>"
var/obj/item/organ/internal/brain/brain
if (brainobj) //Pull brain organ out of MMI.
brainobj.loc = user.loc
brain = brainobj
@@ -158,7 +157,7 @@
brainmob << "Can't do that while incapacitated or dead."
radio.broadcasting = radio.broadcasting==1 ? 0 : 1
brainmob << "\blue Radio is [radio.broadcasting==1 ? "now" : "no longer"] broadcasting."
brainmob << "<span class='notice'>Radio is [radio.broadcasting==1 ? "now" : "no longer"] broadcasting.</span>"
Toggle_Listening()
set name = "Toggle Listening"
@@ -171,7 +170,7 @@
brainmob << "Can't do that while incapacitated or dead."
radio.listening = radio.listening==1 ? 0 : 1
brainmob << "\blue Radio is [radio.listening==1 ? "now" : "no longer"] receiving broadcast."
brainmob << "<span class='notice'>Radio is [radio.listening==1 ? "now" : "no longer"] receiving broadcast.</span>"
/obj/item/device/mmi/emp_act(severity)
if(!brainmob)
@@ -1,9 +1,9 @@
/obj/item/organ/brain
/obj/item/organ/internal/brain
name = "brain"
health = 400 //They need to live awhile longer than other organs. Is this even used by organ code anymore?
desc = "A piece of juicy meat found in a person's head."
organ_tag = "brain"
parent_organ = "head"
parent_organ = BP_HEAD
vital = 1
icon_state = "brain2"
force = 1.0
@@ -15,89 +15,86 @@
attack_verb = list("attacked", "slapped", "whacked")
var/mob/living/carbon/brain/brainmob = null
/obj/item/organ/internal/brain/robotize()
replace_self_with(/obj/item/organ/internal/mmi_holder/posibrain)
/obj/item/organ/brain/robotize()
replace_self_with(/obj/item/organ/mmi_holder/posibrain)
/obj/item/organ/internal/brain/mechassist()
replace_self_with(/obj/item/organ/internal/mmi_holder)
/obj/item/organ/brain/mechassist()
replace_self_with(/obj/item/organ/mmi_holder)
/obj/item/organ/internal/brain/proc/replace_self_with(replace_path)
var/mob/living/carbon/human/tmp_owner = owner
qdel(src)
if(tmp_owner)
tmp_owner.internal_organs_by_name[organ_tag] = new replace_path(tmp_owner, 1)
tmp_owner = null
/obj/item/organ/brain/proc/replace_self_with(replace_path)
if(!owner)
new replace_path(src.loc)
qdel(src)
return
owner.internal_organs_by_name[organ_tag] = new replace_path(owner, 1)
owner.internal_organs -= src
while(null in owner.internal_organs_by_name)
owner.internal_organs_by_name -= null
while(null in owner.internal_organs)
owner.internal_organs -= null
/obj/item/organ/pariah_brain
/obj/item/organ/internal/pariah_brain
name = "brain remnants"
desc = "Did someone tread on this? It looks useless for cloning or cyborgification."
organ_tag = "brain"
parent_organ = "head"
parent_organ = BP_HEAD
icon = 'icons/mob/alien.dmi'
icon_state = "chitin"
vital = 1
/obj/item/organ/brain/xeno
/obj/item/organ/internal/brain/xeno
name = "thinkpan"
desc = "It looks kind of like an enormous wad of purple bubblegum."
icon = 'icons/mob/alien.dmi'
icon_state = "chitin"
/obj/item/organ/brain/New()
/obj/item/organ/internal/brain/New()
..()
health = config.default_brain_health
spawn(5)
if(brainmob && brainmob.client)
brainmob.client.screen.len = null //clear the hud
/obj/item/organ/brain/Destroy()
/obj/item/organ/internal/brain/Destroy()
if(brainmob)
qdel(brainmob)
brainmob = null
..()
/obj/item/organ/brain/proc/transfer_identity(var/mob/living/carbon/H)
name = "\the [H]'s [initial(src.name)]"
brainmob = new(src)
brainmob.name = H.real_name
brainmob.real_name = H.real_name
brainmob.dna = H.dna.Clone()
brainmob.timeofhostdeath = H.timeofdeath
/obj/item/organ/internal/brain/proc/transfer_identity(var/mob/living/carbon/H)
if(!brainmob)
brainmob = new(src)
brainmob.name = H.real_name
brainmob.real_name = H.real_name
brainmob.dna = H.dna.Clone()
brainmob.timeofhostdeath = H.timeofdeath
if(H.mind)
H.mind.transfer_to(brainmob)
brainmob << "<span class='notice'>You feel slightly disoriented. That's normal when you're just a [initial(src.name)].</span>"
brainmob << "<span class='notice'>You feel slightly disoriented. That's normal when you're just \a [initial(src.name)].</span>"
callHook("debrain", list(brainmob))
/obj/item/organ/brain/examine(mob/user) // -- TLE
/obj/item/organ/internal/brain/examine(mob/user) // -- TLE
..(user)
if(brainmob && brainmob.client)//if thar be a brain inside... the brain.
user << "You can feel the small spark of life still left in this one."
else
user << "This one seems particularly lifeless. Perhaps it will regain some of its luster later.."
/obj/item/organ/brain/removed(var/mob/living/user)
/obj/item/organ/internal/brain/removed(var/mob/living/user)
name = "[owner.real_name]'s brain"
if(name == initial(name))
name = "\the [owner.real_name]'s [initial(name)]"
var/mob/living/simple_animal/borer/borer = owner.has_brain_worms()
if(borer)
borer.detatch() //Should remove borer if the brain is removed - RR
var/obj/item/organ/brain/B = src
var/obj/item/organ/internal/brain/B = src
if(istype(B) && istype(owner))
B.transfer_identity(owner)
..()
/obj/item/organ/brain/replaced(var/mob/living/target)
/obj/item/organ/internal/brain/replaced(var/mob/living/target)
if(target.key)
target.ghostize()
@@ -109,13 +106,13 @@
target.key = brainmob.key
..()
/obj/item/organ/brain/slime
/obj/item/organ/internal/brain/slime
name = "slime core"
desc = "A complex, organic knot of jelly and crystalline particles."
icon = 'icons/mob/slimes.dmi'
icon_state = "green slime extract"
/obj/item/organ/brain/golem
/obj/item/organ/internal/brain/golem
name = "chem"
desc = "A tightly furled roll of paper, covered with indecipherable runes."
icon = 'icons/obj/wizard.dmi'
@@ -9,6 +9,6 @@
if(istype(container, /obj/item/device/mmi))
qdel(container)//Gets rid of the MMI if there is one
if(loc)
if(istype(loc,/obj/item/organ/brain))
if(istype(loc,/obj/item/organ/internal/brain))
qdel(loc)//Gets rid of the brain item
..(null,1)
+1 -1
View File
@@ -7,7 +7,7 @@
/mob/living/carbon/proc/breathe()
//if(istype(loc, /obj/machinery/atmospherics/unary/cryo_cell)) return
if(!should_have_organ("lungs") || does_not_breathe) return
if(!should_have_organ(O_LUNGS) || does_not_breathe) return
var/datum/gas_mixture/breath = null
+1 -1
View File
@@ -56,7 +56,7 @@
var/d = rand(round(I.force / 4), I.force)
if(istype(src, /mob/living/carbon/human))
var/mob/living/carbon/human/H = src
var/obj/item/organ/external/organ = H.get_organ("chest")
var/obj/item/organ/external/organ = H.get_organ(BP_TORSO)
if (istype(organ))
if(organ.take_damage(d, 0))
H.UpdateDamageIcon()
@@ -159,7 +159,7 @@
/mob/living/carbon/human/proc/generate_valid_hairstyles(var/check_gender = 1)
var/use_species = species.get_bodytype()
var/obj/item/organ/external/head/H = get_organ("head")
var/obj/item/organ/external/head/H = get_organ(BP_HEAD)
if(H) use_species = H.species.get_bodytype()
var/list/valid_hairstyles = new()
@@ -181,7 +181,7 @@
/mob/living/carbon/human/proc/generate_valid_facial_hairstyles()
var/use_species = species.get_bodytype()
var/obj/item/organ/external/head/H = get_organ("head")
var/obj/item/organ/external/head/H = get_organ(BP_HEAD)
if(H) use_species = H.species.get_bodytype()
var/list/valid_facial_hairstyles = new()
@@ -38,7 +38,7 @@
animate_tail_stop()
//Handle brain slugs.
var/obj/item/organ/external/head = get_organ("head")
var/obj/item/organ/external/head = get_organ(BP_HEAD)
var/mob/living/simple_animal/borer/B
for(var/I in head.implants)
@@ -19,11 +19,43 @@
if(src.stat == 2.0 && (act != "deathgasp"))
return
switch(act)
if ("airguitar")
if (!src.restrained())
message = "is strumming the air and headbanging like a safari chimp."
m_type = 1
if("ping", "beep", "buzz")
if(!isSynthetic())
src << "<span class='warning'>You are not a synthetic.</span>"
return
var/M = null
if(param)
for (var/mob/A in view(null, null))
if (param == A.name)
M = A
break
if(!M)
param = null
var/display_msg = "beeps"
var/use_sound = 'sound/machines/twobeep.ogg'
if(act == "buzz")
display_msg = "buzzes"
use_sound = 'sound/machines/buzz-sigh.ogg'
else if(act == "ping")
display_msg = "pings"
use_sound = 'sound/machines/ping.ogg'
if (param)
message = "[display_msg] at [param]."
else
message = "[display_msg]."
playsound(src.loc, use_sound, 50, 0)
m_type = 1
if ("blink")
message = "blinks."
m_type = 1
+25 -98
View File
@@ -39,19 +39,19 @@
msg += "<EM>[src.name]</EM>"
var/is_synth = isSynthetic()
if(is_synth)
var/use_gender = "a synthetic"
if(gender == MALE)
use_gender = "an android"
else if(gender == FEMALE)
use_gender = "a gynoid"
if(!(skipjumpsuit && skipface))
if(is_synth)
var/use_gender = "a synthetic"
if(gender == MALE)
use_gender = "an android"
else if(gender == FEMALE)
use_gender = "a gynoid"
msg += ", <font color='#555555'>[use_gender]!</font></b>"
msg += ", <font color='#555555'>[use_gender]!</font></b>"
else if(species.name != "Human")
msg += ", <b><font color='[species.get_flesh_colour(src)]'>\a [species.name]!</font></b>"
else if(species.name != "Human")
msg += ", <b><font color='[species.get_flesh_colour(src)]'>\a [species.name]!</font></b>"
msg += "<br>"
//uniform
@@ -64,60 +64,60 @@
tie_msg += ". Attached to it is [lowertext(english_list(U.accessories))]"
if(w_uniform.blood_DNA)
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[w_uniform] [w_uniform.gender==PLURAL?"some":"a"] [(w_uniform.blood_color != "#030303") ? "blood" : "oil"]-stained [w_uniform.name][tie_msg]!</span>\n"
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[w_uniform] [w_uniform.gender==PLURAL?"some":"a"] [(w_uniform.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [w_uniform.name][tie_msg]!</span>\n"
else
msg += "[T.He] [T.is] wearing \icon[w_uniform] \a [w_uniform][tie_msg].\n"
//head
if(head)
if(head.blood_DNA)
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[head] [head.gender==PLURAL?"some":"a"] [(head.blood_color != "#030303") ? "blood" : "oil"]-stained [head.name] on [T.his] head!</span>\n"
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[head] [head.gender==PLURAL?"some":"a"] [(head.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [head.name] on [T.his] head!</span>\n"
else
msg += "[T.He] [T.is] wearing \icon[head] \a [head] on [T.his] head.\n"
//suit/armour
if(wear_suit)
if(wear_suit.blood_DNA)
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[wear_suit] [wear_suit.gender==PLURAL?"some":"a"] [(wear_suit.blood_color != "#030303") ? "blood" : "oil"]-stained [wear_suit.name]!</span>\n"
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[wear_suit] [wear_suit.gender==PLURAL?"some":"a"] [(wear_suit.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [wear_suit.name]!</span>\n"
else
msg += "[T.He] [T.is] wearing \icon[wear_suit] \a [wear_suit].\n"
//suit/armour storage
if(s_store && !skipsuitstorage)
if(s_store.blood_DNA)
msg += "<span class='warning'>[T.He] [T.is] carrying \icon[s_store] [s_store.gender==PLURAL?"some":"a"] [(s_store.blood_color != "#030303") ? "blood" : "oil"]-stained [s_store.name] on [T.his] [wear_suit.name]!</span>\n"
msg += "<span class='warning'>[T.He] [T.is] carrying \icon[s_store] [s_store.gender==PLURAL?"some":"a"] [(s_store.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [s_store.name] on [T.his] [wear_suit.name]!</span>\n"
else
msg += "[T.He] [T.is] carrying \icon[s_store] \a [s_store] on [T.his] [wear_suit.name].\n"
//back
if(back)
if(back.blood_DNA)
msg += "<span class='warning'>[T.He] [T.has] \icon[back] [back.gender==PLURAL?"some":"a"] [(back.blood_color != "#030303") ? "blood" : "oil"]-stained [back] on [T.his] back.</span>\n"
msg += "<span class='warning'>[T.He] [T.has] \icon[back] [back.gender==PLURAL?"some":"a"] [(back.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [back] on [T.his] back.</span>\n"
else
msg += "[T.He] [T.has] \icon[back] \a [back] on [T.his] back.\n"
//left hand
if(l_hand)
if(l_hand.blood_DNA)
msg += "<span class='warning'>[T.He] [T.is] holding \icon[l_hand] [l_hand.gender==PLURAL?"some":"a"] [(l_hand.blood_color != "#030303") ? "blood" : "oil"]-stained [l_hand.name] in [T.his] left hand!</span>\n"
msg += "<span class='warning'>[T.He] [T.is] holding \icon[l_hand] [l_hand.gender==PLURAL?"some":"a"] [(l_hand.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [l_hand.name] in [T.his] left hand!</span>\n"
else
msg += "[T.He] [T.is] holding \icon[l_hand] \a [l_hand] in [T.his] left hand.\n"
//right hand
if(r_hand)
if(r_hand.blood_DNA)
msg += "<span class='warning'>[T.He] [T.is] holding \icon[r_hand] [r_hand.gender==PLURAL?"some":"a"] [(r_hand.blood_color != "#030303") ? "blood" : "oil"]-stained [r_hand.name] in [T.his] right hand!</span>\n"
msg += "<span class='warning'>[T.He] [T.is] holding \icon[r_hand] [r_hand.gender==PLURAL?"some":"a"] [(r_hand.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [r_hand.name] in [T.his] right hand!</span>\n"
else
msg += "[T.He] [T.is] holding \icon[r_hand] \a [r_hand] in [T.his] right hand.\n"
//gloves
if(gloves && !skipgloves)
if(gloves.blood_DNA)
msg += "<span class='warning'>[T.He] [T.has] \icon[gloves] [gloves.gender==PLURAL?"some":"a"] [(gloves.blood_color != "#030303") ? "blood" : "oil"]-stained [gloves.name] on [T.his] hands!</span>\n"
msg += "<span class='warning'>[T.He] [T.has] \icon[gloves] [gloves.gender==PLURAL?"some":"a"] [(gloves.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [gloves.name] on [T.his] hands!</span>\n"
else
msg += "[T.He] [T.has] \icon[gloves] \a [gloves] on [T.his] hands.\n"
else if(blood_DNA)
msg += "<span class='warning'>[T.He] [T.has] [(hand_blood_color != "#030303") ? "blood" : "oil"]-stained hands!</span>\n"
msg += "<span class='warning'>[T.He] [T.has] [(hand_blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained hands!</span>\n"
//handcuffed?
@@ -135,30 +135,30 @@
//belt
if(belt)
if(belt.blood_DNA)
msg += "<span class='warning'>[T.He] [T.has] \icon[belt] [belt.gender==PLURAL?"some":"a"] [(belt.blood_color != "#030303") ? "blood" : "oil"]-stained [belt.name] about [T.his] waist!</span>\n"
msg += "<span class='warning'>[T.He] [T.has] \icon[belt] [belt.gender==PLURAL?"some":"a"] [(belt.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [belt.name] about [T.his] waist!</span>\n"
else
msg += "[T.He] [T.has] \icon[belt] \a [belt] about [T.his] waist.\n"
//shoes
if(shoes && !skipshoes)
if(shoes.blood_DNA)
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[shoes] [shoes.gender==PLURAL?"some":"a"] [(shoes.blood_color != "#030303") ? "blood" : "oil"]-stained [shoes.name] on [T.his] feet!</span>\n"
msg += "<span class='warning'>[T.He] [T.is] wearing \icon[shoes] [shoes.gender==PLURAL?"some":"a"] [(shoes.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [shoes.name] on [T.his] feet!</span>\n"
else
msg += "[T.He] [T.is] wearing \icon[shoes] \a [shoes] on [T.his] feet.\n"
else if(feet_blood_DNA)
msg += "<span class='warning'>[T.He] [T.has] [(feet_blood_color != "#030303") ? "blood" : "oil"]-stained feet!</span>\n"
msg += "<span class='warning'>[T.He] [T.has] [(feet_blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained feet!</span>\n"
//mask
if(wear_mask && !skipmask)
if(wear_mask.blood_DNA)
msg += "<span class='warning'>[T.He] [T.has] \icon[wear_mask] [wear_mask.gender==PLURAL?"some":"a"] [(wear_mask.blood_color != "#030303") ? "blood" : "oil"]-stained [wear_mask.name] on [T.his] face!</span>\n"
msg += "<span class='warning'>[T.He] [T.has] \icon[wear_mask] [wear_mask.gender==PLURAL?"some":"a"] [(wear_mask.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [wear_mask.name] on [T.his] face!</span>\n"
else
msg += "[T.He] [T.has] \icon[wear_mask] \a [wear_mask] on [T.his] face.\n"
//eyes
if(glasses && !skipeyes)
if(glasses.blood_DNA)
msg += "<span class='warning'>[T.He] [T.has] \icon[glasses] [glasses.gender==PLURAL?"some":"a"] [(glasses.blood_color != "#030303") ? "blood" : "oil"]-stained [glasses] covering [T.his] eyes!</span>\n"
msg += "<span class='warning'>[T.He] [T.has] \icon[glasses] [glasses.gender==PLURAL?"some":"a"] [(glasses.blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained [glasses] covering [T.his] eyes!</span>\n"
else
msg += "[T.He] [T.has] \icon[glasses] \a [glasses] covering [T.his] eyes.\n"
@@ -194,7 +194,7 @@
msg += "<span class='warning'>[T.He] [T.is] twitching ever so slightly.</span>\n"
//splints
for(var/organ in list("l_leg","r_leg","l_arm","r_arm"))
for(var/organ in list(BP_L_LEG, BP_R_LEG, BP_L_ARM, BP_R_ARM))
var/obj/item/organ/external/o = get_organ(organ)
if(o && o.status & ORGAN_SPLINTED)
msg += "<span class='warning'>[T.He] [T.has] a splint on [T.his] [o.name]!</span>\n"
@@ -295,79 +295,6 @@
if(((temp.status & ORGAN_BROKEN) && temp.brute_dam > temp.min_broken_damage) || (temp.status & ORGAN_MUTATED))
wound_flavor_text["[temp.name]"] += "<span class='warning'>[T.His] [temp.name] is dented and swollen!</span><br>"
//Handles the text strings being added to the actual description.
//If they have something that covers the limb, and it is not missing, put flavortext. If it is covered but bleeding, add other flavortext.
// ***********************************************************************************
// THIS NEEDS TO BE ENTIRELY REWRITTEN. Commenting out for now, BADLY NEEDS REWRITING.
// ***********************************************************************************
/*
var/display_chest = 0
var/display_shoes = 0
var/display_gloves = 0
if(wound_flavor_text["head"] && (is_destroyed["head"] || (!skipmask && !(wear_mask && istype(wear_mask, /obj/item/clothing/mask/gas)))))
msg += wound_flavor_text["head"]
else if(is_bleeding["head"])
msg += "<span class='warning'>[src] [T.has] blood running down [T.his] face!</span>\n"
if(wound_flavor_text["upper body"] && !w_uniform && !skipjumpsuit) //No need. A missing chest gibs you.
msg += wound_flavor_text["upper body"]
else if(is_bleeding["upper body"])
display_chest = 1
if(wound_flavor_text["left arm"] && (is_destroyed["left arm"] || (!w_uniform && !skipjumpsuit)))
msg += wound_flavor_text["left arm"]
else if(is_bleeding["left arm"])
display_chest = 1
if(wound_flavor_text["left hand"] && (is_destroyed["left hand"] || (!gloves && !skipgloves)))
msg += wound_flavor_text["left hand"]
else if(is_bleeding["left hand"])
display_gloves = 1
if(wound_flavor_text["right arm"] && (is_destroyed["right arm"] || (!w_uniform && !skipjumpsuit)))
msg += wound_flavor_text["right arm"]
else if(is_bleeding["right arm"])
display_chest = 1
if(wound_flavor_text["right hand"] && (is_destroyed["right hand"] || (!gloves && !skipgloves)))
msg += wound_flavor_text["right hand"]
else if(is_bleeding["right hand"])
display_gloves = 1
if(wound_flavor_text["lower body"] && (is_destroyed["lower body"] || (!w_uniform && !skipjumpsuit)))
msg += wound_flavor_text["lower body"]
else if(is_bleeding["lower body"])
display_chest = 1
if(wound_flavor_text["left leg"] && (is_destroyed["left leg"] || (!w_uniform && !skipjumpsuit)))
msg += wound_flavor_text["left leg"]
else if(is_bleeding["left leg"])
display_chest = 1
if(wound_flavor_text["left foot"]&& (is_destroyed["left foot"] || (!shoes && !skipshoes)))
msg += wound_flavor_text["left foot"]
else if(is_bleeding["left foot"])
display_shoes = 1
if(wound_flavor_text["right leg"] && (is_destroyed["right leg"] || (!w_uniform && !skipjumpsuit)))
msg += wound_flavor_text["right leg"]
else if(is_bleeding["right leg"])
display_chest = 1
if(wound_flavor_text["right foot"]&& (is_destroyed["right foot"] || (!shoes && !skipshoes)))
msg += wound_flavor_text["right foot"]
else if(is_bleeding["right foot"])
display_shoes = 1
if(display_chest)
msg += "<span class='danger'>[src] [T.has] blood soaking through from under [T.his] clothing!</span>\n"
if(display_shoes)
msg += "<span class='danger'>[src] [T.has] blood running from [T.his] shoes!</span>\n"
if(display_gloves)
msg += "<span class='danger'>[src] [T.has] blood running from under [T.his] gloves!</span>\n"
*/
for(var/limb in wound_flavor_text)
msg += wound_flavor_text[limb]
is_bleeding[limb] = null
+28 -40
View File
@@ -71,7 +71,7 @@
stat("Tank Pressure", internal.air_contents.return_pressure())
stat("Distribution Pressure", internal.distribute_pressure)
var/obj/item/organ/xenos/plasmavessel/P = internal_organs_by_name["plasma vessel"]
var/obj/item/organ/internal/xenos/plasmavessel/P = internal_organs_by_name[O_PLASMA]
if(P)
stat(null, "Phoron Stored: [P.stored_plasma]/[P.max_plasma]")
@@ -145,26 +145,12 @@
var/weapon_message = "Explosive Blast"
for(var/obj/item/organ/external/temp in organs)
switch(temp.name)
if("head")
switch(temp.organ_tag)
if(BP_HEAD)
update |= temp.take_damage(b_loss * 0.2, f_loss * 0.2, used_weapon = weapon_message)
if("chest")
if(BP_TORSO)
update |= temp.take_damage(b_loss * 0.4, f_loss * 0.4, used_weapon = weapon_message)
if("l_arm")
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if("r_arm")
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if("l_leg")
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if("r_leg")
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if("r_foot")
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if("l_foot")
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if("r_arm")
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if("l_arm")
else
update |= temp.take_damage(b_loss * 0.05, f_loss * 0.05, used_weapon = weapon_message)
if(update) UpdateDamageIcon()
@@ -174,7 +160,7 @@
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(M)
L.imp_in = M
L.implanted = 1
var/obj/item/organ/external/affected = M.organs_by_name["head"]
var/obj/item/organ/external/affected = M.organs_by_name[BP_HEAD]
affected.implants += L
L.part = affected
L.implanted(src)
@@ -318,7 +304,7 @@
//Returns "Unknown" if facially disfigured and real_name if not. Useful for setting name when polyacided or when updating a human's name variable
/mob/living/carbon/human/proc/get_face_name()
var/obj/item/organ/external/head = get_organ("head")
var/obj/item/organ/external/head = get_organ(BP_HEAD)
if(!head || head.disfigured || (head.status & ORGAN_DESTROYED) || !real_name || (HUSK in mutations) ) //disfigured. use id-name if possible
return "Unknown"
return real_name
@@ -655,7 +641,7 @@
///Returns a number between -1 to 2
/mob/living/carbon/human/eyecheck()
var/obj/item/organ/I = internal_organs_by_name["eyes"]
var/obj/item/organ/I = internal_organs_by_name[O_EYES]
if(!I || I.status & (ORGAN_CUT_AWAY|ORGAN_DESTROYED))
return 2
@@ -742,7 +728,7 @@
/mob/living/carbon/human/check_has_mouth()
// Todo, check stomach organ when implemented.
var/obj/item/organ/external/head/H = get_organ("head")
var/obj/item/organ/external/head/H = get_organ(BP_HEAD)
if(!H || !H.can_intake_reagents)
return 0
return 1
@@ -908,7 +894,7 @@
/mob/living/carbon/human/revive()
if(should_have_organ("heart"))
if(should_have_organ(O_HEART))
vessel.add_reagent("blood",560-vessel.total_volume)
fixblood()
@@ -916,7 +902,7 @@
restore_all_organs() // Reapply robotics/amputated status from preferences.
if(!client || !key) //Don't boot out anyone already in the mob.
for (var/obj/item/organ/brain/H in world)
for (var/obj/item/organ/internal/brain/H in world)
if(H.brainmob)
if(H.brainmob.real_name == src.real_name)
if(H.brainmob.mind)
@@ -935,11 +921,11 @@
..()
/mob/living/carbon/human/proc/is_lung_ruptured()
var/obj/item/organ/lungs/L = internal_organs_by_name["lungs"]
var/obj/item/organ/internal/lungs/L = internal_organs_by_name[O_LUNGS]
return L && L.is_bruised()
/mob/living/carbon/human/proc/rupture_lung()
var/obj/item/organ/lungs/L = internal_organs_by_name["lungs"]
var/obj/item/organ/internal/lungs/L = internal_organs_by_name[O_LUNGS]
if(L && !L.is_bruised())
src.custom_pain("You feel a stabbing pain in your chest!", 1)
@@ -1028,7 +1014,7 @@
for(var/obj/item/O in organ.implants)
if(!istype(O,/obj/item/weapon/implant) && prob(5)) //Moving with things stuck in you could be bad.
// All kinds of embedded objects cause bleeding.
if(!can_feel_pain(organ.limb_name))
if(!can_feel_pain(organ.organ_tag))
src << "<span class='warning'>You feel [O] moving inside your [organ.name].</span>"
else
var/msg = pick( \
@@ -1038,7 +1024,7 @@
src << msg
organ.take_damage(rand(1,3), 0, 0)
if(!(organ.status & ORGAN_ROBOT) && !should_have_organ("heart")) //There is no blood in protheses.
if(!(organ.status & ORGAN_ROBOT) && !should_have_organ(O_HEART)) //There is no blood in protheses.
organ.status |= ORGAN_BLEEDING
src.adjustToxLoss(rand(1,3))
@@ -1140,6 +1126,8 @@
qdel(hud_used)
hud_used = new /datum/hud(src)
full_prosthetic = null
if(species)
return 1
else
@@ -1205,7 +1193,7 @@
if(!target_zone)
if(!user)
target_zone = pick("chest","chest","chest","left leg","right leg","left arm", "right arm", "head")
target_zone = pick(BP_TORSO,BP_TORSO,BP_TORSO,BP_L_LEG,BP_R_LEG,BP_L_ARM,BP_R_ARM,BP_HEAD)
else
target_zone = user.zone_sel.selecting
@@ -1219,7 +1207,7 @@
fail_msg = "That limb is robotic."
else
switch(target_zone)
if("head")
if(BP_HEAD)
if(head && head.item_flags & THICKMATERIAL)
. = 0
else
@@ -1227,7 +1215,7 @@
. = 0
if(!. && error_msg && user)
if(!fail_msg)
fail_msg = "There is no exposed flesh or thin material [target_zone == "head" ? "on their head" : "on their body"] to inject into."
fail_msg = "There is no exposed flesh or thin material [target_zone == BP_HEAD ? "on their head" : "on their body"] to inject into."
user << "<span class='alert'>[fail_msg]</span>"
/mob/living/carbon/human/print_flavor_text(var/shrink = 1)
@@ -1285,15 +1273,15 @@
..()
/mob/living/carbon/human/has_brain()
if(internal_organs_by_name["brain"])
var/obj/item/organ/brain = internal_organs_by_name["brain"]
if(internal_organs_by_name[O_BRAIN])
var/obj/item/organ/brain = internal_organs_by_name[O_BRAIN]
if(brain && istype(brain))
return 1
return 0
/mob/living/carbon/human/has_eyes()
if(internal_organs_by_name["eyes"])
var/obj/item/organ/eyes = internal_organs_by_name["eyes"]
if(internal_organs_by_name[O_EYES])
var/obj/item/organ/eyes = internal_organs_by_name[O_EYES]
if(eyes && istype(eyes) && !(eyes.status & ORGAN_CUT_AWAY))
return 1
return 0
@@ -1402,10 +1390,10 @@
/mob/living/carbon/human/should_have_organ(var/organ_check)
var/obj/item/organ/external/affecting
if(organ_check in list("heart","lungs"))
affecting = organs_by_name["chest"]
else if(organ_check in list("liver","kidneys"))
affecting = organs_by_name["groin"]
if(organ_check in list(O_HEART, O_LUNGS))
affecting = organs_by_name[BP_TORSO]
else if(organ_check in list(O_LIVER, O_KIDNEYS))
affecting = organs_by_name[BP_GROIN]
if(affecting && (affecting.status & ORGAN_ROBOT))
return 0
@@ -180,7 +180,7 @@
*/
if(prob(80))
hit_zone = ran_zone(hit_zone)
if(prob(15) && hit_zone != "chest") // Missed!
if(prob(15) && hit_zone != BP_TORSO) // Missed!
if(!src.lying)
attack_message = "[H] attempted to strike [src], but missed!"
else
@@ -29,7 +29,7 @@
if(status_flags & GODMODE) return 0 //godmode
if(should_have_organ("brain"))
var/obj/item/organ/brain/sponge = internal_organs_by_name["brain"]
var/obj/item/organ/internal/brain/sponge = internal_organs_by_name["brain"]
if(sponge)
sponge.take_damage(amount)
brainloss = sponge.damage
@@ -43,7 +43,7 @@
if(status_flags & GODMODE) return 0 //godmode
if(should_have_organ("brain"))
var/obj/item/organ/brain/sponge = internal_organs_by_name["brain"]
var/obj/item/organ/internal/brain/sponge = internal_organs_by_name["brain"]
if(sponge)
sponge.damage = min(max(amount, 0),(maxHealth*2))
brainloss = sponge.damage
@@ -57,7 +57,7 @@
if(status_flags & GODMODE) return 0 //godmode
if(should_have_organ("brain"))
var/obj/item/organ/brain/sponge = internal_organs_by_name["brain"]
var/obj/item/organ/internal/brain/sponge = internal_organs_by_name["brain"]
if(sponge)
brainloss = min(sponge.damage,maxHealth*2)
else
@@ -189,19 +189,19 @@
// Defined here solely to take species flags into account without having to recast at mob/living level.
/mob/living/carbon/human/getOxyLoss()
if(!should_have_organ("lungs"))
if(!should_have_organ(O_LUNGS))
oxyloss = 0
return ..()
/mob/living/carbon/human/adjustOxyLoss(var/amount)
if(!should_have_organ("lungs"))
if(!should_have_organ(O_LUNGS))
oxyloss = 0
else
amount = amount*species.oxy_mod
..(amount)
/mob/living/carbon/human/setOxyLoss(var/amount)
if(!should_have_organ("lungs"))
if(!should_have_organ(O_LUNGS))
oxyloss = 0
else
..()
@@ -321,7 +321,7 @@ In most cases it makes more sense to use apply_damage() instead! And make sure t
This function restores the subjects blood to max.
*/
/mob/living/carbon/human/proc/restore_blood()
if(should_have_organ("heart"))
if(should_have_organ(O_HEART))
var/blood_volume = vessel.get_reagent_amount("blood")
vessel.add_reagent("blood",560.0-blood_volume)
@@ -345,9 +345,10 @@ This function restores all organs.
/mob/living/carbon/human/proc/get_organ(var/zone)
if(!zone) zone = "chest"
if (zone in list( "eyes", "mouth" ))
zone = "head"
if(!zone)
zone = BP_TORSO
else if (zone in list( O_EYES, O_MOUTH ))
zone = BP_HEAD
return organs_by_name[zone]
/mob/living/carbon/human/apply_damage(var/damage = 0, var/damagetype = BRUTE, var/def_zone = null, var/blocked = 0, var/sharp = 0, var/edge = 0, var/obj/used_weapon = null)
@@ -44,11 +44,11 @@ emp_act
agony_amount *= siemens_coeff
switch (def_zone)
if("head")
if(BP_HEAD)
agony_amount *= 1.50
if("l_hand", "r_hand")
if(BP_L_HAND, BP_R_HAND)
var/c_hand
if (def_zone == "l_hand")
if (def_zone == BP_L_HAND)
c_hand = l_hand
else
c_hand = r_hand
@@ -233,7 +233,7 @@ emp_act
//Apply blood
if(bloody)
switch(hit_area)
if("head")
if(BP_HEAD)
if(wear_mask)
wear_mask.add_blood(src)
update_inv_wear_mask(0)
@@ -243,7 +243,7 @@ emp_act
if(glasses && prob(33))
glasses.add_blood(src)
update_inv_glasses(0)
if("chest")
if(BP_TORSO)
bloody_body(src)
if(Iforce > 10 || Iforce >= 5 && prob(33))
@@ -285,7 +285,7 @@ emp_act
var/mob/living/L = O.thrower
zone = check_zone(L.zone_sel.selecting)
else
zone = ran_zone("chest",75) //Hits a random part of the body, geared towards the chest
zone = ran_zone(BP_TORSO,75) //Hits a random part of the body, geared towards the chest
//check if we hit
var/miss_chance = 15
@@ -82,8 +82,9 @@
var/list/flavor_texts = list()
var/gunshot_residue
var/pulling_punches // Are you trying not to hurt your opponent?
var/full_prosthetic // We are a robutt.
var/pulling_punches // Are you trying not to hurt your opponent?
var/full_prosthetic // We are a robutt.
var/robolimb_count = 0 // Number of robot limbs.
mob_bump_flag = HUMAN
mob_push_flags = ~HEAVY
@@ -26,7 +26,7 @@
tally += wear_suit.slowdown
if(istype(buckled, /obj/structure/bed/chair/wheelchair))
for(var/organ_name in list("l_hand","r_hand","l_arm","r_arm"))
for(var/organ_name in list(BP_L_HAND, BP_R_HAND, BP_L_ARM, BP_R_ARM))
var/obj/item/organ/external/E = get_organ(organ_name)
if(!E || (E.status & ORGAN_DESTROYED))
tally += 4
@@ -38,7 +38,7 @@
if(shoes)
tally += shoes.slowdown
for(var/organ_name in list("l_foot","r_foot","l_leg","r_leg"))
for(var/organ_name in list(BP_L_LEG, BP_R_LEG, BP_L_FOOT, BP_R_FOOT))
var/obj/item/organ/external/E = get_organ(organ_name)
if(!E || (E.status & ORGAN_DESTROYED))
tally += 4
@@ -1,5 +1,5 @@
/mob/living/carbon/human/proc/update_eyes()
var/obj/item/organ/eyes/eyes = internal_organs_by_name["eyes"]
var/obj/item/organ/internal/eyes/eyes = internal_organs_by_name[O_EYES]
if(eyes)
eyes.update_colour()
regenerate_icons()
@@ -113,7 +113,7 @@
// You should not be able to pick anything up, but stranger things have happened.
if(l_hand)
for(var/limb_tag in list("l_hand","l_arm"))
for(var/limb_tag in list(BP_L_HAND, BP_L_ARM))
var/obj/item/organ/external/E = get_organ(limb_tag)
if(!E)
visible_message("<span class='danger'>Lacking a functioning left hand, \the [src] drops \the [l_hand].</span>")
@@ -121,7 +121,7 @@
break
if(r_hand)
for(var/limb_tag in list("r_hand","r_arm"))
for(var/limb_tag in list(BP_R_HAND, BP_R_ARM))
var/obj/item/organ/external/E = get_organ(limb_tag)
if(!E)
visible_message("<span class='danger'>Lacking a functioning right hand, \the [src] drops \the [r_hand].</span>")
@@ -45,44 +45,44 @@ This saves us from having to call add_fingerprint() any time something is put in
/mob/living/carbon/human/proc/has_organ_for_slot(slot)
switch(slot)
if(slot_back)
return has_organ("chest")
return has_organ(BP_TORSO)
if(slot_wear_mask)
return has_organ("head")
return has_organ(BP_HEAD)
if(slot_handcuffed)
return has_organ("l_hand") && has_organ("r_hand")
return has_organ(BP_L_HAND) && has_organ(BP_R_HAND)
if(slot_legcuffed)
return has_organ("l_leg") && has_organ("r_leg")
return has_organ(BP_L_FOOT) && has_organ(BP_R_FOOT)
if(slot_l_hand)
return has_organ("l_hand")
return has_organ(BP_L_HAND)
if(slot_r_hand)
return has_organ("r_hand")
return has_organ(BP_R_HAND)
if(slot_belt)
return has_organ("chest")
return has_organ(BP_TORSO)
if(slot_wear_id)
// the only relevant check for this is the uniform check
return 1
if(slot_l_ear)
return has_organ("head")
return has_organ(BP_HEAD)
if(slot_r_ear)
return has_organ("head")
return has_organ(BP_HEAD)
if(slot_glasses)
return has_organ("head")
return has_organ(BP_HEAD)
if(slot_gloves)
return has_organ("l_hand") || has_organ("r_hand")
return has_organ(BP_L_HAND) || has_organ(BP_R_HAND)
if(slot_head)
return has_organ("head")
return has_organ(BP_HEAD)
if(slot_shoes)
return has_organ("r_foot") || has_organ("l_foot")
return has_organ(BP_L_FOOT) || has_organ(BP_R_FOOT)
if(slot_wear_suit)
return has_organ("chest")
return has_organ(BP_TORSO)
if(slot_w_uniform)
return has_organ("chest")
return has_organ(BP_TORSO)
if(slot_l_store)
return has_organ("chest")
return has_organ(BP_TORSO)
if(slot_r_store)
return has_organ("chest")
return has_organ(BP_TORSO)
if(slot_s_store)
return has_organ("chest")
return has_organ(BP_TORSO)
if(slot_in_backpack)
return 1
if(slot_tie)
+42 -39
View File
@@ -255,12 +255,7 @@
if (radiation)
// TODO.
if(isSynthetic())
radiation = 0
return
var/obj/item/organ/diona/nutrients/rad_organ = locate() in internal_organs
var/obj/item/organ/internal/diona/nutrients/rad_organ = locate() in internal_organs
if(rad_organ && !rad_organ.is_broken())
var/rads = radiation/25
radiation -= rads
@@ -280,34 +275,36 @@
if (radiation > 50)
damage = 1
radiation -= 1 * RADIATION_SPEED_COEFFICIENT
if(prob(5) && prob(100 * RADIATION_SPEED_COEFFICIENT))
radiation -= 5 * RADIATION_SPEED_COEFFICIENT
src << "<span class='warning'>You feel weak.</span>"
Weaken(3)
if(!lying)
emote("collapse")
if(prob(5) && prob(100 * RADIATION_SPEED_COEFFICIENT) && species.get_bodytype() == "Human") //apes go bald
if((h_style != "Bald" || f_style != "Shaved" ))
src << "<span class='warning'>Your hair falls out.</span>"
h_style = "Bald"
f_style = "Shaved"
update_hair()
if(!isSynthetic())
if(prob(5) && prob(100 * RADIATION_SPEED_COEFFICIENT))
radiation -= 5 * RADIATION_SPEED_COEFFICIENT
src << "<span class='warning'>You feel weak.</span>"
Weaken(3)
if(!lying)
emote("collapse")
if(prob(5) && prob(100 * RADIATION_SPEED_COEFFICIENT) && species.get_bodytype() == "Human") //apes go bald
if((h_style != "Bald" || f_style != "Shaved" ))
src << "<span class='warning'>Your hair falls out.</span>"
h_style = "Bald"
f_style = "Shaved"
update_hair()
if (radiation > 75)
radiation -= 1 * RADIATION_SPEED_COEFFICIENT
damage = 3
if(prob(5))
take_overall_damage(0, 5 * RADIATION_SPEED_COEFFICIENT, used_weapon = "Radiation Burns")
if(prob(1))
src << "<span class='warning'>You feel strange!</span>"
adjustCloneLoss(5 * RADIATION_SPEED_COEFFICIENT)
emote("gasp")
radiation -= 1 * RADIATION_SPEED_COEFFICIENT
if(!isSynthetic())
if(prob(5))
take_overall_damage(0, 5 * RADIATION_SPEED_COEFFICIENT, used_weapon = "Radiation Burns")
if(prob(1))
src << "<span class='warning'>You feel strange!</span>"
adjustCloneLoss(5 * RADIATION_SPEED_COEFFICIENT)
emote("gasp")
if(damage)
damage *= species.radiation_mod
damage *= isSynthetic() ? 0.5 : species.radiation_mod
adjustToxLoss(damage * RADIATION_SPEED_COEFFICIENT)
updatehealth()
if(organs.len)
if(!isSynthetic() && organs.len)
var/obj/item/organ/external/O = pick(organs)
if(istype(O)) O.add_autopsy_data("Radiation Poisoning", damage)
@@ -371,8 +368,8 @@
var/safe_pressure_min = 16 // Minimum safe partial pressure of breathable gas in kPa
// Lung damage increases the minimum safe pressure.
if(should_have_organ("lungs"))
var/obj/item/organ/lungs/L = internal_organs_by_name["lungs"]
if(should_have_organ(O_LUNGS))
var/obj/item/organ/internal/lungs/L = internal_organs_by_name[O_LUNGS]
if(isnull(L))
safe_pressure_min = INFINITY //No lungs, how are you breathing?
else if(L.is_broken())
@@ -525,24 +522,24 @@
if(breath.temperature >= species.heat_level_1)
if(breath.temperature < species.heat_level_2)
apply_damage(HEAT_GAS_DAMAGE_LEVEL_1, BURN, "head", used_weapon = "Excessive Heat")
apply_damage(HEAT_GAS_DAMAGE_LEVEL_1, BURN, BP_HEAD, used_weapon = "Excessive Heat")
fire_alert = max(fire_alert, 2)
else if(breath.temperature < species.heat_level_3)
apply_damage(HEAT_GAS_DAMAGE_LEVEL_2, BURN, "head", used_weapon = "Excessive Heat")
apply_damage(HEAT_GAS_DAMAGE_LEVEL_2, BURN, BP_HEAD, used_weapon = "Excessive Heat")
fire_alert = max(fire_alert, 2)
else
apply_damage(HEAT_GAS_DAMAGE_LEVEL_3, BURN, "head", used_weapon = "Excessive Heat")
apply_damage(HEAT_GAS_DAMAGE_LEVEL_3, BURN, BP_HEAD, used_weapon = "Excessive Heat")
fire_alert = max(fire_alert, 2)
else if(breath.temperature <= species.cold_level_1)
if(breath.temperature > species.cold_level_2)
apply_damage(COLD_GAS_DAMAGE_LEVEL_1, BURN, "head", used_weapon = "Excessive Cold")
apply_damage(COLD_GAS_DAMAGE_LEVEL_1, BURN, BP_HEAD, used_weapon = "Excessive Cold")
fire_alert = max(fire_alert, 1)
else if(breath.temperature > species.cold_level_3)
apply_damage(COLD_GAS_DAMAGE_LEVEL_2, BURN, "head", used_weapon = "Excessive Cold")
apply_damage(COLD_GAS_DAMAGE_LEVEL_2, BURN, BP_HEAD, used_weapon = "Excessive Cold")
fire_alert = max(fire_alert, 1)
else
apply_damage(COLD_GAS_DAMAGE_LEVEL_3, BURN, "head", used_weapon = "Excessive Cold")
apply_damage(COLD_GAS_DAMAGE_LEVEL_3, BURN, BP_HEAD, used_weapon = "Excessive Cold")
fire_alert = max(fire_alert, 1)
@@ -691,13 +688,19 @@
*/
/mob/living/carbon/human/proc/stabilize_body_temperature()
if (species.passive_temp_gain) // We produce heat naturally.
// We produce heat naturally.
if (species.passive_temp_gain)
bodytemperature += species.passive_temp_gain
// Robolimbs cause overheating too.
if(robolimb_count)
bodytemperature += round(robolimb_count/2)
var/body_temperature_difference = species.body_temperature - bodytemperature
if (abs(body_temperature_difference) < 0.5)
return //fuck this precision
if (on_fire)
return //too busy for pesky convection
@@ -862,7 +865,7 @@
if(status_flags & GODMODE) return 0 //godmode
var/obj/item/organ/diona/node/light_organ = locate() in internal_organs
var/obj/item/organ/internal/diona/node/light_organ = locate() in internal_organs
if(!isSynthetic())
if(light_organ && !light_organ.is_broken())
@@ -1548,7 +1551,7 @@
/mob/living/carbon/human/proc/handle_pulse()
if(life_tick % 5) return pulse //update pulse every 5 life ticks (~1 tick/sec, depending on server load)
if(!internal_organs_by_name["heart"])
if(!internal_organs_by_name[O_HEART])
return PULSE_NONE //No blood, no pulse.
if(stat == DEAD)
@@ -1582,7 +1585,7 @@
if(pulse == PULSE_NONE)
return
var/obj/item/organ/heart/H = internal_organs_by_name["heart"]
var/obj/item/organ/internal/heart/H = internal_organs_by_name[O_HEART]
if(!H || (H.status & ORGAN_ROBOT))
return
@@ -45,28 +45,28 @@
)
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest),
"groin" = list("path" = /obj/item/organ/external/groin),
"head" = list("path" = /obj/item/organ/external/head/vox),
"l_arm" = list("path" = /obj/item/organ/external/arm),
"r_arm" = list("path" = /obj/item/organ/external/arm/right),
"l_leg" = list("path" = /obj/item/organ/external/leg),
"r_leg" = list("path" = /obj/item/organ/external/leg/right),
"l_hand" = list("path" = /obj/item/organ/external/hand),
"r_hand" = list("path" = /obj/item/organ/external/hand/right),
"l_foot" = list("path" = /obj/item/organ/external/foot),
"r_foot" = list("path" = /obj/item/organ/external/foot/right)
BP_TORSO = list("path" = /obj/item/organ/external/chest),
BP_GROIN = list("path" = /obj/item/organ/external/groin),
BP_HEAD = list("path" = /obj/item/organ/external/head/vox),
BP_L_ARM = list("path" = /obj/item/organ/external/arm),
BP_R_ARM = list("path" = /obj/item/organ/external/arm/right),
BP_L_LEG = list("path" = /obj/item/organ/external/leg),
BP_R_LEG = list("path" = /obj/item/organ/external/leg/right),
BP_L_HAND = list("path" = /obj/item/organ/external/hand),
BP_R_HAND = list("path" = /obj/item/organ/external/hand/right),
BP_L_FOOT = list("path" = /obj/item/organ/external/foot),
BP_R_FOOT = list("path" = /obj/item/organ/external/foot/right)
)
has_organ = list(
"heart" = /obj/item/organ/heart,
"lungs" = /obj/item/organ/lungs,
"liver" = /obj/item/organ/liver,
"kidneys" = /obj/item/organ/kidneys,
"brain" = /obj/item/organ/brain,
"eyes" = /obj/item/organ/eyes,
"stack" = /obj/item/organ/stack/vox
O_HEART = /obj/item/organ/internal/heart,
O_LUNGS = /obj/item/organ/internal/lungs,
O_LIVER = /obj/item/organ/internal/liver,
O_KIDNEYS = /obj/item/organ/internal/kidneys,
O_BRAIN = /obj/item/organ/internal/brain,
O_EYES = /obj/item/organ/internal/eyes,
"stack" = /obj/item/organ/internal/stack/vox
)
/datum/species/vox/get_random_name(var/gender)
@@ -108,12 +108,12 @@
// Pariahs have no stack.
has_organ = list(
"heart" = /obj/item/organ/heart,
"lungs" = /obj/item/organ/lungs,
"liver" = /obj/item/organ/liver,
"kidneys" = /obj/item/organ/kidneys,
"brain" = /obj/item/organ/pariah_brain,
"eyes" = /obj/item/organ/eyes
O_HEART = /obj/item/organ/internal/heart,
O_LUNGS = /obj/item/organ/internal/lungs,
O_LIVER = /obj/item/organ/internal/liver,
O_KIDNEYS = /obj/item/organ/internal/kidneys,
O_BRAIN = /obj/item/organ/internal/pariah_brain,
O_EYES = /obj/item/organ/internal/eyes
)
flags = IS_RESTRICTED | NO_SCAN | HAS_EYE_COLOR
@@ -58,8 +58,6 @@
// Death vars.
var/meat_type = /obj/item/weapon/reagent_containers/food/snacks/meat/human
var/gibber_type = /obj/effect/gibspawner/human
var/single_gib_type = /obj/effect/decal/cleanable/blood/gibs
var/remains_type = /obj/effect/decal/remains/xeno
var/gibbed_anim = "gibbed-h"
var/dusted_anim = "dust-h"
@@ -120,28 +118,28 @@
var/rarity_value = 1 // Relative rarity/collector value for this species.
// Determines the organs that the species spawns with and
var/list/has_organ = list( // which required-organ checks are conducted.
"heart" = /obj/item/organ/heart,
"lungs" = /obj/item/organ/lungs,
"liver" = /obj/item/organ/liver,
"kidneys" = /obj/item/organ/kidneys,
"brain" = /obj/item/organ/brain,
"appendix" = /obj/item/organ/appendix,
"eyes" = /obj/item/organ/eyes
O_HEART = /obj/item/organ/internal/heart,
O_LUNGS = /obj/item/organ/internal/lungs,
O_LIVER = /obj/item/organ/internal/liver,
O_KIDNEYS = /obj/item/organ/internal/kidneys,
O_BRAIN = /obj/item/organ/internal/brain,
O_APPENDIX = /obj/item/organ/internal/appendix,
O_EYES = /obj/item/organ/internal/eyes
)
var/vision_organ // If set, this organ is required for vision. Defaults to "eyes" if the species has them.
var/list/has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest),
"groin" = list("path" = /obj/item/organ/external/groin),
"head" = list("path" = /obj/item/organ/external/head),
"l_arm" = list("path" = /obj/item/organ/external/arm),
"r_arm" = list("path" = /obj/item/organ/external/arm/right),
"l_leg" = list("path" = /obj/item/organ/external/leg),
"r_leg" = list("path" = /obj/item/organ/external/leg/right),
"l_hand" = list("path" = /obj/item/organ/external/hand),
"r_hand" = list("path" = /obj/item/organ/external/hand/right),
"l_foot" = list("path" = /obj/item/organ/external/foot),
"r_foot" = list("path" = /obj/item/organ/external/foot/right)
BP_TORSO = list("path" = /obj/item/organ/external/chest),
BP_GROIN = list("path" = /obj/item/organ/external/groin),
BP_HEAD = list("path" = /obj/item/organ/external/head),
BP_L_ARM = list("path" = /obj/item/organ/external/arm),
BP_R_ARM = list("path" = /obj/item/organ/external/arm/right),
BP_L_LEG = list("path" = /obj/item/organ/external/leg),
BP_R_LEG = list("path" = /obj/item/organ/external/leg/right),
BP_L_HAND = list("path" = /obj/item/organ/external/hand),
BP_R_HAND = list("path" = /obj/item/organ/external/hand/right),
BP_L_FOOT = list("path" = /obj/item/organ/external/foot),
BP_R_FOOT = list("path" = /obj/item/organ/external/foot/right)
)
// Bump vars
@@ -158,8 +156,8 @@
hud = new()
//If the species has eyes, they are the default vision organ
if(!vision_organ && has_organ["eyes"])
vision_organ = "eyes"
if(!vision_organ && has_organ[O_EYES])
vision_organ = O_EYES
unarmed_attacks = list()
for(var/u_type in unarmed_types)
@@ -186,13 +184,13 @@
return ((H && H.isSynthetic()) ? "flashing a 'system offline' glyph on their monitor" : show_ssd)
/datum/species/proc/get_blood_colour(var/mob/living/carbon/human/H)
return ((H && H.isSynthetic()) ? "#1F181F" : blood_color)
return ((H && H.isSynthetic()) ? SYNTH_BLOOD_COLOUR : blood_color)
/datum/species/proc/get_virus_immune(var/mob/living/carbon/human/H)
return ((H && H.isSynthetic()) ? 1 : virus_immune)
/datum/species/proc/get_flesh_colour(var/mob/living/carbon/human/H)
return ((H && H.isSynthetic()) ? "#575757" : flesh_color)
return ((H && H.isSynthetic()) ? SYNTH_FLESH_COLOUR : flesh_color)
/datum/species/proc/get_environment_discomfort(var/mob/living/carbon/human/H, var/msg_type)
@@ -269,7 +267,10 @@
for(var/name in H.organs_by_name)
H.organs |= H.organs_by_name[name]
for(var/obj/item/organ/external/O in H.organs)
for(var/name in H.internal_organs_by_name)
H.internal_organs |= H.internal_organs_by_name[name]
for(var/obj/item/organ/O in (H.organs|H.internal_organs))
O.owner = H
/datum/species/proc/hug(var/mob/living/carbon/human/H,var/mob/living/target)
@@ -33,7 +33,7 @@
return 0
switch(zone)
if("head", "mouth", "eyes")
if(BP_HEAD, O_MOUTH, O_EYES)
// ----- HEAD ----- //
switch(attack_damage)
if(1 to 2)
@@ -18,7 +18,7 @@
flesh_color = "#137E8F"
has_organ = list(
"brain" = /obj/item/organ/brain/golem
"brain" = /obj/item/organ/internal/brain/golem
)
death_message = "becomes completely motionless..."
@@ -38,12 +38,12 @@
toxins_mod = 1.1
has_organ = list(
"heart" = /obj/item/organ/heart,
"lungs" = /obj/item/organ/lungs,
"liver" = /obj/item/organ/liver,
"kidneys" = /obj/item/organ/kidneys,
"brain" = /obj/item/organ/brain,
"eyes" = /obj/item/organ/eyes
O_HEART = /obj/item/organ/heart,
O_LUNGS = /obj/item/organ/lungs,
O_LIVER = /obj/item/organ/liver,
O_KIDNEYS = /obj/item/organ/kidneys,
O_BRAIN = /obj/item/organ/brain,
O_EYES = /obj/item/organ/eyes
)
/*
@@ -39,17 +39,17 @@
pass_flags = PASSTABLE
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest),
"groin" = list("path" = /obj/item/organ/external/groin),
"head" = list("path" = /obj/item/organ/external/head/no_eyes),
"l_arm" = list("path" = /obj/item/organ/external/arm),
"r_arm" = list("path" = /obj/item/organ/external/arm/right),
"l_leg" = list("path" = /obj/item/organ/external/leg),
"r_leg" = list("path" = /obj/item/organ/external/leg/right),
"l_hand" = list("path" = /obj/item/organ/external/hand),
"r_hand" = list("path" = /obj/item/organ/external/hand/right),
"l_foot" = list("path" = /obj/item/organ/external/foot),
"r_foot" = list("path" = /obj/item/organ/external/foot/right)
BP_TORSO = list("path" = /obj/item/organ/external/chest),
BP_GROIN = list("path" = /obj/item/organ/external/groin),
BP_HEAD = list("path" = /obj/item/organ/external/head/no_eyes),
BP_L_ARM = list("path" = /obj/item/organ/external/arm),
BP_R_ARM = list("path" = /obj/item/organ/external/arm/right),
BP_L_LEG = list("path" = /obj/item/organ/external/leg),
BP_R_LEG = list("path" = /obj/item/organ/external/leg/right),
BP_L_HAND = list("path" = /obj/item/organ/external/hand),
BP_R_HAND = list("path" = /obj/item/organ/external/hand/right),
BP_L_FOOT = list("path" = /obj/item/organ/external/foot),
BP_R_FOOT = list("path" = /obj/item/organ/external/foot/right)
)
/datum/species/monkey/handle_npc(var/mob/living/carbon/human/H)
@@ -20,7 +20,7 @@
death_message = "rapidly loses cohesion, splattering across the ground..."
has_organ = list(
"brain" = /obj/item/organ/brain/slime
"brain" = /obj/item/organ/internal/brain/slime
)
breath_type = null
@@ -31,17 +31,17 @@
push_flags = MONKEY|SLIME|SIMPLE_ANIMAL
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest/unbreakable),
"groin" = list("path" = /obj/item/organ/external/groin/unbreakable),
"head" = list("path" = /obj/item/organ/external/head/unbreakable),
"l_arm" = list("path" = /obj/item/organ/external/arm/unbreakable),
"r_arm" = list("path" = /obj/item/organ/external/arm/right/unbreakable),
"l_leg" = list("path" = /obj/item/organ/external/leg/unbreakable),
"r_leg" = list("path" = /obj/item/organ/external/leg/right/unbreakable),
"l_hand" = list("path" = /obj/item/organ/external/hand/unbreakable),
"r_hand" = list("path" = /obj/item/organ/external/hand/right/unbreakable),
"l_foot" = list("path" = /obj/item/organ/external/foot/unbreakable),
"r_foot" = list("path" = /obj/item/organ/external/foot/right/unbreakable)
BP_TORSO = list("path" = /obj/item/organ/external/chest/unbreakable),
BP_GROIN = list("path" = /obj/item/organ/external/groin/unbreakable),
BP_HEAD = list("path" = /obj/item/organ/external/head/unbreakable),
BP_L_ARM = list("path" = /obj/item/organ/external/arm/unbreakable),
BP_R_ARM = list("path" = /obj/item/organ/external/arm/right/unbreakable),
BP_L_LEG = list("path" = /obj/item/organ/external/leg/unbreakable),
BP_R_LEG = list("path" = /obj/item/organ/external/leg/right/unbreakable),
BP_L_HAND = list("path" = /obj/item/organ/external/hand/unbreakable),
BP_R_HAND = list("path" = /obj/item/organ/external/hand/right/unbreakable),
BP_L_FOOT = list("path" = /obj/item/organ/external/foot/unbreakable),
BP_R_FOOT = list("path" = /obj/item/organ/external/foot/right/unbreakable)
)
/datum/species/slime/handle_death(var/mob/living/carbon/human/H)
@@ -152,17 +152,17 @@
reagent_tag = IS_SKRELL
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest),
"groin" = list("path" = /obj/item/organ/external/groin),
"head" = list("path" = /obj/item/organ/external/head/skrell),
"l_arm" = list("path" = /obj/item/organ/external/arm),
"r_arm" = list("path" = /obj/item/organ/external/arm/right),
"l_leg" = list("path" = /obj/item/organ/external/leg),
"r_leg" = list("path" = /obj/item/organ/external/leg/right),
"l_hand" = list("path" = /obj/item/organ/external/hand),
"r_hand" = list("path" = /obj/item/organ/external/hand/right),
"l_foot" = list("path" = /obj/item/organ/external/foot),
"r_foot" = list("path" = /obj/item/organ/external/foot/right)
BP_TORSO = list("path" = /obj/item/organ/external/chest),
BP_GROIN = list("path" = /obj/item/organ/external/groin),
BP_HEAD = list("path" = /obj/item/organ/external/head/skrell),
BP_L_ARM = list("path" = /obj/item/organ/external/arm),
BP_R_ARM = list("path" = /obj/item/organ/external/arm/right),
BP_L_LEG = list("path" = /obj/item/organ/external/leg),
BP_R_LEG = list("path" = /obj/item/organ/external/leg/right),
BP_L_HAND = list("path" = /obj/item/organ/external/hand),
BP_R_HAND = list("path" = /obj/item/organ/external/hand/right),
BP_L_FOOT = list("path" = /obj/item/organ/external/foot),
BP_R_FOOT = list("path" = /obj/item/organ/external/foot/right)
)
/datum/species/diona
@@ -190,26 +190,26 @@
water and other radiation."
has_organ = list(
"nutrient channel" = /obj/item/organ/diona/nutrients,
"neural strata" = /obj/item/organ/diona/strata,
"response node" = /obj/item/organ/diona/node,
"gas bladder" = /obj/item/organ/diona/bladder,
"polyp segment" = /obj/item/organ/diona/polyp,
"anchoring ligament" = /obj/item/organ/diona/ligament
O_NUTRIENT = /obj/item/organ/internal/diona/nutrients,
O_STRATA = /obj/item/organ/internal/diona/strata,
O_RESPONSE = /obj/item/organ/internal/diona/node,
O_GBLADDER = /obj/item/organ/internal/diona/bladder,
O_POLYP = /obj/item/organ/internal/diona/polyp,
O_ANCHOR = /obj/item/organ/internal/diona/ligament
)
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/diona/chest),
"groin" = list("path" = /obj/item/organ/external/diona/groin),
"head" = list("path" = /obj/item/organ/external/head/no_eyes/diona),
"l_arm" = list("path" = /obj/item/organ/external/diona/arm),
"r_arm" = list("path" = /obj/item/organ/external/diona/arm/right),
"l_leg" = list("path" = /obj/item/organ/external/diona/leg),
"r_leg" = list("path" = /obj/item/organ/external/diona/leg/right),
"l_hand" = list("path" = /obj/item/organ/external/diona/hand),
"r_hand" = list("path" = /obj/item/organ/external/diona/hand/right),
"l_foot" = list("path" = /obj/item/organ/external/diona/foot),
"r_foot" = list("path" = /obj/item/organ/external/diona/foot/right)
BP_TORSO = list("path" = /obj/item/organ/external/diona/chest),
BP_GROIN = list("path" = /obj/item/organ/external/diona/groin),
BP_HEAD = list("path" = /obj/item/organ/external/head/no_eyes/diona),
BP_L_ARM = list("path" = /obj/item/organ/external/diona/arm),
BP_R_ARM = list("path" = /obj/item/organ/external/diona/arm/right),
BP_L_LEG = list("path" = /obj/item/organ/external/diona/leg),
BP_R_LEG = list("path" = /obj/item/organ/external/diona/leg/right),
BP_L_HAND = list("path" = /obj/item/organ/external/diona/hand),
BP_R_HAND = list("path" = /obj/item/organ/external/diona/hand/right),
BP_L_FOOT = list("path" = /obj/item/organ/external/diona/foot),
BP_R_FOOT = list("path" = /obj/item/organ/external/diona/foot/right)
)
inherent_verbs = list(
@@ -260,9 +260,13 @@
if(H.mind)
H.mind.transfer_to(S)
if(H.isSynthetic())
H.visible_message("<span class='danger'>\The [H] collapses into parts, revealing a solitary diona nymph at the core.</span>")
return
for(var/mob/living/carbon/alien/diona/D in H.contents)
if(D.client)
D.loc = H.loc
D.forceMove(get_turf(H))
else
qdel(D)
@@ -108,7 +108,7 @@ Des: Removes all infection images from aliens and places an infection image on a
for(var/mob/living/carbon/alien in player_list)
if(!locate(/obj/item/organ/xenos/hivenode) in alien.internal_organs)
if(!locate(/obj/item/organ/internal/xenos/hivenode) in alien.internal_organs)
continue
if(alien.client)
@@ -130,7 +130,7 @@ Des: Checks if the passed mob (C) is infected with the alien egg, then gives eac
for(var/mob/living/carbon/alien in player_list)
if(!locate(/obj/item/organ/xenos/hivenode) in alien.internal_organs)
if(!locate(/obj/item/organ/internal/xenos/hivenode) in alien.internal_organs)
continue
if(alien.client)
@@ -149,7 +149,7 @@ Des: Removes the alien infection image from all aliens in the world located in p
for(var/mob/living/carbon/alien in player_list)
if(!locate(/obj/item/organ/xenos/hivenode) in alien.internal_organs)
if(!locate(/obj/item/organ/internal/xenos/hivenode) in alien.internal_organs)
continue
if(alien.client)
@@ -110,7 +110,7 @@ var/const/MAX_ACTIVE_TIME = 400
return
var/mob/living/carbon/C = M
if(istype(C) && locate(/obj/item/organ/xenos/hivenode) in C.internal_organs)
if(istype(C) && locate(/obj/item/organ/internal/xenos/hivenode) in C.internal_organs)
return
@@ -221,7 +221,7 @@ var/const/MAX_ACTIVE_TIME = 400
return 0
var/mob/living/carbon/C = M
if(istype(C) && locate(/obj/item/organ/xenos/hivenode) in C.internal_organs)
if(istype(C) && locate(/obj/item/organ/internal/xenos/hivenode) in C.internal_organs)
return 0
if(ishuman(C))
@@ -11,7 +11,7 @@
/mob/living/carbon/human/proc/gain_plasma(var/amount)
var/obj/item/organ/xenos/plasmavessel/I = internal_organs_by_name["plasma vessel"]
var/obj/item/organ/internal/xenos/plasmavessel/I = internal_organs_by_name[O_PLASMA]
if(!istype(I)) return
if(amount)
@@ -20,13 +20,13 @@
/mob/living/carbon/human/proc/check_alien_ability(var/cost,var/needs_foundation,var/needs_organ)
var/obj/item/organ/xenos/plasmavessel/P = internal_organs_by_name["plasma vessel"]
var/obj/item/organ/internal/xenos/plasmavessel/P = internal_organs_by_name[O_PLASMA]
if(!istype(P))
src << "<span class='danger'>Your plasma vessel has been removed!</span>"
return
if(needs_organ)
var/obj/item/organ/I = internal_organs_by_name[needs_organ]
var/obj/item/organ/internal/I = internal_organs_by_name[needs_organ]
if(!I)
src << "<span class='danger'>Your [needs_organ] has been removed!</span>"
return
@@ -62,7 +62,7 @@
src << "<span class='alium'>You need to be closer.</span>"
return
var/obj/item/organ/xenos/plasmavessel/I = M.internal_organs_by_name["plasma vessel"]
var/obj/item/organ/internal/xenos/plasmavessel/I = M.internal_organs_by_name[O_PLASMA]
if(!istype(I))
src << "<span class='alium'>Their plasma vessel is missing.</span>"
return
@@ -70,7 +70,7 @@
var/amount = input("Amount:", "Transfer Plasma to [M]") as num
if (amount)
amount = abs(round(amount))
if(check_alien_ability(amount,0,"plasma vessel"))
if(check_alien_ability(amount,0,O_PLASMA))
M.gain_plasma(amount)
M << "<span class='alium'>[src] has transfered [amount] plasma to you.</span>"
src << "<span class='alium'>You have transferred [amount] plasma to [M].</span>"
@@ -92,7 +92,7 @@
src << "There's already an egg here."
return
if(check_alien_ability(75,1,"egg sac"))
if(check_alien_ability(75,1,O_EGG))
visible_message("<span class='alium'><B>[src] has laid an egg!</B></span>")
new /obj/effect/alien/egg(loc)
@@ -119,7 +119,7 @@
set desc = "Plants some alien weeds"
set category = "Abilities"
if(check_alien_ability(50,1,"resin spinner"))
if(check_alien_ability(50,1,O_RESIN))
visible_message("<span class='alium'><B>[src] has planted some alien weeds!</B></span>")
new /obj/effect/alien/weeds/node(loc)
return
@@ -153,7 +153,7 @@
src << "<span class='alium'>You cannot dissolve this object.</span>"
return
if(check_alien_ability(200,0,"acid gland"))
if(check_alien_ability(200,0,O_ACID))
new /obj/effect/alien/acid(get_turf(O), O)
visible_message("<span class='alium'><B>[src] vomits globs of vile stuff all over [O]. It begins to sizzle and melt under the bubbling mess of acid!</B></span>")
@@ -164,7 +164,7 @@
set desc = "Spits neurotoxin at someone, paralyzing them for a short time if they are not wearing protective gear."
set category = "Abilities"
if(!check_alien_ability(50,0,"acid gland"))
if(!check_alien_ability(50,0,O_ACID))
return
if(stat || paralysis || stunned || weakened || lying || restrained() || buckled)
@@ -206,7 +206,7 @@
if(!choice)
return
if(!check_alien_ability(75,1,"resin spinner"))
if(!check_alien_ability(75,1,O_RESIN))
return
visible_message("<span class='warning'><B>[src] vomits up a thick purple substance and begins to shape it!</B></span>", "<span class='alium'>You shape a [choice].</span>")
@@ -44,11 +44,11 @@
vision_flags = SEE_SELF|SEE_MOBS
has_organ = list(
"heart" = /obj/item/organ/heart,
"brain" = /obj/item/organ/brain/xeno,
"plasma vessel" = /obj/item/organ/xenos/plasmavessel,
"hive node" = /obj/item/organ/xenos/hivenode,
"nutrient vessel" = /obj/item/organ/diona/nutrients
O_HEART = /obj/item/organ/internal/heart,
O_BRAIN = /obj/item/organ/internal/brain/xeno,
O_PLASMA = /obj/item/organ/internal/xenos/plasmavessel,
O_HIVE = /obj/item/organ/internal/xenos/hivenode,
O_NUTRIENT = /obj/item/organ/internal/diona/nutrients
)
bump_flag = ALIEN
@@ -61,17 +61,17 @@
var/weeds_plasma_rate = 5 // Plasma regen on weeds.
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest),
"groin" = list("path" = /obj/item/organ/external/groin),
"head" = list("path" = /obj/item/organ/external/head/no_eyes),
"l_arm" = list("path" = /obj/item/organ/external/arm),
"r_arm" = list("path" = /obj/item/organ/external/arm/right),
"l_leg" = list("path" = /obj/item/organ/external/leg),
"r_leg" = list("path" = /obj/item/organ/external/leg/right),
"l_hand" = list("path" = /obj/item/organ/external/hand),
"r_hand" = list("path" = /obj/item/organ/external/hand/right),
"l_foot" = list("path" = /obj/item/organ/external/foot),
"r_foot" = list("path" = /obj/item/organ/external/foot/right)
BP_TORSO = list("path" = /obj/item/organ/external/chest),
BP_GROIN = list("path" = /obj/item/organ/external/groin),
BP_HEAD = list("path" = /obj/item/organ/external/head/no_eyes),
BP_L_ARM = list("path" = /obj/item/organ/external/arm),
BP_R_ARM = list("path" = /obj/item/organ/external/arm/right),
BP_L_LEG = list("path" = /obj/item/organ/external/leg),
BP_R_LEG = list("path" = /obj/item/organ/external/leg/right),
BP_L_HAND = list("path" = /obj/item/organ/external/hand),
BP_R_HAND = list("path" = /obj/item/organ/external/hand/right),
BP_L_FOOT = list("path" = /obj/item/organ/external/foot),
BP_R_FOOT = list("path" = /obj/item/organ/external/foot/right)
)
/datum/species/xenos/get_bodytype()
@@ -112,7 +112,7 @@
if(environment.gas["phoron"] > 0 || locate(/obj/effect/alien/weeds) in T)
if(!regenerate(H))
var/obj/item/organ/xenos/plasmavessel/P = H.internal_organs_by_name["plasma vessel"]
var/obj/item/organ/internal/xenos/plasmavessel/P = H.internal_organs_by_name[O_PLASMA]
P.stored_plasma += weeds_plasma_rate
P.stored_plasma = min(max(P.stored_plasma,0),P.max_plasma)
..()
@@ -172,13 +172,13 @@
deform = 'icons/mob/human_races/xenos/r_xenos_drone.dmi'
has_organ = list(
"heart" = /obj/item/organ/heart,
"brain" = /obj/item/organ/brain/xeno,
"plasma vessel" = /obj/item/organ/xenos/plasmavessel/queen,
"acid gland" = /obj/item/organ/xenos/acidgland,
"hive node" = /obj/item/organ/xenos/hivenode,
"resin spinner" = /obj/item/organ/xenos/resinspinner,
"nutrient vessel" = /obj/item/organ/diona/nutrients
O_HEART = /obj/item/organ/internal/heart,
O_BRAIN = /obj/item/organ/internal/brain/xeno,
O_PLASMA = /obj/item/organ/internal/xenos/plasmavessel/queen,
O_ACID = /obj/item/organ/internal/xenos/acidgland,
O_HIVE = /obj/item/organ/internal/xenos/hivenode,
O_RESIN = /obj/item/organ/internal/xenos/resinspinner,
O_NUTRIENT = /obj/item/organ/internal/diona/nutrients
)
inherent_verbs = list(
@@ -211,11 +211,11 @@
deform = 'icons/mob/human_races/xenos/r_xenos_hunter.dmi'
has_organ = list(
"heart" = /obj/item/organ/heart,
"brain" = /obj/item/organ/brain/xeno,
"plasma vessel" = /obj/item/organ/xenos/plasmavessel/hunter,
"hive node" = /obj/item/organ/xenos/hivenode,
"nutrient vessel" = /obj/item/organ/diona/nutrients
O_HEART = /obj/item/organ/internal/heart,
O_BRAIN = /obj/item/organ/internal/brain/xeno,
O_PLASMA = /obj/item/organ/internal/xenos/plasmavessel/hunter,
O_HIVE = /obj/item/organ/internal/xenos/hivenode,
O_NUTRIENT = /obj/item/organ/internal/diona/nutrients
)
inherent_verbs = list(
@@ -239,12 +239,12 @@
deform = 'icons/mob/human_races/xenos/r_xenos_sentinel.dmi'
has_organ = list(
"heart" = /obj/item/organ/heart,
"brain" = /obj/item/organ/brain/xeno,
"plasma vessel" = /obj/item/organ/xenos/plasmavessel/sentinel,
"acid gland" = /obj/item/organ/xenos/acidgland,
"hive node" = /obj/item/organ/xenos/hivenode,
"nutrient vessel" = /obj/item/organ/diona/nutrients
O_HEART = /obj/item/organ/internal/heart,
O_BRAIN = /obj/item/organ/internal/brain/xeno,
O_PLASMA = /obj/item/organ/internal/xenos/plasmavessel/sentinel,
O_ACID = /obj/item/organ/internal/xenos/acidgland,
O_HIVE = /obj/item/organ/internal/xenos/hivenode,
O_NUTRIENT = /obj/item/organ/internal/diona/nutrients
)
inherent_verbs = list(
@@ -271,14 +271,14 @@
deform = 'icons/mob/human_races/xenos/r_xenos_queen.dmi'
has_organ = list(
"heart" = /obj/item/organ/heart,
"brain" = /obj/item/organ/brain/xeno,
"egg sac" = /obj/item/organ/xenos/eggsac,
"plasma vessel" = /obj/item/organ/xenos/plasmavessel/queen,
"acid gland" = /obj/item/organ/xenos/acidgland,
"hive node" = /obj/item/organ/xenos/hivenode,
"resin spinner" = /obj/item/organ/xenos/resinspinner,
"nutrient vessel" = /obj/item/organ/diona/nutrients
O_HEART = /obj/item/organ/internal/heart,
O_BRAIN = /obj/item/organ/internal/brain/xeno,
O_EGG = /obj/item/organ/internal/xenos/eggsac,
O_PLASMA = /obj/item/organ/internal/xenos/plasmavessel/queen,
O_ACID = /obj/item/organ/internal/xenos/acidgland,
O_HIVE = /obj/item/organ/internal/xenos/hivenode,
O_RESIN = /obj/item/organ/internal/xenos/resinspinner,
O_NUTRIENT = /obj/item/organ/internal/diona/nutrients
)
inherent_verbs = list(
@@ -121,7 +121,7 @@
if(can_reach_splints)
var/removed_splint
for(var/organ in list("l_leg","r_leg","l_arm","r_arm"))
for(var/organ in list(BP_L_LEG, BP_R_LEG, BP_L_ARM, BP_R_ARM))
var/obj/item/organ/external/o = get_organ(organ)
if (o && o.status & ORGAN_SPLINTED)
var/obj/item/W = new /obj/item/stack/medical/splint(get_turf(src), 1)
@@ -47,22 +47,22 @@ var/global/list/sparring_attack_cache = list()
if(attack_damage >= 5 && armour < 2 && !(target == user) && stun_chance <= attack_damage * 5) // 25% standard chance
switch(zone) // strong punches can have effects depending on where they hit
if("head", "mouth", "eyes")
if(BP_HEAD, O_EYES, O_MOUTH)
// Induce blurriness
target.visible_message("<span class='danger'>[target] looks momentarily disoriented.</span>", "<span class='danger'>You see stars.</span>")
target.apply_effect(attack_damage*2, EYE_BLUR, armour)
if("l_arm", "l_hand")
if(BP_L_ARM, BP_L_HAND)
if (target.l_hand)
// Disarm left hand
//Urist McAssistant dropped the macguffin with a scream just sounds odd.
target.visible_message("<span class='danger'>\The [target.l_hand] was knocked right out of [target]'s grasp!</span>")
target.drop_l_hand()
if("r_arm", "r_hand")
if(BP_R_ARM, BP_R_HAND)
if (target.r_hand)
// Disarm right hand
target.visible_message("<span class='danger'>\The [target.r_hand] was knocked right out of [target]'s grasp!</span>")
target.drop_r_hand()
if("chest")
if(BP_TORSO)
if(!target.lying)
var/turf/T = get_step(get_turf(target), get_dir(get_turf(user), get_turf(target)))
if(!T.density)
@@ -73,7 +73,7 @@ var/global/list/sparring_attack_cache = list()
if(prob(50))
target.set_dir(reverse_dir[target.dir])
target.apply_effect(attack_damage * 0.4, WEAKEN, armour)
if("groin")
if(BP_GROIN)
target.visible_message("<span class='warning'>[target] looks like \he is in pain!</span>", "<span class='warning'>[(target.gender=="female") ? "Oh god that hurt!" : "Oh no, not your[pick("testicles", "crown jewels", "clockweights", "family jewels", "marbles", "bean bags", "teabags", "sweetmeats", "goolies")]!"]</span>")
target.apply_effects(stutter = attack_damage * 2, agony = attack_damage* 3, blocked = armour)
if("l_leg", "l_foot", "r_leg", "r_foot")
@@ -93,7 +93,7 @@ var/global/list/sparring_attack_cache = list()
playsound(user.loc, attack_sound, 25, 1, -1)
/datum/unarmed_attack/proc/handle_eye_attack(var/mob/living/carbon/human/user, var/mob/living/carbon/human/target)
var/obj/item/organ/eyes/eyes = target.internal_organs_by_name["eyes"]
var/obj/item/organ/internal/eyes/eyes = target.internal_organs_by_name[O_EYES]
if(eyes)
eyes.take_damage(rand(3,4), 1)
user.visible_message("<span class='danger'>[user] presses \his [eye_attack_text] into [target]'s [eyes.name]!</span>")
@@ -114,7 +114,7 @@ var/global/list/sparring_attack_cache = list()
if (user.wear_mask && istype(user.wear_mask, /obj/item/clothing/mask/muzzle))
return 0
if (user == target && (zone == "head" || zone == "eyes" || zone == "mouth"))
if (user == target && (zone == BP_HEAD || zone == O_EYES || zone == O_MOUTH))
return 0
return 1
@@ -137,7 +137,7 @@ var/global/list/sparring_attack_cache = list()
if(!target.lying)
switch(zone)
if("head", "mouth", "eyes")
if(BP_HEAD, O_MOUTH, O_EYES)
// ----- HEAD ----- //
switch(attack_damage)
if(1 to 2)
@@ -177,7 +177,7 @@ var/global/list/sparring_attack_cache = list()
if (user.legcuffed)
return 0
if(!(zone in list("l_leg", "r_leg", "l_foot", "r_foot", "groin")))
if(!(zone in list("l_leg", "r_leg", "l_foot", "r_foot", BP_GROIN)))
return 0
var/obj/item/organ/external/E = user.organs_by_name["l_foot"]
@@ -208,12 +208,13 @@ var/global/list/damage_icon_parts = list()
if(!(O.status & ORGAN_DESTROYED))
O.update_icon()
if(O.damage_state == "00") continue
var/use_colour = ((O.status & ORGAN_ROBOT) ? SYNTH_BLOOD_COLOUR : O.species.get_blood_colour(src))
var/icon/DI
var/cache_index = "[O.damage_state]/[O.icon_name]/[O.species.get_blood_colour()]/[species.get_bodytype()]"
var/cache_index = "[O.damage_state]/[O.icon_name]/[use_colour]/[species.get_bodytype()]"
if(damage_icon_parts[cache_index] == null)
DI = new /icon(species.damage_overlays, O.damage_state) // the damage icon for whole human
DI.Blend(new /icon(species.damage_mask, O.icon_name), ICON_MULTIPLY) // mask with this organ's pixels
DI.Blend(O.species.get_blood_colour(), ICON_MULTIPLY)
DI.Blend(use_colour, ICON_MULTIPLY)
damage_icon_parts[cache_index] = DI
else
DI = damage_icon_parts[cache_index]
@@ -252,7 +253,7 @@ var/global/list/damage_icon_parts = list()
icon_key += "[lip_style]"
else
icon_key += "nolips"
var/obj/item/organ/eyes/eyes = internal_organs_by_name["eyes"]
var/obj/item/organ/internal/eyes/eyes = internal_organs_by_name[O_EYES]
if(eyes)
icon_key += "[rgb(eyes.eye_colour[1], eyes.eye_colour[2], eyes.eye_colour[3])]"
else
@@ -286,7 +287,7 @@ var/global/list/damage_icon_parts = list()
base_icon = human_icon_cache[icon_key]
else
//BEGIN CACHED ICON GENERATION.
var/obj/item/organ/external/chest = get_organ("chest")
var/obj/item/organ/external/chest = get_organ(BP_TORSO)
base_icon = chest.get_icon()
for(var/obj/item/organ/external/part in organs)
@@ -351,7 +352,7 @@ var/global/list/damage_icon_parts = list()
//Reset our hair
overlays_standing[HAIR_LAYER] = null
var/obj/item/organ/external/head/head_organ = get_organ("head")
var/obj/item/organ/external/head/head_organ = get_organ(BP_HEAD)
if(!head_organ || head_organ.is_stump() || (head_organ.status & ORGAN_DESTROYED) )
if(update_icons) update_icons()
return
@@ -763,9 +764,10 @@ var/global/list/damage_icon_parts = list()
if(wear_suit.blood_DNA)
var/obj/item/clothing/suit/S = wear_suit
var/image/bloodsies = image("icon" = species.blood_mask, "icon_state" = "[S.blood_overlay_type]blood")
bloodsies.color = wear_suit.blood_color
standing.overlays += bloodsies
if(istype(S)) //You can put non-suits in your suit slot (diona nymphs etc).
var/image/bloodsies = image("icon" = species.blood_mask, "icon_state" = "[S.blood_overlay_type]blood")
bloodsies.color = wear_suit.blood_color
standing.overlays += bloodsies
overlays_standing[SUIT_LAYER] = standing
update_tail_showing(0)
@@ -33,15 +33,9 @@
else
loc_temp = environment.temperature
if(loc_temp < 310.15) // a cold place
bodytemperature += adjust_body_temperature(bodytemperature, loc_temp, 1)
else // a hot place
bodytemperature += adjust_body_temperature(bodytemperature, loc_temp, 1)
//Account for massive pressure differences
bodytemperature += adjust_body_temperature(bodytemperature, loc_temp, 1)
if(bodytemperature < (T0C + 5)) // start calculating temperature damage etc
if(bodytemperature <= (T0C - 50)) // hurt temperature
if(bodytemperature <= 50) // sqrting negative numbers is bad
adjustToxLoss(200)
+2 -2
View File
@@ -344,8 +344,8 @@ default behaviour is:
/mob/living/proc/get_organ_target()
var/mob/shooter = src
var/t = shooter:zone_sel.selecting
if ((t in list( "eyes", "mouth" )))
t = "head"
if ((t in list( O_EYES, O_MOUTH )))
t = BP_HEAD
var/obj/item/organ/external/def_zone = ran_zone(t)
return def_zone
+1 -1
View File
@@ -404,7 +404,7 @@
var/total_damage = 0
for(var/i in 1 to 3)
var/damage = min(W.force*1.5, 20)*damage_mod
apply_damage(damage, W.damtype, "head", 0, sharp=W.sharp, edge=W.edge)
apply_damage(damage, W.damtype, BP_HEAD, 0, sharp=W.sharp, edge=W.edge)
total_damage += damage
var/oxyloss = total_damage
@@ -65,10 +65,12 @@
user.show_message("\blue Operating Temperature: [M.bodytemperature-T0C]&deg;C ([M.bodytemperature*1.8-459.67]&deg;F)", 1)
if("prosthetics")
var/mob/living/carbon/human/H = M
user << "<span class='notice'>Analyzing Results for \the [H]:</span>"
if(H.isSynthetic())
user << "System instability: <font color='green'>[H.getToxLoss()]</font>"
user << "Key: <font color='#FFA500'>Electronics</font>/<font color='red'>Brute</font>"
user << "<span class='notice'>External prosthetics:</span>"
var/organ_found
if(H.internal_organs.len)
@@ -64,7 +64,7 @@
/obj/item/robot_parts,
/obj/item/borg/upgrade,
/obj/item/device/flash, //to build borgs
/obj/item/organ/brain, //to insert into MMIs.
/obj/item/organ/internal/brain, //to insert into MMIs.
/obj/item/stack/cable_coil, //again, for borg building
/obj/item/weapon/circuitboard,
/obj/item/slime_extract,
@@ -106,7 +106,7 @@
if(istype(host,/mob/living/carbon/human))
var/mob/living/carbon/human/H = host
var/obj/item/organ/external/head = H.get_organ("head")
var/obj/item/organ/external/head = H.get_organ(BP_HEAD)
head.implants -= src
controlling = 0
@@ -73,7 +73,7 @@
if(istype(M,/mob/living/carbon/human))
var/mob/living/carbon/human/H = M
var/obj/item/organ/external/E = H.organs_by_name["head"]
var/obj/item/organ/external/E = H.organs_by_name[BP_HEAD]
if(!E || (E.status & ORGAN_DESTROYED))
src << "\The [H] does not have a head!"
@@ -118,7 +118,7 @@
replace_brain()
else
// If they're in normally, implant removal can get them out.
var/obj/item/organ/external/head = H.get_organ("head")
var/obj/item/organ/external/head = H.get_organ(BP_HEAD)
head.implants += src
return
@@ -181,11 +181,11 @@
H.ChangeToHusk()
var/obj/item/organ/borer/B = new(H)
var/obj/item/organ/internal/borer/B = new(H)
H.internal_organs_by_name["brain"] = B
H.internal_organs |= B
var/obj/item/organ/external/affecting = H.get_organ("head")
var/obj/item/organ/external/affecting = H.get_organ(BP_HEAD)
affecting.implants -= src
var/s2h_id = src.computer_id
@@ -133,7 +133,7 @@
if(ishuman(target_mob))
var/mob/living/carbon/human/H = target_mob
var/dam_zone = pick("chest", "l_hand", "r_hand", "l_leg", "r_leg")
var/dam_zone = pick(BP_TORSO, BP_L_HAND, BP_R_HAND, BP_L_LEG, BP_R_LEG)
var/obj/item/organ/external/affecting = H.get_organ(ran_zone(dam_zone))
H.apply_damage(damage, BRUTE, affecting, H.run_armor_check(affecting, "melee"), sharp=1, edge=1)
return H
@@ -53,7 +53,7 @@
var/parrot_state = PARROT_WANDER //Hunt for a perch when created
var/parrot_sleep_max = 25 //The time the parrot sits while perched before looking around. Mosly a way to avoid the parrot's AI in life() being run every single tick.
var/parrot_sleep_dur = 25 //Same as above, this is the var that physically counts down
var/parrot_dam_zone = list("chest", "head", "l_arm", "l_leg", "r_arm", "r_leg") //For humans, select a bodypart to attack
var/parrot_dam_zone = list(BP_TORSO, BP_HEAD, BP_L_ARM, BP_R_ARM, BP_L_LEG, BP_R_LEG) //For humans, select a bodypart to attack
var/parrot_speed = 5 //"Delay in world ticks between movement." according to byond. Yeah, that's BS but it does directly affect movement. Higher number = slower.
var/parrot_been_shot = 0 //Parrots get a speed bonus after being shot. This will deincrement every Life() and at 0 the parrot will return to regular speed.
+3
View File
@@ -1128,3 +1128,6 @@ mob/proc/yank_out_object()
src.in_throw_mode = 1
if(src.throw_icon)
src.throw_icon.icon_state = "act_throw_on"
/mob/proc/isSynthetic()
return 0
+16 -16
View File
@@ -124,7 +124,7 @@
if(iscarbon(affecting))
handle_eye_mouth_covering(affecting, assailant, assailant.zone_sel.selecting)
if(force_down)
if(affecting.loc != assailant.loc)
force_down = 0
@@ -148,14 +148,14 @@
/obj/item/weapon/grab/proc/handle_eye_mouth_covering(mob/living/carbon/target, mob/user, var/target_zone)
var/announce = (target_zone != last_hit_zone) //only display messages when switching between different target zones
last_hit_zone = target_zone
switch(target_zone)
if("mouth")
if(O_MOUTH)
if(announce)
user.visible_message("<span class='warning'>\The [user] covers [target]'s mouth!</span>")
if(target.silent < 3)
target.silent = 3
if("eyes")
if(O_EYES)
if(announce)
assailant.visible_message("<span class='warning'>[assailant] covers [affecting]'s eyes!</span>")
if(affecting.eye_blind < 3)
@@ -232,7 +232,7 @@
else
assailant.visible_message("<span class='warning'>[assailant] pins [affecting] down to the ground (now hands)!</span>")
apply_pinning(affecting, assailant)
state = GRAB_AGGRESSIVE
icon_state = "grabbed1"
hud.icon_state = "reinforce1"
@@ -252,7 +252,7 @@
hud.name = "kill"
affecting.Stun(10) //10 ticks of ensured grab
else if(state < GRAB_UPGRADING)
assailant.visible_message("<span class='danger'>[assailant] starts to tighten \his grip on [affecting]'s neck!</span>")
assailant.visible_message("<span class='danger'>[assailant] starts to tighten \his grip on [affecting]'s neck!</span>")
hud.icon_state = "kill1"
state = GRAB_KILL
@@ -264,7 +264,7 @@
affecting.setClickCooldown(10)
affecting.losebreath += 1
affecting.set_dir(WEST)
adjust_position()
adjust_position()
//This is used to make sure the victim hasn't managed to yackety sax away before using the grab.
/obj/item/weapon/grab/proc/confirm()
@@ -284,10 +284,10 @@
return
if(world.time < (last_action + 20))
return
last_action = world.time
reset_kill_state() //using special grab moves will interrupt choking them
//clicking on the victim while grabbing them
if(M == affecting)
if(ishuman(affecting))
@@ -300,21 +300,21 @@
force_down = 0
return
inspect_organ(affecting, assailant, hit_zone)
if(I_GRAB)
jointlock(affecting, assailant, hit_zone)
if(I_HURT)
if(hit_zone == "eyes")
if(hit_zone == O_EYES)
attack_eye(affecting, assailant)
else if(hit_zone == "head")
else if(hit_zone == BP_HEAD)
headbut(affecting, assailant)
else
dislocate(affecting, assailant, hit_zone)
if(I_DISARM)
pin_down(affecting, assailant)
//clicking on yourself while grabbing them
if(M == assailant && state >= GRAB_AGGRESSIVE)
devour(affecting, assailant)
@@ -325,7 +325,7 @@
qdel(src)
/obj/item/weapon/grab/proc/reset_kill_state()
if(state == GRAB_KILL)
if(state == GRAB_KILL)
assailant.visible_message("<span class='warning'>[assailant] lost \his tight grip on [affecting]'s neck!</span>")
hud.icon_state = "kill"
state = GRAB_NECK
+5 -5
View File
@@ -60,7 +60,7 @@
if(!istype(attacker))
return
var/datum/unarmed_attack/attack = attacker.get_unarmed_attack(target, "eyes")
var/datum/unarmed_attack/attack = attacker.get_unarmed_attack(target, O_EYES)
if(!attack)
return
@@ -93,11 +93,11 @@
if(istype(hat))
damage += hat.force * 3
var/armor = target.run_armor_check("head", "melee")
target.apply_damage(damage, BRUTE, "head", armor)
attacker.apply_damage(10, BRUTE, "head", attacker.run_armor_check("head", "melee"))
var/armor = target.run_armor_check(BP_HEAD, "melee")
target.apply_damage(damage, BRUTE, BP_HEAD, armor)
attacker.apply_damage(10, BRUTE, BP_HEAD, attacker.run_armor_check(BP_HEAD, "melee"))
if(!armor && target.headcheck("head") && prob(damage))
if(!armor && target.headcheck(BP_HEAD) && prob(damage))
target.apply_effect(20, PARALYZE)
target.visible_message("<span class='danger'>[target] [target.species.get_knockout_message(target)]</span>")
+59 -57
View File
@@ -11,15 +11,16 @@
return L.mob_size <= MOB_SMALL
return 0
/mob/living/proc/isSynthetic()
return 0
// If they are 100% robotic, they count as synthetic.
/mob/living/carbon/human/isSynthetic()
// If they are 100% robotic, they count as synthetic.
for(var/obj/item/organ/external/E in organs)
if(!(E.status & ORGAN_ROBOT))
return 0
return 1
if(isnull(full_prosthetic))
robolimb_count = 0
for(var/obj/item/organ/external/E in organs)
if(E.status & ORGAN_ROBOT)
robolimb_count++
if(robolimb_count == organs.len)
full_prosthetic = 1
return full_prosthetic
/mob/living/silicon/isSynthetic()
return 1
@@ -72,46 +73,13 @@ proc/getsensorlevel(A)
Miss Chance
*/
//TODO: Integrate defence zones and targeting body parts with the actual organ system, move these into organ definitions.
//The base miss chance for the different defence zones
var/list/global/base_miss_chance = list(
"head" = 40,
"chest" = 10,
"groin" = 20,
"l_leg" = 20,
"r_leg" = 20,
"l_arm" = 20,
"r_arm" = 20,
"l_hand" = 50,
"r_hand" = 50,
"l_foot" = 50,
"r_foot" = 50,
)
//Used to weight organs when an organ is hit randomly (i.e. not a directed, aimed attack).
//Also used to weight the protection value that armour provides for covering that body part when calculating protection from full-body effects.
var/list/global/organ_rel_size = list(
"head" = 25,
"chest" = 70,
"groin" = 30,
"l_leg" = 25,
"r_leg" = 25,
"l_arm" = 25,
"r_arm" = 25,
"l_hand" = 10,
"r_hand" = 10,
"l_foot" = 10,
"r_foot" = 10,
)
/proc/check_zone(zone)
if(!zone) return "chest"
if(!zone) return BP_TORSO
switch(zone)
if("eyes")
zone = "head"
if("mouth")
zone = "head"
if(O_EYES)
zone = BP_HEAD
if(O_MOUTH)
zone = BP_HEAD
return zone
// Returns zone with a certain probability. If the probability fails, or no zone is specified, then a random body part is chosen.
@@ -126,17 +94,17 @@ var/list/global/organ_rel_size = list(
var/ran_zone = zone
while (ran_zone == zone)
ran_zone = pick (
organ_rel_size["head"]; "head",
organ_rel_size["chest"]; "chest",
organ_rel_size["groin"]; "groin",
organ_rel_size["l_arm"]; "l_arm",
organ_rel_size["r_arm"]; "r_arm",
organ_rel_size["l_leg"]; "l_leg",
organ_rel_size["r_leg"]; "r_leg",
organ_rel_size["l_hand"]; "l_hand",
organ_rel_size["r_hand"]; "r_hand",
organ_rel_size["l_foot"]; "l_foot",
organ_rel_size["r_foot"]; "r_foot",
organ_rel_size[BP_HEAD]; BP_HEAD,
organ_rel_size[BP_TORSO]; BP_TORSO,
organ_rel_size[BP_GROIN]; BP_GROIN,
organ_rel_size[BP_L_ARM]; BP_L_ARM,
organ_rel_size[BP_R_ARM]; BP_R_ARM,
organ_rel_size[BP_L_LEG]; BP_L_LEG,
organ_rel_size[BP_R_LEG]; BP_R_LEG,
organ_rel_size[BP_L_HAND]; BP_L_HAND,
organ_rel_size[BP_R_HAND]; BP_R_HAND,
organ_rel_size[BP_L_FOOT]; BP_L_FOOT,
organ_rel_size[BP_R_FOOT]; BP_R_FOOT,
)
return ran_zone
@@ -564,3 +532,37 @@ proc/is_blind(A)
return threatcount
#undef SAFE_PERP
//TODO: Integrate defence zones and targeting body parts with the actual organ system, move these into organ definitions.
//The base miss chance for the different defence zones
var/list/global/base_miss_chance = list(
"head" = 40,
"chest" = 10,
"groin" = 20,
"l_leg" = 20,
"r_leg" = 20,
"l_arm" = 20,
"r_arm" = 20,
"l_hand" = 50,
"r_hand" = 50,
"l_foot" = 50,
"r_foot" = 50,
)
//Used to weight organs when an organ is hit randomly (i.e. not a directed, aimed attack).
//Also used to weight the protection value that armour provides for covering that body part when calculating protection from full-body effects.
var/list/global/organ_rel_size = list(
"head" = 25,
"chest" = 70,
"groin" = 30,
"l_leg" = 25,
"r_leg" = 25,
"l_arm" = 25,
"r_arm" = 25,
"l_hand" = 10,
"r_hand" = 10,
"l_foot" = 10,
"r_foot" = 10,
)
@@ -5,7 +5,7 @@ datum/preferences
s_tone = random_skin_tone()
var/use_head_species
var/obj/item/organ/external/head/temp_head = H.get_organ("head")
var/obj/item/organ/external/head/temp_head = H.get_organ(BP_HEAD)
if(temp_head)
use_head_species = temp_head.species.get_bodytype()
else
@@ -202,20 +202,20 @@ datum/preferences
icobase = 'icons/mob/human_races/r_human.dmi'
preview_icon = new /icon(icobase, "")
for(var/name in list("torso", "groin", "head", "r_arm","r_hand","r_leg","r_foot","l_leg","l_foot","l_arm","l_hand"))
for(var/name in BP_ALL)
if(organ_data[name] == "amputated")
continue
if(organ_data[name] == "cyborg")
var/datum/robolimb/R
if(rlimb_data[name]) R = all_robolimbs[rlimb_data[name]]
if(!R) R = basic_robolimb
if(name in list("torso", "groin", "head"))
if(name in list(BP_TORSO, BP_GROIN, BP_HEAD))
preview_icon.Blend(icon(R.icon, "[name]_[g]"), ICON_OVERLAY)
else
preview_icon.Blend(icon(R.icon, "[name]"), ICON_OVERLAY)
continue
var/icon/limb_icon
if(name in list("torso", "groin", "head"))
if(name in list(BP_TORSO, BP_GROIN, BP_HEAD))
limb_icon = new /icon(icobase, "[name]_[g]")
else
limb_icon = new /icon(icobase, "[name]")
@@ -244,7 +244,7 @@ datum/preferences
// This is absolute garbage but whatever. It will do until this entire file can be rewritten without crashes.
var/use_eye_icon = "eyes_s"
var/list/use_eye_data = current_species.has_limbs["head"]
var/list/use_eye_data = current_species.has_limbs[BP_HEAD]
if(islist(use_eye_data))
var/use_eye_path = use_eye_data["path"]
var/obj/item/organ/external/head/temp_head = new use_eye_path ()