mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-30 00:21:11 +01:00
Aim Intent Safety Fix (#19280)
* Fixed aim intent triggering clicking messages if someone moves (despite being allowed to move) when you're not on harm intent. Fixes https://github.com/Aurorastation/Aurora.3/issues/19242
This commit is contained in:
@@ -23,6 +23,13 @@
|
||||
return TRUE
|
||||
|
||||
/obj/aiming_overlay/proc/trigger(var/perm)
|
||||
if(!owner || !aiming_with || !aiming_at || !locked)
|
||||
return FALSE
|
||||
if(perm && (target_permissions & perm))
|
||||
return FALSE
|
||||
if(!owner.canClick())
|
||||
return FALSE
|
||||
|
||||
var/obj/item/gun/G = aiming_with
|
||||
if(istype(G) && G.safety())
|
||||
if(owner.a_intent == I_HURT)
|
||||
@@ -30,12 +37,6 @@
|
||||
else
|
||||
G.handle_click_empty(owner)
|
||||
to_chat(owner, SPAN_WARNING("Your [G]'s safety prevents firing."))
|
||||
if(!owner || !aiming_with || !aiming_at || !locked)
|
||||
return FALSE
|
||||
if(perm && (target_permissions & perm))
|
||||
return FALSE
|
||||
if(!owner.canClick())
|
||||
return FALSE
|
||||
|
||||
owner.setClickCooldown(DEFAULT_QUICK_COOLDOWN) // Spam prevention, essentially.
|
||||
owner.visible_message(
|
||||
|
||||
Reference in New Issue
Block a user