* Maps and things no code/icons * helpers defines globalvars * Onclick world.dm orphaned_procs * subsystems Round vote and shuttle autocall done here too * datums * Game folder * Admin - chatter modules * clothing - mining * modular computers - zambies * client * mob level 1 * mob stage 2 + simple_animal * silicons n brains * mob stage 3 + Alien/Monkey * human mobs * icons updated * some sounds * emitter y u no commit * update tgstation.dme * compile fixes * travis fixes Also removes Fast digest mode, because reasons. * tweaks for travis Mentors are broke again Also fixes Sizeray guns * oxygen loss fix for vore code. * removes unused code * some code updates * bulk fixes * further fixes * outside things * whoops. * Maint bar ported * GLOBs.
25 lines
767 B
Plaintext
25 lines
767 B
Plaintext
/**
|
|
* tgui state: physical_state
|
|
*
|
|
* Short-circuits the default state to only check physical distance.
|
|
**/
|
|
|
|
GLOBAL_DATUM_INIT(physical_state, /datum/ui_state/physical, new)
|
|
|
|
/datum/ui_state/physical/can_use_topic(src_object, mob/user)
|
|
. = user.shared_ui_interaction(src_object)
|
|
if(. > UI_CLOSE)
|
|
return min(., user.physical_can_use_topic(src_object))
|
|
|
|
/mob/proc/physical_can_use_topic(src_object)
|
|
return UI_CLOSE
|
|
|
|
/mob/living/physical_can_use_topic(src_object)
|
|
return shared_living_ui_distance(src_object)
|
|
|
|
/mob/living/silicon/physical_can_use_topic(src_object)
|
|
return max(UI_UPDATE, shared_living_ui_distance(src_object)) // Silicons can always see.
|
|
|
|
/mob/living/silicon/ai/physical_can_use_topic(src_object)
|
|
return UI_UPDATE // AIs are not physical.
|