From 88486f97ca3961351b7b13e66175295012d06e16 Mon Sep 17 00:00:00 2001 From: Leo Date: Tue, 17 Oct 2017 12:19:36 -0200 Subject: [PATCH] Merge pull request #31795 from AnturK/random-runtimes Random runtime fixes. --- code/game/gamemodes/malfunction/Malf_Modules.dm | 2 +- code/game/turfs/simulated/walls.dm | 2 +- code/modules/mob/living/carbon/human/update_icons.dm | 9 +++++---- .../reagents/chemistry/reagents/medicine_reagents.dm | 3 ++- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/code/game/gamemodes/malfunction/Malf_Modules.dm b/code/game/gamemodes/malfunction/Malf_Modules.dm index e087b23392..92dca5d3c9 100644 --- a/code/game/gamemodes/malfunction/Malf_Modules.dm +++ b/code/game/gamemodes/malfunction/Malf_Modules.dm @@ -426,7 +426,7 @@ GLOBAL_LIST_INIT(blacklisted_malf_machines, typecacheof(list( for(var/obj/machinery/door/D in GLOB.airlocks) if(!(D.z in GLOB.station_z_levels)) continue - INVOKE_ASYNC(D, /obj/machinery/door.proc/hostile_lockdown, src) + INVOKE_ASYNC(D, /obj/machinery/door.proc/hostile_lockdown, owner) addtimer(CALLBACK(D, /obj/machinery/door.proc/disable_lockdown), 900) var/obj/machinery/computer/communications/C = locate() in GLOB.machines diff --git a/code/game/turfs/simulated/walls.dm b/code/game/turfs/simulated/walls.dm index 8ab9a4e682..57037de446 100644 --- a/code/game/turfs/simulated/walls.dm +++ b/code/game/turfs/simulated/walls.dm @@ -174,7 +174,7 @@ return /turf/closed/wall/proc/try_clean(obj/item/W, mob/user, turf/T) - if((user.a_intent != INTENT_HELP) || !damage_decals.len || !istype(W, /obj/item/weldingtool)) + if((user.a_intent != INTENT_HELP) || !LAZYLEN(damage_decals) || !istype(W, /obj/item/weldingtool)) return FALSE var/obj/item/weldingtool/WT = W if(WT.remove_fuel(0, user)) diff --git a/code/modules/mob/living/carbon/human/update_icons.dm b/code/modules/mob/living/carbon/human/update_icons.dm index 4a9983b9e6..de0f733944 100644 --- a/code/modules/mob/living/carbon/human/update_icons.dm +++ b/code/modules/mob/living/carbon/human/update_icons.dm @@ -223,10 +223,11 @@ There are several things that need to be remembered: if(!(head && (head.flags_inv & HIDEEYES)) && !(wear_mask && (wear_mask.flags_inv & HIDEEYES))) overlays_standing[GLASSES_LAYER] = glasses.build_worn_icon(state = glasses.icon_state, default_layer = GLASSES_LAYER, default_icon_file = 'icons/mob/eyes.dmi') var/mutable_appearance/glasses_overlay = overlays_standing[GLASSES_LAYER] - if(OFFSET_GLASSES in dna.species.offset_features) - glasses_overlay.pixel_x += dna.species.offset_features[OFFSET_GLASSES][1] - glasses_overlay.pixel_y += dna.species.offset_features[OFFSET_GLASSES][2] - overlays_standing[GLASSES_LAYER] = glasses_overlay + if(glasses_overlay) + if(OFFSET_GLASSES in dna.species.offset_features) + glasses_overlay.pixel_x += dna.species.offset_features[OFFSET_GLASSES][1] + glasses_overlay.pixel_y += dna.species.offset_features[OFFSET_GLASSES][2] + overlays_standing[GLASSES_LAYER] = glasses_overlay apply_overlay(GLASSES_LAYER) diff --git a/code/modules/reagents/chemistry/reagents/medicine_reagents.dm b/code/modules/reagents/chemistry/reagents/medicine_reagents.dm index dcf725819d..a25401eec5 100644 --- a/code/modules/reagents/chemistry/reagents/medicine_reagents.dm +++ b/code/modules/reagents/chemistry/reagents/medicine_reagents.dm @@ -814,7 +814,8 @@ M.jitteriness = 0 if(M.has_dna()) M.dna.remove_all_mutations() - ..() + if(!QDELETED(M)) //We were a monkey, now a human + ..() /datum/reagent/medicine/antihol name = "Antihol"