examine signature changed to include distance

- distance is INFINITE, 0, or a positive integer based on get_dist() between
the examiner and examinee's turfs when they are on the same Z. When the
examiner is dead or a ghost, distance is always 0.
- also updates /examine( implementations to use it!
- adds w_class_to_name proc for reusing "It is a X item." examine behavior.
This commit is contained in:
Spookerton
2023-12-29 23:44:21 +00:00
parent e3393dc87b
commit 978f4511a5
240 changed files with 524 additions and 551 deletions
@@ -46,10 +46,10 @@
IC.emp_act(severity)
..()
/obj/item/clothing/examine(mob/user)
/obj/item/clothing/examine(mob/user, distance, infix, suffix)
. = ..()
if(IC)
. += IC.examine(user)
. += IC.examine(user, distance, infix, suffix)
/obj/item/clothing/CtrlShiftClick(mob/user)
var/turf/T = get_turf(src)
@@ -178,4 +178,4 @@
/obj/item/clothing/suit/circuitry/Initialize()
setup_integrated_circuit(/obj/item/electronic_assembly/clothing/large)
return ..()
return ..()
@@ -45,7 +45,7 @@
I.do_work()
return
/obj/item/assembly/electronic_assembly/examine(mob/user)
/obj/item/assembly/electronic_assembly/examine(mob/user, distance, infix, suffix)
. = ..()
if(EA)
for(var/obj/item/integrated_circuit/IC in EA.contents)
@@ -81,4 +81,3 @@
if(!CanInteract(user, state = deep_inventory_state))
return 0
return 1