From fb51202dda1ad57bb4f0d18cc8d10d7cdad601f0 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Sat, 3 Oct 2020 02:31:19 +0200 Subject: [PATCH] [MIRROR] changes your cursor to an eye when you are holding shift to indicate you will examine (#1124) * changes your cursor to an eye when you are holding shift to indicate you will examine (#54083) * changes your cursor to an eye when you are holding shift to indicate you will examine Co-authored-by: Qustinnus --- code/modules/keybindings/bindings_client.dm | 2 ++ code/modules/mob/living/silicon/silicon.dm | 1 + code/modules/mob/mob.dm | 5 +++-- code/modules/mob/mob_defines.dm | 2 ++ icons/effects/mouse_pointers/examine_pointer.dmi | Bin 0 -> 430 bytes 5 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 icons/effects/mouse_pointers/examine_pointer.dmi diff --git a/code/modules/keybindings/bindings_client.dm b/code/modules/keybindings/bindings_client.dm index bd2033dc4fe..25520dc583b 100644 --- a/code/modules/keybindings/bindings_client.dm +++ b/code/modules/keybindings/bindings_client.dm @@ -75,6 +75,7 @@ holder?.key_down(_key, src) mob.focus?.key_down(_key, src) + mob.update_mouse_pointer() /client/verb/keyUp(_key as text) @@ -104,6 +105,7 @@ break holder?.key_up(_key, src) mob.focus?.key_up(_key, src) + mob.update_mouse_pointer() // Called every game tick diff --git a/code/modules/mob/living/silicon/silicon.dm b/code/modules/mob/living/silicon/silicon.dm index 58f5b70d678..8dabac31912 100644 --- a/code/modules/mob/living/silicon/silicon.dm +++ b/code/modules/mob/living/silicon/silicon.dm @@ -14,6 +14,7 @@ deathsound = 'sound/voice/borg_deathsound.ogg' speech_span = SPAN_ROBOT flags_1 = PREVENT_CONTENTS_EXPLOSION_1 | HEAR_1 | RAD_PROTECT_CONTENTS_1 | RAD_NO_CONTAMINATE_1 + examine_cursor_icon = null var/datum/ai_laws/laws = null//Now... THEY ALL CAN ALL HAVE LAWS var/last_lawchange_announce = 0 var/list/alarms_to_show = list() diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index e44698a4011..815d1688a58 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -1164,7 +1164,9 @@ if (!client) return client.mouse_pointer_icon = initial(client.mouse_pointer_icon) - if (ismecha(loc)) + if(examine_cursor_icon && client.keys_held["Shift"]) //mouse shit is hardcoded, make this non hard-coded once we make mouse modifiers bindable + client.mouse_pointer_icon = examine_cursor_icon + else if (ismecha(loc)) var/obj/vehicle/sealed/mecha/M = loc if(M.mouse_pointer) client.mouse_pointer_icon = M.mouse_pointer @@ -1177,7 +1179,6 @@ ///This mob is abile to read books /mob/proc/is_literate() return FALSE - ///Can this mob read (is literate and not blind) /mob/proc/can_read(obj/O) if(is_blind()) diff --git a/code/modules/mob/mob_defines.dm b/code/modules/mob/mob_defines.dm index ee93efa03c4..8dd87b21010 100644 --- a/code/modules/mob/mob_defines.dm +++ b/code/modules/mob/mob_defines.dm @@ -41,6 +41,8 @@ var/list/datum/action/actions /// A special action? No idea why this lives here var/list/datum/action/chameleon_item_actions + ///Cursor icon used when holding shift over things + var/examine_cursor_icon = 'icons/effects/mouse_pointers/examine_pointer.dmi' /// Whether a mob is alive or dead. TODO: Move this to living - Nodrak (2019, still here) var/stat = CONSCIOUS diff --git a/icons/effects/mouse_pointers/examine_pointer.dmi b/icons/effects/mouse_pointers/examine_pointer.dmi new file mode 100644 index 0000000000000000000000000000000000000000..41a9cec13b07fc8954d21e7877b2b1f0ba7a1374 GIT binary patch literal 430 zcmV;f0a5;mP)oxF0Hv~iTIZi$-&0}~ho zABk{(E*djUI8YkBN5udD00DGTPE!Ct=GbNc0044&R9JLGWpiV4X>fFDZ*Bkpc$`yK zaB_9`^iy#0_2eo`Eh^5;&r`5fFwryM;w;ZhDainGjE%TBGg33tGfE(w;*!LYR3KAH ziHkEOv#1!zH00t;D@x2wg|aj9ONtBfLCOtu40H^+loee4T)z(9IIUAPfXxszOL@iqQ7`U)2OVjt8>d9G3%!{U-c`>twkEH`7f6`VLTU z0QL%SAJF}JKKf|!WlUsA9*IPmnX?+N=UErCBNFj_5s}5ja6q1|H<3po>H#8aSw+Sp z6tGBn6b#^m%ek3qZf&0J8 Y6ZlaH9DJe0w*UYD07*qoM6N<$g6R&g)&Kwi literal 0 HcmV?d00001