Adds Hand Raising (#24223)

* pick me pick me!

* quick fix

Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>

* contra tweak

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>

* contra refactor help

* copy paste moment

* missed one lul

* contra review

* tab hell tab hell tab hell

---------

Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
This commit is contained in:
matttheficus
2024-03-24 14:10:21 -04:00
committed by GitHub
parent 1fe7819c1b
commit 261b53d17c
4 changed files with 34 additions and 14 deletions
+17
View File
@@ -908,3 +908,20 @@ GLOBAL_DATUM_INIT(welding_sparks, /mutable_appearance, mutable_appearance('icons
/obj/item/proc/get_heat()
return
/obj/item/proc/run_pointed_on_item(mob/pointer_mob, atom/target_atom)
if(!HAS_TRAIT(src, TRAIT_CAN_POINT_WITH) || target_atom == src)
return FALSE
var/pointed_object = "\the [target_atom]"
if(target_atom.loc in pointer_mob)
pointed_object += " inside [target_atom.loc]"
if(pointer_mob.a_intent == INTENT_HELP || !ismob(target_atom))
pointer_mob.visible_message("<b>[pointer_mob]</b> points to [pointed_object] with [src]")
return TRUE
target_atom.visible_message("<span class='danger'>[pointer_mob] points [src] at [pointed_object]!</span>",
"<span class='userdanger'>[pointer_mob] points [src] at you!</span>")
SEND_SOUND(target_atom, sound('sound/weapons/targeton.ogg'))
return TRUE
+6
View File
@@ -77,3 +77,9 @@
creature.EyeBlind(2 SECONDS) //OH GOD MY EARS ARE RINGING
creature.Deaf(4 SECONDS) //OH MY HEAD
return ..()
/obj/item/slapper/run_pointed_on_item(mob/pointer_mob, atom/target_atom)
if(target_atom == src)
pointer_mob.visible_message("<b>[pointer_mob]</b> raises [pointer_mob.p_their()] hand!")
return TRUE
return ..()
+7
View File
@@ -1239,6 +1239,13 @@
shoot_gun(user)
return ..()
/obj/item/toy/russian_revolver/trick_revolver/run_pointed_on_item(mob/pointer_mob, atom/target_atom)
if(target_atom != src)
pointer_mob.visible_message("<span class='danger'>[pointer_mob] points [src] at- and [src] goes off in their hand!</span>")
shoot_gun(pointer_mob)
return TRUE
return ..()
/*
* Rubber Chainsaw
*/
+4 -14
View File
@@ -268,24 +268,14 @@
/mob/living/run_pointed(atom/A)
if(!..())
return FALSE
var/obj/item/hand_item = get_active_hand()
if(istype(hand_item) && hand_item.run_pointed_on_item(src, A))
return TRUE
var/pointed_object = "\the [A]"
if(A.loc in src)
pointed_object += " inside [A.loc]"
var/obj/item/hand_item = get_active_hand()
if(!QDELETED(hand_item) && istype(hand_item) && HAS_TRAIT(hand_item, TRAIT_CAN_POINT_WITH) && A != hand_item)
if(a_intent == INTENT_HELP || !ismob(A))
visible_message("<b>[src]</b> points to [pointed_object] with [hand_item]")
return TRUE
A.visible_message("<span class='danger'>[src] points [hand_item] at [pointed_object]!</span>",
"<span class='userdanger'>[src] points [hand_item] at you!</span>")
SEND_SOUND(A, sound('sound/weapons/targeton.ogg'))
return TRUE
if(istype(hand_item, /obj/item/toy/russian_revolver/trick_revolver) && A != hand_item)
var/obj/item/toy/russian_revolver/trick_revolver/trick = hand_item
visible_message("<span class='danger'>[src] points [trick] at- and [trick] goes off in their hand!</span>")
trick.shoot_gun(src)
visible_message("<b>[src]</b> points to [pointed_object]")
return TRUE