mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-30 16:38:22 +01:00
Not Butts Hacking (#9236)
Hacking no longer requires you to hold the tool (wirecutters, multitool, signaler) in your active hand, just that the tool is in one of your hands. This applies to cyborgs as well.
This commit is contained in:
@@ -130,6 +130,21 @@ var/list/slot_equipment_priority = list( \
|
||||
if(hand) return r_hand
|
||||
else return l_hand
|
||||
|
||||
//Returns the thing if it's a subtype of the requested thing, taking priority of the active hand
|
||||
/mob/proc/get_type_in_hands(var/type)
|
||||
if(hand)
|
||||
if(istype(l_hand, type))
|
||||
return l_hand
|
||||
else if(istype(r_hand, type))
|
||||
return r_hand
|
||||
return
|
||||
else
|
||||
if(istype(r_hand, type))
|
||||
return r_hand
|
||||
else if(istype(l_hand, type))
|
||||
return l_hand
|
||||
return
|
||||
|
||||
//Puts the item into your l_hand if possible and calls all necessary triggers/updates. returns 1 on success.
|
||||
/mob/proc/put_in_l_hand(var/obj/item/W)
|
||||
if(lying || !istype(W))
|
||||
|
||||
@@ -6,6 +6,18 @@
|
||||
// TODO: see if refactoring this to return the gripped object (should one exist) works - would make a lot of edge cases a lot simpler
|
||||
return module_active
|
||||
|
||||
/mob/living/silicon/robot/proc/return_wirecutter()
|
||||
for(var/obj/I in list(module_state_1, module_state_2, module_state_3))
|
||||
if(I.iswirecutter())
|
||||
return I
|
||||
return
|
||||
|
||||
/mob/living/silicon/robot/proc/return_multitool()
|
||||
for(var/obj/I in list(module_state_1, module_state_2, module_state_3))
|
||||
if(I.ismultitool())
|
||||
return I
|
||||
return
|
||||
|
||||
/*-------TODOOOOOOOOOO--------*/
|
||||
|
||||
//Verbs used by hotkeys.
|
||||
|
||||
Reference in New Issue
Block a user