From 7b39ffdb8da7b96b6659e75d4670de470982f39f Mon Sep 17 00:00:00 2001 From: AnturK Date: Tue, 3 Oct 2017 10:26:48 +0200 Subject: [PATCH] Fixes locked slots for humans that switch species before assigning key. --- code/_onclick/hud/human.dm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/code/_onclick/hud/human.dm b/code/_onclick/hud/human.dm index 9c41f414986..e7e11600965 100644 --- a/code/_onclick/hud/human.dm +++ b/code/_onclick/hud/human.dm @@ -308,11 +308,15 @@ inv.hud = src inv_slots[inv.slot_id] = inv inv.update_icon() + + update_locked_slots() /datum/hud/human/update_locked_slots() if(!mymob) return var/mob/living/carbon/human/H = mymob + if(!istype(H) || !H.dna.species) + return var/datum/species/S = H.dna.species for(var/obj/screen/inventory/inv in (static_inventory + toggleable_inventory)) if(inv.slot_id)