From 4773361f64a400b384e12583660eb1c788fdc890 Mon Sep 17 00:00:00 2001 From: cib Date: Tue, 15 Jan 2013 19:46:30 +0100 Subject: [PATCH 1/3] Proper fix for the projectile runtime. Adds projectile autopsy messages back. Partial fix to issue #2153 --- code/modules/mob/living/damage_procs.dm | 4 ++-- code/modules/mob/living/living_defense.dm | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/code/modules/mob/living/damage_procs.dm b/code/modules/mob/living/damage_procs.dm index e0d05b12ef6..3c1d1776b31 100644 --- a/code/modules/mob/living/damage_procs.dm +++ b/code/modules/mob/living/damage_procs.dm @@ -8,7 +8,7 @@ Returns standard 0 if fail */ -/mob/living/proc/apply_damage(var/damage = 0,var/damagetype = BRUTE, var/def_zone = null, var/blocked = 0) +/mob/living/proc/apply_damage(var/damage = 0,var/damagetype = BRUTE, var/def_zone = null, var/blocked = 0, var/used_weapon = null) if(!damage || (blocked >= 2)) return 0 switch(damagetype) if(BRUTE) @@ -72,4 +72,4 @@ if(stutter) apply_effect(stutter, STUTTER, blocked) if(eyeblur) apply_effect(eyeblur, EYE_BLUR, blocked) if(drowsy) apply_effect(drowsy, DROWSY, blocked) - return 1 \ No newline at end of file + return 1 diff --git a/code/modules/mob/living/living_defense.dm b/code/modules/mob/living/living_defense.dm index 09f458ca2aa..d0f61484c66 100644 --- a/code/modules/mob/living/living_defense.dm +++ b/code/modules/mob/living/living_defense.dm @@ -57,7 +57,7 @@ P.on_hit(src,2) return 2 if(!P.nodamage) - apply_damage((P.damage/(absorb+1)), P.damage_type, def_zone) + apply_damage((P.damage/(absorb+1)), P.damage_type, def_zone, used_weapon = "Projectile([P.name])") P.on_hit(src, absorb) return absorb From aff12feaaa478c28dcb84938ac2e852e2e6c64e0 Mon Sep 17 00:00:00 2001 From: cib Date: Tue, 15 Jan 2013 21:14:06 +0100 Subject: [PATCH 2/3] More fixes to autopsy scanner, issue #2153 - Scanner will now print data even when only time of death is available. - Scanner will reset chemtraces on new patient. --- code/WorkInProgress/autopsy.dm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/code/WorkInProgress/autopsy.dm b/code/WorkInProgress/autopsy.dm index 7cbc8a40175..df14b1c9396 100644 --- a/code/WorkInProgress/autopsy.dm +++ b/code/WorkInProgress/autopsy.dm @@ -74,10 +74,6 @@ usr << "No." return - if(wdata.len == 0 && chemtraces.len == 0) - usr << "* There is no data about any wounds in the scanner's database. You may have to scan more bodyparts, or otherwise this wound type may not be in the scanner's database." - return - var/scan_data = "" if(timeofdeath) @@ -179,6 +175,8 @@ if(target_name != M.name) target_name = M.name src.wdata = list() + src.chemtraces = list() + src.timeofdeath = null user << "\red A new patient has been registered.. Purging data for previous patient." src.timeofdeath = M.timeofdeath From cdda38b6bebe11186e7d0237925255497dbccc63 Mon Sep 17 00:00:00 2001 From: cib Date: Tue, 15 Jan 2013 21:23:03 +0100 Subject: [PATCH 3/3] More fixes for issue #2153 High/low body temperature damage now leaves an autopsy message. --- code/modules/mob/living/carbon/human/life.dm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index cd0dafa5f1f..1a3f73031da 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -776,13 +776,13 @@ var/const/BLOOD_VOLUME_SURVIVE = 122 fire_alert = max(fire_alert, 1) switch(bodytemperature) if(360 to 400) - apply_damage(HEAT_DAMAGE_LEVEL_1, BURN) + apply_damage(HEAT_DAMAGE_LEVEL_1, BURN, used_weapon = "High Body Temperature") fire_alert = max(fire_alert, 2) if(400 to 1000) - apply_damage(HEAT_DAMAGE_LEVEL_2, BURN) + apply_damage(HEAT_DAMAGE_LEVEL_2, BURN, used_weapon = "High Body Temperature") fire_alert = max(fire_alert, 2) if(1000 to INFINITY) - apply_damage(HEAT_DAMAGE_LEVEL_3, BURN) + apply_damage(HEAT_DAMAGE_LEVEL_3, BURN, used_weapon = "High Body Temperature") fire_alert = max(fire_alert, 2) else if(bodytemperature < BODYTEMP_COLD_DAMAGE_LIMIT) @@ -790,13 +790,13 @@ var/const/BLOOD_VOLUME_SURVIVE = 122 if(!istype(loc, /obj/machinery/atmospherics/unary/cryo_cell)) switch(bodytemperature) if(200 to 260) - apply_damage(COLD_DAMAGE_LEVEL_1, BURN) + apply_damage(COLD_DAMAGE_LEVEL_1, BURN, used_weapon = "Low Body Temperature") fire_alert = max(fire_alert, 1) if(120 to 200) - apply_damage(COLD_DAMAGE_LEVEL_2, BURN) + apply_damage(COLD_DAMAGE_LEVEL_2, BURN, used_weapon = "Low Body Temperature") fire_alert = max(fire_alert, 1) if(-INFINITY to 120) - apply_damage(COLD_DAMAGE_LEVEL_3, BURN) + apply_damage(COLD_DAMAGE_LEVEL_3, BURN, used_weapon = "Low Body Temperature") fire_alert = max(fire_alert, 1) // Account for massive pressure differences. Done by Polymorph