IPC fixes galore

This commit is contained in:
Markolie
2014-12-06 08:28:02 +01:00
parent 6c92a48c41
commit 86f80d5a69
14 changed files with 167 additions and 82 deletions
@@ -1,6 +1,9 @@
/mob/living/carbon/brain/say(var/message)
if (silent)
return
if (stat == 2) // Dead.
return say_dead(message)
if(!(container && (istype(container, /obj/item/device/mmi) || istype(container, /obj/item/device/mmi/posibrain))))
return //No MMI, can't speak, bucko./N
+15 -9
View File
@@ -5,13 +5,13 @@
canmove = 0
icon = null
invisibility = 101
if(!(species.flags & IS_SYNTHETIC))
animation = new(loc)
animation.icon_state = "blank"
animation.icon = 'icons/mob/mob.dmi'
animation.master = src
animation = new(loc)
animation.icon_state = "blank"
animation.icon = 'icons/mob/mob.dmi'
animation.master = src
playsound(src.loc, 'sound/effects/gib.ogg', 100, 1, 10)
playsound(src.loc, 'sound/effects/gib.ogg', 100, 1, 10)
for(var/datum/organ/external/E in src.organs)
if(istype(E, /datum/organ/external/chest))
@@ -20,9 +20,15 @@
if(prob(100 - E.get_damage()))
// Override the current limb status and don't cause an explosion
E.droplimb(1,1)
flick("gibbed-h", animation)
hgibs(loc, viruses, dna)
if(!(species.flags & IS_SYNTHETIC))
flick("gibbed-h", animation)
hgibs(loc, viruses, dna)
else
new /obj/effect/decal/cleanable/robot_debris(src.loc)
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
s.set_up(3, 1, src)
s.start()
spawn(15)
if(animation) del(animation)
@@ -1672,6 +1672,9 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
proc/handle_decay()
var/decaytime = world.time - timeofdeath
if(species.flags & IS_SYNTHETIC)
return
if(decaytime <= 6000) //10 minutes for decaylevel1 -- stinky
return
+6
View File
@@ -633,6 +633,12 @@ obj/structure/cable/proc/cableColor(var/colorC)
if(istype(M,/mob/living/carbon/human))
var/mob/living/carbon/human/H = M
H.updatehealth()
if(istype(M,/mob/living/carbon/human/machine) && M.stat == 0) // If an IPC is brought back to life by welding it, which is possible, update the mob list
if(M in dead_mob_list)
dead_mob_list -= M
respawnable_list -= M
living_mob_list += M
mob_list += M
return
else
user << "Nothing to fix!"
@@ -251,6 +251,7 @@
icon_state = "virusfoodtank"
amount_per_transfer_from_this = 10
anchored = 1
density = 0
New()
..()
+10
View File
@@ -1579,6 +1579,16 @@ datum/design/adv_reagent_scanner
reliability_base = 74
build_path = "/obj/item/device/reagent_scanner/adv"
datum/design/cyborg_analyzer
name = "Cyborg Analyzer"
desc = "A hand-held scanner able to diagnose robotic injuries."
id = "cyborg_analyzer"
req_tech = list("programming" = 2, "biotech" = 2, "magnets" = 2)
build_type = PROTOLATHE
materials = list("$metal" = 30, "$glass" = 20)
reliability_base = 74
build_path = "/obj/item/device/robotanalyzer"
datum/design/mmi
name = "Man-Machine Interface"
desc = "The Warrior's bland acronym, MMI, obscures the true horror of this monstrosity."
@@ -44,6 +44,25 @@
/obj/structure/boulder/New()
icon_state = "boulder[rand(1,4)]"
excavation_level = rand(5,50)
/obj/structure/boulder/Bumped(AM)
. = ..()
if(istype(AM,/mob/living/carbon/human))
var/mob/living/carbon/human/H = AM
if((istype(H.l_hand,/obj/item/weapon/pickaxe)) && (!H.hand))
attackby(H.l_hand,H)
else if((istype(H.r_hand,/obj/item/weapon/pickaxe)) && H.hand)
attackby(H.r_hand,H)
else if(istype(AM,/mob/living/silicon/robot))
var/mob/living/silicon/robot/R = AM
if(istype(R.module_active,/obj/item/weapon/pickaxe))
attackby(R.module_active,R)
else if(istype(AM,/obj/mecha))
var/obj/mecha/M = AM
if(istype(M.selected,/obj/item/mecha_parts/mecha_equipment/tool/drill))
M.selected.action(src)
/obj/structure/boulder/attackby(obj/item/weapon/W as obj, mob/user as mob)
if (istype(W, /obj/item/device/core_sampler))
+2
View File
@@ -128,6 +128,8 @@
if (target.op_stage.face == 3)
var/datum/organ/external/head/h = affected
h.disfigured = 0
h.update_icon()
target.regenerate_icons()
target.op_stage.face = 0
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
+37 -12
View File
@@ -26,20 +26,28 @@
min_duration = 80
max_duration = 100
can_use(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
return ..() && !(affected.status & ORGAN_CUT_AWAY)
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("[user] starts peeling back tattered flesh where [target]'s head used to be with \the [tool].", \
"You start peeling back tattered flesh where [target]'s head used to be with \the [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("[user] starts peeling back tattered flesh where [target]'s head used to be with \the [tool].", \
"You start peeling back tattered flesh where [target]'s head used to be with \the [tool].")
else
user.visible_message("[user] starts peeling back metal where [target]'s head used to be with \the [tool].", \
"You start peeling back metal where [target]'s head used to be with \the [tool].")
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] peels back tattered flesh where [target]'s head used to be with \the [tool].", \
"\blue You peel back tattered flesh where [target]'s head used to be with \the [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("\blue [user] peels back tattered flesh where [target]'s head used to be with \the [tool].", \
"\blue You peel back tattered flesh where [target]'s head used to be with \the [tool].")
else
user.visible_message("\blue [user] peels back metal where [target]'s head used to be with \the [tool].", \
"\blue You peel back metal where [target]'s head used to be with \the [tool].")
affected.status |= ORGAN_CUT_AWAY
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
@@ -47,7 +55,7 @@
if (affected.parent)
affected = affected.parent
user.visible_message("\red [user]'s hand slips, ripping [target]'s [affected.display_name] open!", \
"\red Your hand slips, ripping [target]'s [affected.display_name] open!")
"\red Your hand slips, ripping [target]'s [affected.display_name] open!")
affected.createwound(CUT, 10)
@@ -72,16 +80,25 @@
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
user.visible_message("\blue [user] has finished repositioning flesh and tissue to something anatomically recognizable where [target]'s head used to be with \the [tool].", \
"\blue You have finished repositioning flesh and tissue to something anatomically recognizable where [target]'s head used to be with \the [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("\blue [user] has finished repositioning flesh and tissue to something anatomically recognizable where [target]'s head used to be with \the [tool].", \
"\blue You have finished repositioning flesh and tissue to something anatomically recognizable where [target]'s head used to be with \the [tool].")
else
user.visible_message("\blue [user] has finished repositioning metal to something recognizable where [target]'s head used to be with \the [tool].", \
"\blue You have finished repositioning metal to something anatomically recognizable where [target]'s head used to be with \the [tool].")
target.op_stage.head_reattach = 1
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
if (affected.parent)
affected = affected.parent
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("\red [user]'s hand slips, further rending flesh on [target]'s neck!", \
"\red Your hand slips, further rending flesh on [target]'s neck!")
else
user.visible_message("\red [user]'s hand slips, further rending metal on [target]'s neck!", \
"\red Your hand slips, further rending metal on [target]'s neck!")
target.apply_damage(10, BRUTE, affected)
/datum/surgery_step/head/suture
@@ -99,8 +116,12 @@
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
// var/datum/organ/external/affected = target.get_organ(target_zone)
user.visible_message("[user] is stapling and suturing flesh into place in [target]'s esophagal and vocal region with \the [tool].", \
"You start to staple and suture flesh into place in [target]'s esophagal and vocal region with \the [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("[user] is stapling and suturing flesh into place in [target]'s esophagal and vocal region with \the [tool].", \
"You start to staple and suture flesh into place in [target]'s esophagal and vocal region with \the [tool].")
else
user.visible_message("[user] is stapling and suturing metal into place in [target]'s esophagal and vocal region with \the [tool].", \
"You start to staple and suture metal into place in [target]'s esophagal and vocal region with \the [tool].")
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
@@ -175,15 +196,19 @@
user.visible_message("\blue [user] has attached [target]'s head to the body.", \
"\blue You have attached [target]'s head to the body.")
affected.status = 0
if(istype(target,/mob/living/carbon/human/machine))
affected.status = 128
affected.amputated = 0
affected.destspawn = 0
var/obj/item/weapon/organ/head/B = tool
if (B.brainmob.mind)
B.brainmob.mind.transfer_to(target)
affected.setAmputatedTree()
target.handle_organs()
target.update_body()
target.updatehealth()
target.UpdateDamageIcon()
target.regenerate_icons()
target.updatehealth()
del(B)
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
+32 -12
View File
@@ -37,14 +37,22 @@
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
user.visible_message("[user] starts cutting away flesh where [target]'s [affected.display_name] used to be with \the [tool].", \
"You start cutting away flesh where [target]'s [affected.display_name] used to be with \the [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("[user] starts cutting away flesh where [target]'s [affected.display_name] used to be with \the [tool].", \
"You start cutting away flesh where [target]'s [affected.display_name] used to be with \the [tool].")
else
user.visible_message("[user] starts cutting away metal where [target]'s [affected.display_name] used to be with \the [tool].", \
"You start cutting away metal where [target]'s [affected.display_name] used to be with \the [tool].")
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] cuts away flesh where [target]'s [affected.display_name] used to be with \the [tool].", \
"\blue You cut away flesh where [target]'s [affected.display_name] used to be with \the [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("\blue [user] cuts away flesh where [target]'s [affected.display_name] used to be with \the [tool].", \
"\blue You cut away flesh where [target]'s [affected.display_name] used to be with \the [tool].")
else
user.visible_message("\blue [user] cuts away metal where [target]'s [affected.display_name] used to be with \the [tool].", \
"\blue You cut away metal where [target]'s [affected.display_name] used to be with \the [tool].")
affected.status |= ORGAN_CUT_AWAY
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
@@ -52,7 +60,7 @@
if (affected.parent)
affected = affected.parent
user.visible_message("\red [user]'s hand slips, cutting [target]'s [affected.display_name] open!", \
"\red Your hand slips, cutting [target]'s [affected.display_name] open!")
"\red Your hand slips, cutting [target]'s [affected.display_name] open!")
affected.createwound(CUT, 10)
@@ -71,22 +79,34 @@
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
user.visible_message("[user] is beginning reposition flesh and nerve endings where where [target]'s [affected.display_name] used to be with [tool].", \
"You start repositioning flesh and nerve endings where where [target]'s [affected.display_name] used to be with [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("[user] is beginning to reposition flesh and nerve endings where where [target]'s [affected.display_name] used to be with [tool].", \
"You start repositioning flesh and nerve endings where where [target]'s [affected.display_name] used to be with [tool].")
else
user.visible_message("[user] is beginning to reposition metal and wire endings where where [target]'s [affected.display_name] used to be with [tool].", \
"You start repositioning metal and wire endings where where [target]'s [affected.display_name] used to be with [tool].")
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
user.visible_message("\blue [user] has finished repositioning flesh and nerve endings where [target]'s [affected.display_name] used to be with [tool].", \
"\blue You have finished repositioning flesh and nerve endings where [target]'s [affected.display_name] used to be with [tool].")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("\blue [user] has finished repositioning flesh and nerve endings where [target]'s [affected.display_name] used to be with [tool].", \
"\blue You have finished repositioning flesh and nerve endings where [target]'s [affected.display_name] used to be with [tool].")
else
user.visible_message("\blue [user] has finished repositioning metal and wire endings where [target]'s [affected.display_name] used to be with [tool].", \
"\blue You have finished repositioning metal and wire endings where [target]'s [affected.display_name] used to be with [tool].")
affected.open = 3
fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
if (affected.parent)
affected = affected.parent
user.visible_message("\red [user]'s hand slips, tearing flesh on [target]'s [affected.display_name]!", \
"\red Your hand slips, tearing flesh on [target]'s [affected.display_name]!")
if(!(target.species.flags & IS_SYNTHETIC))
user.visible_message("\red [user]'s hand slips, tearing flesh on [target]'s [affected.display_name]!", \
"\red Your hand slips, tearing flesh on [target]'s [affected.display_name]!")
else
user.visible_message("\red [user]'s hand slips, tearing metal on [target]'s [affected.display_name]!", \
"\red Your hand slips, tearing metal on [target]'s [affected.display_name]!")
target.apply_damage(10, BRUTE, affected, sharp=1)
@@ -108,7 +128,7 @@
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)
user.visible_message("[user] starts adjusting area around [target]'s [affected.display_name] with \the [tool].", \
"You start adjusting area around [target]'s [affected.display_name] with \the [tool]..")
"You start adjusting area around [target]'s [affected.display_name] with \the [tool].")
..()
end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)