From bfeece4c6e7e1fb148957932ea8dbea1280e849c Mon Sep 17 00:00:00 2001 From: Ghommie <42542238+Ghommie@users.noreply.github.com> Date: Thu, 21 Nov 2019 09:23:05 +0100 Subject: [PATCH] fixing a get_idcard runtime. The betrayal of the ?. --- code/modules/mob/mob_helpers.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/modules/mob/mob_helpers.dm b/code/modules/mob/mob_helpers.dm index 550593e316..c18fc36e9a 100644 --- a/code/modules/mob/mob_helpers.dm +++ b/code/modules/mob/mob_helpers.dm @@ -522,10 +522,10 @@ It's fairly easy to fix if dealing with single letters but not so much with comp //gets ID card object from special clothes slot or null. /mob/proc/get_idcard(hand_first = TRUE) var/obj/item/held_item = get_active_held_item() - . = held_item?.GetID() + . = held_item ? held_item.GetID() : null if(!.) //If so, then check the inactive hand held_item = get_inactive_held_item() - . = held_item?.GetID() + . = held_item ? held_item.GetID() : null /mob/proc/get_id_in_hand() var/obj/item/held_item = get_active_held_item()