Split examine verb and function, and improve it (#17251)

* Split examine verb and function, and include adjacency and distance checking in examine function

* Fix various issues

* Update code/modules/mob/examinations.dm

Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>

* Add required define vars

* Update code/game/objects/items/stacks/wrap.dm

Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>

---------

Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>
This commit is contained in:
Cody Brittain
2023-09-09 08:07:36 +00:00
committed by GitHub
co-authored by SleepyGemmy
parent 39228d3a2c
commit ce5ac79e3c
241 changed files with 617 additions and 518 deletions
+2 -2
View File
@@ -208,7 +208,7 @@
callHook("debrain", list(brainmob))
/obj/item/organ/internal/brain/examine(mob/user) // -- TLE
..(user)
. = ..()
if(brainmob && brainmob.client)//if thar be a brain inside... the brain.
to_chat(user, "You can feel the small spark of life still left in this one.")
else
@@ -228,4 +228,4 @@
return ..()
/obj/item/organ/internal/brain/zombie
relative_size = 100
relative_size = 100
+1 -1
View File
@@ -212,7 +212,7 @@
return
/obj/item/organ/examine(mob/user)
..(user)
. = ..()
if(status & ORGAN_DEAD)
to_chat(user, "<span class='notice'>The decay has set in.</span>")
+3 -3
View File
@@ -154,9 +154,9 @@
return //no eating the limb until everything's been removed
return ..()
/obj/item/organ/external/examine()
..()
if(in_range(usr, src) || istype(usr, /mob/abstract/observer))
/obj/item/organ/external/examine(mob/user, distance, is_adjacent)
. = ..()
if(distance <= 1)
for(var/obj/item/I in contents)
if(istype(I, /obj/item/organ))
continue
+2 -2
View File
@@ -230,7 +230,7 @@
. = ..()
/obj/item/organ/internal/ipc_tag/examine(mob/user)
..()
. = ..()
to_chat(user, SPAN_NOTICE("Serial Autogeneration: [auto_generate ? "Yes" : "No"]"))
to_chat(user, SPAN_NOTICE("Serial Number: [serial_number]"))
to_chat(user, SPAN_NOTICE("Ownership Info: [ownership_info]"))
@@ -246,7 +246,7 @@
to_chat(user, SPAN_WARNING("\The [src] reads, \"Scanning failure, please submit scanner for repairs.\""))
return
if(!S.hacked)
user.examinate(src)
examinate(user, src)
else
user.visible_message(SPAN_WARNING("\The [user] starts fiddling with \the [src]..."), SPAN_NOTICE("You start fiddling with \the [src]..."))
if(do_after(user, 30, TRUE, src))
+3 -3
View File
@@ -163,9 +163,9 @@
return ..()
/obj/item/organ/internal/vaurca/preserve/examine(mob/user)
. = ..(user, 0)
if(.)
/obj/item/organ/internal/vaurca/preserve/examine(mob/user, distance, is_adjacent)
. = ..()
if(distance <= 0)
var/celsius_temperature = air_contents.temperature - T0C
var/descriptive
switch(celsius_temperature)