diff --git a/code/WorkInProgress/computer3/component.dm b/code/WorkInProgress/computer3/component.dm
index 501bbc973eb..d5f290b1770 100644
--- a/code/WorkInProgress/computer3/component.dm
+++ b/code/WorkInProgress/computer3/component.dm
@@ -192,9 +192,12 @@
if(reader)
reader.loc = loc
if(istype(L) && !L.get_active_hand())
- L.put_in_hands(reader)
+ if(istype(L,/mob/living/carbon/human))
+ L.put_in_hands(reader)
+ else
+ reader.loc = get_turf(computer)
else
- reader.loc = computer.loc
+ reader.loc = get_turf(computer)
reader = null
return 1
return 0
@@ -203,16 +206,16 @@
if(writer && dualslot)
writer.loc = loc
if(istype(L) && !L.get_active_hand())
- L.put_in_hands(writer)
+ if(istype(L,/mob/living/carbon/human))
+ L.put_in_hands(writer)
+ else
+ writer.loc = get_turf(computer)
else
- writer.loc = computer.loc
+ writer.loc = get_turf(computer)
writer = null
return 1
return 0
-
-
-
// Authorizes the user based on the computer's requirements
proc/authenticate()
return computer.check_access(reader)
diff --git a/code/datums/datumvars.dm b/code/datums/datumvars.dm
index a51ac42ee25..20f67c6e33b 100644
--- a/code/datums/datumvars.dm
+++ b/code/datums/datumvars.dm
@@ -794,6 +794,9 @@ client
var/new_language = input("Please choose a language to add.","Language",null) as null|anything in all_languages
+ if(!new_language)
+ return
+
if(!H)
usr << "Mob doesn't exist anymore"
return
@@ -817,6 +820,9 @@ client
var/datum/language/rem_language = input("Please choose a language to remove.","Language",null) as null|anything in H.languages
+ if(!rem_language)
+ return
+
if(!H)
usr << "Mob doesn't exist anymore"
return
diff --git a/code/game/gamemodes/changeling/changeling_powers.dm b/code/game/gamemodes/changeling/changeling_powers.dm
index 0309eccee0b..d353c77ad06 100644
--- a/code/game/gamemodes/changeling/changeling_powers.dm
+++ b/code/game/gamemodes/changeling/changeling_powers.dm
@@ -457,7 +457,7 @@
changeling.chem_charges -= 20
// restore us to health
- C.rejuvenate()
+ C.revive()
// remove our fake death flag
C.status_flags &= ~(FAKEDEATH)
diff --git a/code/game/machinery/computer/card.dm b/code/game/machinery/computer/card.dm
index 9341aca674f..a3fa74173a8 100644
--- a/code/game/machinery/computer/card.dm
+++ b/code/game/machinery/computer/card.dm
@@ -40,13 +40,13 @@
if(scan)
usr << "You remove \the [scan] from \the [src]."
scan.loc = get_turf(src)
- if(!usr.get_active_hand())
+ if(!usr.get_active_hand() && istype(usr,/mob/living/carbon/human))
usr.put_in_hands(scan)
scan = null
else if(modify)
usr << "You remove \the [modify] from \the [src]."
modify.loc = get_turf(src)
- if(!usr.get_active_hand())
+ if(!usr.get_active_hand() && istype(usr,/mob/living/carbon/human))
usr.put_in_hands(modify)
modify = null
else
diff --git a/code/game/machinery/computer/medical.dm b/code/game/machinery/computer/medical.dm
index 6d347224f2f..1086055fd89 100644
--- a/code/game/machinery/computer/medical.dm
+++ b/code/game/machinery/computer/medical.dm
@@ -26,7 +26,7 @@
if(scan)
usr << "You remove \the [scan] from \the [src]."
scan.loc = get_turf(src)
- if(!usr.get_active_hand())
+ if(!usr.get_active_hand() && istype(usr,/mob/living/carbon/human))
usr.put_in_hands(scan)
scan = null
else
diff --git a/code/game/machinery/computer/security.dm b/code/game/machinery/computer/security.dm
index af720b8c195..ba0ff29e9c9 100644
--- a/code/game/machinery/computer/security.dm
+++ b/code/game/machinery/computer/security.dm
@@ -32,7 +32,7 @@
if(scan)
usr << "You remove \the [scan] from \the [src]."
scan.loc = get_turf(src)
- if(!usr.get_active_hand())
+ if(!usr.get_active_hand() && istype(usr,/mob/living/carbon/human))
usr.put_in_hands(scan)
scan = null
else
diff --git a/code/game/objects/items/devices/paicard.dm b/code/game/objects/items/devices/paicard.dm
index 42651ea7200..94e9b2ffd0c 100644
--- a/code/game/objects/items/devices/paicard.dm
+++ b/code/game/objects/items/devices/paicard.dm
@@ -302,4 +302,10 @@
/obj/item/device/paicard/emp_act(severity)
for(var/mob/M in src)
M.emp_act(severity)
- ..()
\ No newline at end of file
+ ..()
+
+/obj/item/device/paicard/ex_act(severity)
+ if(pai)
+ pai.ex_act(severity)
+ else
+ del(src)
\ No newline at end of file
diff --git a/code/game/objects/structures/stool_bed_chair_nest/alien_nests.dm b/code/game/objects/structures/stool_bed_chair_nest/alien_nests.dm
index 3c5bbfc1ca2..231ae772c02 100644
--- a/code/game/objects/structures/stool_bed_chair_nest/alien_nests.dm
+++ b/code/game/objects/structures/stool_bed_chair_nest/alien_nests.dm
@@ -1,4 +1,5 @@
//Alium nests. Essentially beds with an unbuckle delay that only aliums can buckle mobs to.
+#define NEST_RESIST_TIME 1200
/obj/structure/stool/bed/nest
name = "alien nest"
@@ -19,12 +20,16 @@
buckled_mob.old_y = 0
unbuckle()
else
+ if(world.time <= buckled_mob.last_special+NEST_RESIST_TIME)
+ return
+ buckled_mob.last_special = world.time
buckled_mob.visible_message(\
"[buckled_mob.name] struggles to break free of the gelatinous resin...",\
"You struggle to break free from the gelatinous resin...",\
"You hear squelching...")
- spawn(1200)
+ spawn(NEST_RESIST_TIME)
if(user && buckled_mob && user.buckled == src)
+ buckled_mob.last_special = world.time
buckled_mob.pixel_y = 0
buckled_mob.old_y = 0
unbuckle()
diff --git a/code/game/objects/structures/window.dm b/code/game/objects/structures/window.dm
index 710edd42055..ff6dfb93e6b 100644
--- a/code/game/objects/structures/window.dm
+++ b/code/game/objects/structures/window.dm
@@ -169,31 +169,32 @@
/obj/structure/window/attackby(obj/item/W as obj, mob/user as mob)
if(!istype(W)) return//I really wish I did not need this
- if(W.flags & NOBLUDGEON) return
-
if (istype(W, /obj/item/weapon/grab) && get_dist(src,user)<2)
var/obj/item/weapon/grab/G = W
- if (istype(G.affecting, /mob/living))
+ if(istype(G.affecting,/mob/living))
var/mob/living/M = G.affecting
var/state = G.state
del(W) //gotta delete it here because if window breaks, it won't get deleted
switch (state)
if(1)
+ M.visible_message("[user] slams [M] against \the [src]!")
M.apply_damage(7)
hit(10)
- visible_message("\red [user] slams [M] against \the [src]!")
if(2)
+ M.visible_message("[user] bashes [M] against \the [src]!")
if (prob(50))
M.Weaken(1)
M.apply_damage(10)
hit(25)
- visible_message("\red [user] bashes [M] against \the [src]!")
if(3)
+ M.visible_message("[user] crushes [M] against \the [src]!")
M.Weaken(5)
M.apply_damage(20)
hit(50)
- visible_message("\red [user] crushes [M] against \the [src]!")
return
+
+ if(W.flags & NOBLUDGEON) return
+
if(istype(W, /obj/item/weapon/screwdriver))
if(reinf && state >= 1)
state = 3 - state
@@ -299,7 +300,7 @@
//player-constructed windows
if (constructed)
anchored = 0
-
+
if (start_dir)
dir = start_dir
diff --git a/code/modules/hydroponics/hydro_tray.dm b/code/modules/hydroponics/hydro_tray.dm
index ba5f4dbc310..75169cd30cc 100644
--- a/code/modules/hydroponics/hydro_tray.dm
+++ b/code/modules/hydroponics/hydro_tray.dm
@@ -129,8 +129,6 @@
create_reagents(200)
connect()
update_icon()
- if(closed_system)
- flags &= ~OPENCONTAINER
/obj/machinery/portable_atmospherics/hydroponics/bullet_act(var/obj/item/projectile/Proj)
@@ -777,11 +775,6 @@
closed_system = !closed_system
usr << "You [closed_system ? "close" : "open"] the tray's lid."
- if(closed_system)
- flags &= ~OPENCONTAINER
- else
- flags |= OPENCONTAINER
-
update_icon()
/obj/machinery/portable_atmospherics/hydroponics/soil
diff --git a/code/modules/mob/death.dm b/code/modules/mob/death.dm
index dc1ca257276..ab9c64eebfe 100644
--- a/code/modules/mob/death.dm
+++ b/code/modules/mob/death.dm
@@ -1,31 +1,31 @@
//This is the proc for gibbing a mob. Cannot gib ghosts.
//added different sort of gibs and animations. N
-/mob/proc/gib()
+/mob/proc/gib(anim="gibbed-m",do_gibs)
death(1)
- var/atom/movable/overlay/animation = null
monkeyizing = 1
canmove = 0
icon = null
invisibility = 101
+ update_canmove()
+ dead_mob_list -= src
+ var/atom/movable/overlay/animation = null
animation = new(loc)
animation.icon_state = "blank"
animation.icon = 'icons/mob/mob.dmi'
animation.master = src
-// flick("gibbed-m", animation)
- gibs(loc, viruses, dna)
+ flick(anim, animation)
+ if(do_gibs) gibs(loc, viruses, dna)
- dead_mob_list -= src
spawn(15)
if(animation) del(animation)
if(src) del(src)
-
//This is the proc for turning a mob into ash. Mostly a copy of gib code (above).
//Originally created for wizard disintegrate. I've removed the virus code since it's irrelevant here.
//Dusting robots does not eject the MMI, so it's a bit more powerful than gib() /N
-/mob/proc/dust()
+/mob/proc/dust(anim="dust-m",remains=/obj/effect/decal/cleanable/ash)
death(1)
var/atom/movable/overlay/animation = null
monkeyizing = 1
@@ -38,8 +38,8 @@
animation.icon = 'icons/mob/mob.dmi'
animation.master = src
-// flick("dust-m", animation)
- new /obj/effect/decal/cleanable/ash(loc)
+ flick(anim, animation)
+ new remains(loc)
dead_mob_list -= src
spawn(15)
@@ -47,17 +47,45 @@
if(src) del(src)
-/mob/proc/death(gibbed)
+/mob/proc/death(gibbed,deathmessage="seizes up and falls limp...")
+
+ if(stat == DEAD)
+ return 0
+
+ if(!gibbed)
+ src.visible_message("\The [src.name] [deathmessage]")
+
+ stat = DEAD
+
+ update_canmove()
+
+ dizziness = 0
+ jitteriness = 0
+
+ layer = MOB_LAYER
+
+ if(blind && client)
+ blind.layer = 0
+
+ sight |= SEE_TURFS|SEE_MOBS|SEE_OBJS
+ see_in_dark = 8
+ see_invisible = SEE_INVISIBLE_LEVEL_TWO
- //Quick fix for corpses kept propped up in chairs. ~Z
drop_r_hand()
drop_l_hand()
- //End of fix.
+
+ if(healths)
+ healths.icon_state = "health6"
timeofdeath = world.time
-
- var/tod = worldtime2text() //weasellos time of death patch
- if(mind) mind.store_memory("Time of death: [tod]", 0)
+ if(mind) mind.store_memory("Time of death: [worldtime2text()]", 0)
living_mob_list -= src
- dead_mob_list += src
- return ..(gibbed)
+ dead_mob_list |= src
+
+ updateicon()
+
+ if(ticker && ticker.mode)
+ ticker.mode.check_win()
+
+
+ return 1
diff --git a/code/modules/mob/living/blob/blob.dm b/code/modules/mob/living/blob/blob.dm
index ec90c4fb7ff..2b82ccbedbf 100644
--- a/code/modules/mob/living/blob/blob.dm
+++ b/code/modules/mob/living/blob/blob.dm
@@ -52,14 +52,8 @@
death(gibbed)
- if(key)
- var/mob/dead/observer/ghost = new(src)
- ghost.name = ghost_name
- ghost.real_name = ghost_name
- ghost.key = key
- if (ghost.client)
- ghost.client.eye = ghost
- return ..(gibbed)
+ ghostize()
+ ..(gibbed)
blob_act()
diff --git a/code/modules/mob/living/carbon/alien/death.dm b/code/modules/mob/living/carbon/alien/death.dm
index 7dfd2cc0ebc..3c561652137 100644
--- a/code/modules/mob/living/carbon/alien/death.dm
+++ b/code/modules/mob/living/carbon/alien/death.dm
@@ -1,13 +1,4 @@
/mob/living/carbon/alien/death(gibbed)
-
- if(stat == DEAD) return
- if(healths) healths.icon_state = "health6"
- stat = DEAD
-
- if(dead_icon) icon_state = dead_icon
-
- if(!gibbed)
- update_canmove()
- if(client) blind.layer = 0
-
- return ..(gibbed)
\ No newline at end of file
+ if(!gibbed && dead_icon)
+ icon_state = dead_icon
+ return ..(gibbed,"lets out a waning guttural screech, green blood bubbling from its maw.")
\ No newline at end of file
diff --git a/code/modules/mob/living/carbon/alien/emote.dm b/code/modules/mob/living/carbon/alien/emote.dm
index 0efcae7c911..b3b0ae53c18 100644
--- a/code/modules/mob/living/carbon/alien/emote.dm
+++ b/code/modules/mob/living/carbon/alien/emote.dm
@@ -36,6 +36,9 @@
if (!muzzled)
message = "[src] burps."
m_type = 2
+ if("deathgasp")
+ message = "The [src.name] lets out a waning guttural screech, green blood bubbling from its maw."
+ m_type = 2
if("scratch")
if (!src.restrained())
message = "The [src.name] scratches."
diff --git a/code/modules/mob/living/carbon/brain/death.dm b/code/modules/mob/living/carbon/brain/death.dm
index 897b03c8a14..ecb729ece90 100644
--- a/code/modules/mob/living/carbon/brain/death.dm
+++ b/code/modules/mob/living/carbon/brain/death.dm
@@ -1,43 +1,12 @@
/mob/living/carbon/brain/death(gibbed)
- if(stat == DEAD) return
- if(!gibbed && container && istype(container, /obj/item/device/mmi))//If not gibbed but in a container.
- for(var/mob/O in viewers(container, null))
- O.show_message(text("\red []'s MMI flatlines!", src), 1, "\red You hear something flatline.", 2)
+ if(!gibbed && istype(container, /obj/item/device/mmi)) //If not gibbed but in a container.
container.icon_state = "mmi_dead"
- stat = DEAD
-
- if(blind) blind.layer = 0
- sight |= SEE_TURFS|SEE_MOBS|SEE_OBJS
- see_in_dark = 8
- see_invisible = SEE_INVISIBLE_LEVEL_TWO
-
- tod = worldtime2text() //weasellos time of death patch
- if(mind) mind.store_memory("Time of death: [tod]", 0) //mind. ?
-
- return ..(gibbed)
+ return ..(gibbed,"beeps shrilly as the MMI flatlines!")
/mob/living/carbon/brain/gib()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
-// flick("gibbed-m", animation)
- gibs(loc, viruses, dna)
-
- dead_mob_list -= src
- if(container && istype(container, /obj/item/device/mmi))
+ if(istype(container, /obj/item/device/mmi))
del(container)//Gets rid of the MMI if there is one
if(loc)
if(istype(loc,/obj/item/organ/brain))
del(loc)//Gets rid of the brain item
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
\ No newline at end of file
+ ..(null,1)
\ No newline at end of file
diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm
index 03dd42b0310..37da1745d28 100644
--- a/code/modules/mob/living/carbon/carbon.dm
+++ b/code/modules/mob/living/carbon/carbon.dm
@@ -57,7 +57,7 @@
for(var/mob/N in viewers(src, null))
if(N.client)
N.show_message(text("\red [M] bursts out of [src]!"), 2)
- . = ..()
+ . = ..(null,1)
/mob/living/carbon/attack_hand(mob/M as mob)
if(!istype(M, /mob/living/carbon)) return
diff --git a/code/modules/mob/living/carbon/human/death.dm b/code/modules/mob/living/carbon/human/death.dm
index f97397fe4cd..fea5366a7f5 100644
--- a/code/modules/mob/living/carbon/human/death.dm
+++ b/code/modules/mob/living/carbon/human/death.dm
@@ -1,15 +1,4 @@
/mob/living/carbon/human/gib()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
for(var/datum/organ/external/E in src.organs)
if(istype(E, /datum/organ/external/chest))
@@ -19,49 +8,25 @@
// Override the current limb status and don't cause an explosion
E.droplimb(1,1)
+ ..(species ? species.gibbed_anim : "gibbed-h")
+
if(species)
- flick(species.gibbed_anim, animation)
hgibs(loc, viruses, dna, species.flesh_color, species.blood_color)
else
- flick("gibbed-h", animation)
hgibs(loc, viruses, dna)
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
-
/mob/living/carbon/human/dust()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
- flick(species.dusted_anim, animation)
- new species.remains_type(loc)
-
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
-
+ if(species)
+ ..(species.dusted_anim, species.remains_type)
+ else
+ ..()
/mob/living/carbon/human/death(gibbed)
- if(stat == DEAD) return
- if(healths) healths.icon_state = "health5"
- stat = DEAD
- dizziness = 0
- jitteriness = 0
+ if(stat == DEAD) return
hud_updateflag |= 1 << HEALTH_HUD
hud_updateflag |= 1 << STATUS_HUD
-
handle_hud_list()
//Handle species-specific deaths.
@@ -88,36 +53,16 @@
callHook("death", list(src, gibbed))
- //Check for heist mode kill count.
- if(ticker.mode && ( istype( ticker.mode,/datum/game_mode/heist) ) )
- //Check for last assailant's mutantrace.
- /*if( LAssailant && ( istype( LAssailant,/mob/living/carbon/human ) ) )
- var/mob/living/carbon/human/V = LAssailant
- if (V.dna && (V.dna.mutantrace == "vox"))*/ //Not currently feasible due to terrible LAssailant tracking.
- //world << "Vox kills: [vox_kills]"
- vox_kills++ //Bad vox. Shouldn't be killing humans.
+ if(!gibbed && species.death_sound)
+ playsound(loc, species.death_sound, 80, 1, 1)
- if(!gibbed)
-
- emote("deathgasp") //let the world KNOW WE ARE DEAD // Doing this with the deathgasp emote seems odd.
- if(species && species.death_sound) playsound(loc, species.death_sound, 80, 1, 1)
-
- //For ninjas exploding when they die.
- if( istype(wear_suit, /obj/item/clothing/suit/space/space_ninja) && wear_suit:s_initialized )
- src << browse(null, "window=spideros")//Just in case.
- var/location = loc
- explosion(location, 0, 0, 3, 4)
-
- update_canmove()
- if(client) blind.layer = 0
-
- tod = worldtime2text() //weasellos time of death patch
- if(mind) mind.store_memory("Time of death: [tod]", 0)
if(ticker && ticker.mode)
-// world.log << "k"
sql_report_death(src)
- ticker.mode.check_win() //Calls the rounds wincheck, mainly for wizard, malf, and changeling now
- return ..(gibbed)
+ ticker.mode.check_win()
+ if(istype(ticker.mode,/datum/game_mode/heist))
+ vox_kills++ //Bad vox. Shouldn't be killing humans.
+
+ return ..(gibbed,species.death_message)
/mob/living/carbon/human/proc/makeSkeleton()
if(SKELETON in src.mutations) return
diff --git a/code/modules/mob/living/carbon/metroid/death.dm b/code/modules/mob/living/carbon/metroid/death.dm
index b8e004e2016..2ebc5c576b5 100644
--- a/code/modules/mob/living/carbon/metroid/death.dm
+++ b/code/modules/mob/living/carbon/metroid/death.dm
@@ -1,4 +1,8 @@
/mob/living/carbon/slime/death(gibbed)
+
+ if(stat == DEAD) return
+ stat = DEAD
+
if(!gibbed)
if(is_adult)
var/mob/living/carbon/slime/M = new /mob/living/carbon/slime(loc)
@@ -12,17 +16,7 @@
name = "[colour] [is_adult ? "adult" : "baby"] slime ([number])"
return
- if(stat == DEAD) return
- stat = DEAD
icon_state = "[colour] baby slime dead"
- overlays.len = 0
- for(var/mob/O in viewers(src, null))
- O.show_message("The [name] seizes up and falls limp...", 1) //ded -- Urist
-
- update_canmove()
- if(blind) blind.layer = 0
-
- if(ticker && ticker.mode)
- ticker.mode.check_win()
+ overlays.Cut()
return ..(gibbed)
\ No newline at end of file
diff --git a/code/modules/mob/living/carbon/monkey/death.dm b/code/modules/mob/living/carbon/monkey/death.dm
index 8e982eb9356..6d0c48c804c 100644
--- a/code/modules/mob/living/carbon/monkey/death.dm
+++ b/code/modules/mob/living/carbon/monkey/death.dm
@@ -1,56 +1,8 @@
/mob/living/carbon/monkey/gib()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
- flick("gibbed-m", animation)
- gibs(loc, viruses, dna)
-
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
+ ..(null,1)
/mob/living/carbon/monkey/dust()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
- flick("dust-m", animation)
- new /obj/effect/decal/cleanable/ash(loc)
-
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
-
+ ..("dust-m")
/mob/living/carbon/monkey/death(gibbed)
- if(stat == DEAD) return
- if(healths) healths.icon_state = "health5"
- stat = DEAD
-
- if(!gibbed)
- for(var/mob/O in viewers(src, null))
- O.show_message("The [name] lets out a faint chimper as it collapses and stops moving...", 1) //ded -- Urist
-
- update_canmove()
- if(blind) blind.layer = 0
-
- ticker.mode.check_win()
-
- return ..(gibbed)
\ No newline at end of file
+ ..(gibbed,"lets out a faint chimper as it collapses and stops moving...")
\ No newline at end of file
diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm
index aaf82a90c3b..1919cf8b627 100644
--- a/code/modules/mob/living/silicon/ai/ai.dm
+++ b/code/modules/mob/living/silicon/ai/ai.dm
@@ -385,13 +385,6 @@ var/list/ai_verbs_default = list(
user.reset_view(camera)
return 1
-/mob/living/silicon/ai/blob_act()
- if (stat != 2)
- adjustBruteLoss(60)
- updatehealth()
- return 1
- return 0
-
/mob/living/silicon/ai/restrained()
return 0
@@ -404,26 +397,6 @@ var/list/ai_verbs_default = list(
ai_call_shuttle()
..()
-/mob/living/silicon/ai/ex_act(severity)
- if(!blinded)
- flick("flash", flash)
-
- switch(severity)
- if(1.0)
- if (stat != 2)
- adjustBruteLoss(100)
- adjustFireLoss(100)
- if(2.0)
- if (stat != 2)
- adjustBruteLoss(60)
- adjustFireLoss(60)
- if(3.0)
- if (stat != 2)
- adjustBruteLoss(30)
-
- updatehealth()
-
-
/mob/living/silicon/ai/Topic(href, href_list)
if(usr != src)
return
@@ -481,7 +454,7 @@ var/list/ai_verbs_default = list(
else
src << "\red System error. Cannot locate [html_decode(href_list["trackname"])]."
return
-
+
return
/mob/living/silicon/ai/meteorhit(obj/O as obj)
@@ -495,11 +468,6 @@ var/list/ai_verbs_default = list(
updatehealth()
return
-/mob/living/silicon/ai/bullet_act(var/obj/item/projectile/Proj)
- ..(Proj)
- updatehealth()
- return 2
-
/mob/living/silicon/ai/attack_animal(mob/living/M as mob)
if(M.melee_damage_upper == 0)
M.emote("[M.friendly] [src]")
diff --git a/code/modules/mob/living/silicon/ai/death.dm b/code/modules/mob/living/silicon/ai/death.dm
index f2cd262f4c3..456940bc252 100644
--- a/code/modules/mob/living/silicon/ai/death.dm
+++ b/code/modules/mob/living/silicon/ai/death.dm
@@ -1,20 +1,19 @@
/mob/living/silicon/ai/death(gibbed)
- if(stat == DEAD) return
- stat = DEAD
+
+ if(stat == DEAD)
+ return
+
if (src.custom_sprite == 1)//check for custom AI sprite, defaulting to blue screen if no.
icon_state = "[ckey]-ai-crash"
- else icon_state = "ai-crash"
- update_canmove()
+ else
+ icon_state = "ai-crash"
+
if(src.eyeobj)
src.eyeobj.setLoc(get_turf(src))
- if(blind) blind.layer = 0
- sight |= SEE_TURFS|SEE_MOBS|SEE_OBJS
- see_in_dark = 8
- see_invisible = SEE_INVISIBLE_LEVEL_TWO
+
remove_ai_verbs(src)
var/callshuttle = 0
-
for(var/obj/machinery/computer/communications/commconsole in world)
if(commconsole.z == 2)
continue
@@ -48,13 +47,10 @@
spawn(10)
explosion(src.loc, 3, 6, 12, 15)
- for(var/obj/machinery/ai_status_display/O in world) //change status
+ for(var/obj/machinery/ai_status_display/O in world)
spawn( 0 )
O.mode = 2
if (istype(loc, /obj/item/device/aicard))
loc.icon_state = "aicard-404"
- tod = worldtime2text() //weasellos time of death patch
- if(mind) mind.store_memory("Time of death: [tod]", 0)
-
return ..(gibbed)
diff --git a/code/modules/mob/living/silicon/death.dm b/code/modules/mob/living/silicon/death.dm
index 45b0268437d..2b56af75378 100644
--- a/code/modules/mob/living/silicon/death.dm
+++ b/code/modules/mob/living/silicon/death.dm
@@ -1,41 +1,12 @@
/mob/living/silicon/gib()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
-// flick("gibbed-r", animation)
+ ..("gibbed-r")
robogibs(loc, viruses)
- dead_mob_list -= src
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
-
/mob/living/silicon/dust()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
+ ..("dust-r", /obj/effect/decal/remains/robot)
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
-// flick("dust-r", animation)
- new /obj/effect/decal/remains/robot(loc)
-
- dead_mob_list -= src
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
+/mob/living/silicon/death(gibbed,deathmessage)
+ if(in_contents_of(/obj/machinery/recharge_station))//exit the recharge station
+ var/obj/machinery/recharge_station/RC = loc
+ RC.go_out()
+ return ..(gibbed,deathmessage)
\ No newline at end of file
diff --git a/code/modules/mob/living/silicon/decoy/death.dm b/code/modules/mob/living/silicon/decoy/death.dm
index d3996e2fa70..b94a311ef7a 100644
--- a/code/modules/mob/living/silicon/decoy/death.dm
+++ b/code/modules/mob/living/silicon/decoy/death.dm
@@ -1,10 +1,8 @@
/mob/living/silicon/decoy/death(gibbed)
if(stat == DEAD) return
- stat = DEAD
icon_state = "ai-crash"
spawn(10)
explosion(loc, 3, 6, 12, 15)
-
for(var/obj/machinery/ai_status_display/O in world) //change status
O.mode = 2
return ..(gibbed)
\ No newline at end of file
diff --git a/code/modules/mob/living/silicon/pai/death.dm b/code/modules/mob/living/silicon/pai/death.dm
index 127091a854c..87e70393d0f 100644
--- a/code/modules/mob/living/silicon/pai/death.dm
+++ b/code/modules/mob/living/silicon/pai/death.dm
@@ -1,18 +1,13 @@
/mob/living/silicon/pai/death(gibbed)
- if(stat == DEAD) return
- stat = DEAD
- canmove = 0
- if(blind) blind.layer = 0
- sight |= SEE_TURFS|SEE_MOBS|SEE_OBJS
- see_in_dark = 8
- see_invisible = SEE_INVISIBLE_LEVEL_TWO
-
- //var/tod = time2text(world.realtime,"hh:mm:ss") //weasellos time of death patch
- //mind.store_memory("Time of death: [tod]", 0)
-
- //New pAI's get a brand new mind to prevent meta stuff from their previous life. This new mind causes problems down the line if it's not deleted here.
- //Read as: I have no idea what I'm doing but asking for help got me nowhere so this is what you get. - Nodrak
- if(mind) del(mind)
- living_mob_list -= src
+ if(card)
+ card.removePersonality()
+ if(gibbed)
+ src.loc = get_turf(card)
+ del(card)
+ else
+ close_up()
+ if(mind)
+ del(mind)
+ ..(gibbed)
ghostize()
del(src)
\ No newline at end of file
diff --git a/code/modules/mob/living/silicon/pai/life.dm b/code/modules/mob/living/silicon/pai/life.dm
index 423287f60c1..6c099af932a 100644
--- a/code/modules/mob/living/silicon/pai/life.dm
+++ b/code/modules/mob/living/silicon/pai/life.dm
@@ -1,6 +1,8 @@
/mob/living/silicon/pai/Life()
+
if (src.stat == 2)
return
+
if(src.cable)
if(get_dist(src, src.cable) > 1)
var/turf/T = get_turf_or_move(src.loc)
@@ -9,20 +11,26 @@
del(src.cable)
regular_hud_updates()
+
if(src.secHUD == 1)
process_sec_hud(src, 1)
+
if(src.medHUD == 1)
process_med_hud(src, 1)
+
if(silence_time)
if(world.timeofday >= silence_time)
silence_time = null
src << "Communication circuit reinitialized. Speech and messaging functionality restored."
+
handle_statuses()
+ if(health <= 0)
+ death(null,"gives one shrill beep before falling lifeless.")
+
/mob/living/silicon/pai/updatehealth()
if(status_flags & GODMODE)
health = 100
stat = CONSCIOUS
else
- health = 100 - getBruteLoss() - getFireLoss()
-
+ health = 100 - getBruteLoss() - getFireLoss()
\ No newline at end of file
diff --git a/code/modules/mob/living/silicon/pai/pai.dm b/code/modules/mob/living/silicon/pai/pai.dm
index 90336528c6c..556dbd0014d 100755
--- a/code/modules/mob/living/silicon/pai/pai.dm
+++ b/code/modules/mob/living/silicon/pai/pai.dm
@@ -169,28 +169,7 @@
if(3)
src << "You feel an electric surge run through your circuitry and become acutely aware at how lucky you are that you can still feel at all."
-/mob/living/silicon/pai/ex_act(severity)
- if(!blinded)
- flick("flash", src.flash)
-
- switch(severity)
- if(1.0)
- if (src.stat != 2)
- adjustBruteLoss(100)
- adjustFireLoss(100)
- if(2.0)
- if (src.stat != 2)
- adjustBruteLoss(60)
- adjustFireLoss(60)
- if(3.0)
- if (src.stat != 2)
- adjustBruteLoss(30)
-
- src.updatehealth()
-
-
// See software.dm for Topic()
-
/mob/living/silicon/pai/meteorhit(obj/O as obj)
for(var/mob/M in viewers(src, null))
M.show_message(text("\red [] has been hit by []", src, O), 1)
@@ -201,10 +180,6 @@
src.updatehealth()
return
-//mob/living/silicon/pai/bullet_act(var/obj/item/projectile/Proj)
-
-///mob/living/silicon/pai/attack_hand(mob/living/carbon/M as mob)
-
/mob/living/silicon/pai/proc/switchCamera(var/obj/machinery/camera/C)
if(istype(usr, /mob/living))
var/mob/living/U = usr
@@ -374,7 +349,8 @@
src.updatehealth()
else
visible_message("[user.name] bonks [src] harmlessly with [W].")
- if(stat != 2) close_up()
+ spawn(1)
+ if(stat != 2) close_up()
return
/mob/living/silicon/pai/attack_hand(mob/user as mob)
diff --git a/code/modules/mob/living/silicon/robot/death.dm b/code/modules/mob/living/silicon/robot/death.dm
index b16efbc34f7..ca3c80d3a74 100644
--- a/code/modules/mob/living/silicon/robot/death.dm
+++ b/code/modules/mob/living/silicon/robot/death.dm
@@ -1,72 +1,15 @@
-/mob/living/silicon/robot/gib()
- //robots don't die when gibbed. instead they drop their MMI'd brain
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
- flick("gibbed-r", animation)
- robogibs(loc, viruses)
-
- living_mob_list -= src
- dead_mob_list -= src
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
-
/mob/living/silicon/robot/dust()
- death(1)
- var/atom/movable/overlay/animation = null
- monkeyizing = 1
- canmove = 0
- icon = null
- invisibility = 101
-
- animation = new(loc)
- animation.icon_state = "blank"
- animation.icon = 'icons/mob/mob.dmi'
- animation.master = src
-
- flick("dust-r", animation)
- new /obj/effect/decal/remains/robot(loc)
- if(mmi) del(mmi) //Delete the MMI first so that it won't go popping out.
-
- dead_mob_list -= src
- spawn(15)
- if(animation) del(animation)
- if(src) del(src)
-
+ //Delete the MMI first so that it won't go popping out.
+ if(mmi)
+ del(mmi)
+ ..()
/mob/living/silicon/robot/death(gibbed)
- if(stat == DEAD) return
- if(!gibbed)
- emote("deathgasp")
- stat = DEAD
- update_canmove()
if(camera)
camera.status = 0
-
- if(in_contents_of(/obj/machinery/recharge_station))//exit the recharge station
- var/obj/machinery/recharge_station/RC = loc
- RC.go_out()
-
+ if(module)
+ var/obj/item/weapon/gripper/G = locate(/obj/item/weapon/gripper) in module
+ if(G) G.drop_item()
remove_robot_verbs()
-
- if(blind) blind.layer = 0
- sight |= SEE_TURFS|SEE_MOBS|SEE_OBJS
- see_in_dark = 8
- see_invisible = SEE_INVISIBLE_LEVEL_TWO
- updateicon()
-
- tod = worldtime2text() //weasellos time of death patch
- if(mind) mind.store_memory("Time of death: [tod]", 0)
-
sql_report_cyborg_death(src)
-
- return ..(gibbed)
\ No newline at end of file
+ ..(gibbed,"shudders violently for a moment, then becomes motionless, its eyes slowly darkening.")
diff --git a/code/modules/mob/living/silicon/robot/drone/drone.dm b/code/modules/mob/living/silicon/robot/drone/drone.dm
index 2aaa75fae15..d31f537e1a0 100644
--- a/code/modules/mob/living/silicon/robot/drone/drone.dm
+++ b/code/modules/mob/living/silicon/robot/drone/drone.dm
@@ -200,14 +200,6 @@
return
..()
-/mob/living/silicon/robot/drone/death(gibbed)
-
- if(module)
- var/obj/item/weapon/gripper/G = locate(/obj/item/weapon/gripper) in module
- if(G) G.drop_item()
-
- ..(gibbed)
-
//DRONE MOVEMENT.
/mob/living/silicon/robot/drone/Process_Spaceslipping(var/prob_slip)
//TODO: Consider making a magboot item for drones to equip. ~Z
diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm
index 9fc052fde26..bc112a0840b 100644
--- a/code/modules/mob/living/silicon/robot/robot.dm
+++ b/code/modules/mob/living/silicon/robot/robot.dm
@@ -455,13 +455,6 @@ var/list/robot_verbs_default = list(
C.toggled = 1
src << "\red You enable [C.name]."
-/mob/living/silicon/robot/blob_act()
- if (stat != 2)
- adjustBruteLoss(60)
- updatehealth()
- return 1
- return 0
-
// this function shows information about the malf_ai gameplay type in the status screen
/mob/living/silicon/robot/show_malf_ai()
..()
@@ -515,29 +508,6 @@ var/list/robot_verbs_default = list(
/mob/living/silicon/robot/restrained()
return 0
-
-/mob/living/silicon/robot/ex_act(severity)
- if(!blinded)
- flick("flash", flash)
-
- switch(severity)
- if(1.0)
- if (stat != 2)
- adjustBruteLoss(100)
- adjustFireLoss(100)
- gib()
- return
- if(2.0)
- if (stat != 2)
- adjustBruteLoss(60)
- adjustFireLoss(60)
- if(3.0)
- if (stat != 2)
- adjustBruteLoss(30)
-
- updatehealth()
-
-
/mob/living/silicon/robot/meteorhit(obj/O as obj)
for(var/mob/M in viewers(src, null))
M.show_message(text("\red [src] has been hit by [O]"), 1)
@@ -549,14 +519,11 @@ var/list/robot_verbs_default = list(
updatehealth()
return
-
/mob/living/silicon/robot/bullet_act(var/obj/item/projectile/Proj)
..(Proj)
- updatehealth()
if(prob(75) && Proj.damage > 0) spark_system.start()
return 2
-
/mob/living/silicon/robot/Bump(atom/movable/AM as mob|obj, yes)
spawn( 0 )
if ((!( yes ) || now_pushing))
@@ -988,7 +955,7 @@ var/list/robot_verbs_default = list(
return 1
return 0
-/mob/living/silicon/robot/proc/updateicon()
+/mob/living/silicon/robot/updateicon()
overlays.Cut()
if(stat == 0)
diff --git a/code/modules/mob/living/silicon/silicon.dm b/code/modules/mob/living/silicon/silicon.dm
index f3cc857b17d..ee4f34db817 100644
--- a/code/modules/mob/living/silicon/silicon.dm
+++ b/code/modules/mob/living/silicon/silicon.dm
@@ -67,8 +67,14 @@
/mob/living/silicon/IsAdvancedToolUser()
return 1
-/mob/living/silicon/bullet_act(var/obj/item/projectile/Proj)
+/mob/living/silicon/blob_act()
+ if (src.stat != 2)
+ src.adjustBruteLoss(60)
+ src.updatehealth()
+ return 1
+ return 0
+/mob/living/silicon/bullet_act(var/obj/item/projectile/Proj)
if(!Proj.nodamage)
switch(Proj.damage_type)
@@ -78,7 +84,7 @@
adjustFireLoss(Proj.damage)
Proj.on_hit(src,2)
-
+ updatehealth()
return 2
/mob/living/silicon/apply_effect(var/effect = 0,var/effecttype = STUN, var/blocked = 0)
@@ -222,4 +228,25 @@
flavor_text = copytext(sanitize(input(usr, "Please enter your new flavour text.", "Flavour text", null) as text), 1)
/mob/living/silicon/binarycheck()
- return 1
\ No newline at end of file
+ return 1
+
+/mob/living/silicon/ex_act(severity)
+ if(!blinded)
+ flick("flash", flash)
+
+ switch(severity)
+ if(1.0)
+ if (stat != 2)
+ adjustBruteLoss(100)
+ adjustFireLoss(100)
+ if(!anchored)
+ gib()
+ if(2.0)
+ if (stat != 2)
+ adjustBruteLoss(60)
+ adjustFireLoss(60)
+ if(3.0)
+ if (stat != 2)
+ adjustBruteLoss(30)
+
+ updatehealth()
\ No newline at end of file
diff --git a/code/modules/mob/living/simple_animal/constructs.dm b/code/modules/mob/living/simple_animal/constructs.dm
index 3abf928244c..fe0bda0b067 100644
--- a/code/modules/mob/living/simple_animal/constructs.dm
+++ b/code/modules/mob/living/simple_animal/constructs.dm
@@ -35,14 +35,10 @@
spell_list += new spell(src)
/mob/living/simple_animal/construct/death()
- ..()
new /obj/item/weapon/ectoplasm (src.loc)
- for(var/mob/M in viewers(src, null))
- if((M.client && !( M.blinded )))
- M.show_message("\red [src] collapses in a shattered heap. ")
+ ..(null,"collapses in a shattered heap.")
ghostize()
del src
- return
/mob/living/simple_animal/construct/examine()
set src in oview()
diff --git a/code/modules/mob/living/simple_animal/hostile/mimic.dm b/code/modules/mob/living/simple_animal/hostile/mimic.dm
index d239e88c6de..1a1aef1e83e 100644
--- a/code/modules/mob/living/simple_animal/hostile/mimic.dm
+++ b/code/modules/mob/living/simple_animal/hostile/mimic.dm
@@ -43,11 +43,8 @@
/mob/living/simple_animal/hostile/mimic/death()
..()
- visible_message("\red [src] stops moving!")
del(src)
-
-
//
// Crate Mimic
//
diff --git a/code/modules/mob/living/simple_animal/hostile/retaliate/drone.dm b/code/modules/mob/living/simple_animal/hostile/retaliate/drone.dm
index ddbd35d0e34..e5474dbcd21 100644
--- a/code/modules/mob/living/simple_animal/hostile/retaliate/drone.dm
+++ b/code/modules/mob/living/simple_animal/hostile/retaliate/drone.dm
@@ -158,8 +158,7 @@
walk(src,0)
/mob/living/simple_animal/hostile/retaliate/malf_drone/death()
- src.visible_message("\blue \icon[src] [src] suddenly breaks apart.")
- ..()
+ ..(null,"suddenly breaks apart.")
del(src)
/mob/living/simple_animal/hostile/retaliate/malf_drone/Del()
diff --git a/code/modules/mob/living/simple_animal/hostile/syndicate.dm b/code/modules/mob/living/simple_animal/hostile/syndicate.dm
index ff9aba71a47..e2678bc2f8b 100644
--- a/code/modules/mob/living/simple_animal/hostile/syndicate.dm
+++ b/code/modules/mob/living/simple_animal/hostile/syndicate.dm
@@ -158,7 +158,5 @@
minbodytemp = 0
/mob/living/simple_animal/hostile/viscerator/death()
- ..()
- visible_message("\red [src] is smashed into pieces!")
- del src
- return
\ No newline at end of file
+ ..(null,"is smashed into pieces!")
+ del src
\ No newline at end of file
diff --git a/code/modules/mob/living/simple_animal/hostile/tree.dm b/code/modules/mob/living/simple_animal/hostile/tree.dm
index 7f44f8a9b15..63d2f570f0a 100644
--- a/code/modules/mob/living/simple_animal/hostile/tree.dm
+++ b/code/modules/mob/living/simple_animal/hostile/tree.dm
@@ -51,7 +51,6 @@
L.visible_message("\the [src] knocks down \the [L]!")
/mob/living/simple_animal/hostile/tree/death()
- ..()
- visible_message("\red [src] is hacked into pieces!")
+ ..(null,"is hacked into pieces!")
new /obj/item/stack/sheet/wood(loc)
del(src)
\ No newline at end of file
diff --git a/code/modules/mob/living/simple_animal/simple_animal.dm b/code/modules/mob/living/simple_animal/simple_animal.dm
index e06d1af9381..11713801aaf 100644
--- a/code/modules/mob/living/simple_animal/simple_animal.dm
+++ b/code/modules/mob/living/simple_animal/simple_animal.dm
@@ -197,12 +197,10 @@
..()
/mob/living/simple_animal/gib()
- if(icon_gib)
- flick(icon_gib, src)
if(meat_amount && meat_type)
for(var/i = 0; i < meat_amount; i++)
new meat_type(src.loc)
- ..()
+ ..(icon_gib,1)
/mob/living/simple_animal/emote(var/act, var/type, var/desc)
if(act)
diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm
index 9e8a8c65fa3..de4023163a3 100644
--- a/code/modules/mob/mob.dm
+++ b/code/modules/mob/mob.dm
@@ -1080,3 +1080,6 @@ mob/proc/yank_out_object()
return I
return 0
+
+/mob/proc/updateicon()
+ return
\ No newline at end of file
diff --git a/code/modules/surgery/implant.dm b/code/modules/surgery/implant.dm
index 7e2fbc776e4..bb7d25046ad 100644
--- a/code/modules/surgery/implant.dm
+++ b/code/modules/surgery/implant.dm
@@ -112,7 +112,7 @@
can_use(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
if(..())
var/datum/organ/external/affected = target.get_organ(target_zone)
- return !affected.hidden && affected.cavity && tool.w_class <= get_max_wclass(affected)
+ return !istype(user,/mob/living/silicon/robot) && !affected.hidden && affected.cavity && tool.w_class <= get_max_wclass(affected)
begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
var/datum/organ/external/affected = target.get_organ(target_zone)