mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
Replaces istypes with the proper tool_behaviour checks. (#40414)
This commit is contained in:
committed by
yogstation13-bot
parent
81a1280956
commit
5a29dc43e3
@@ -74,7 +74,9 @@ handles linking back and forth.
|
||||
_MakeLocal()
|
||||
|
||||
/datum/component/remote_materials/proc/OnAttackBy(datum/source, obj/item/I, mob/user)
|
||||
if (istype(I, /obj/item/multitool))
|
||||
if(I.tool_behaviour == TOOL_MULTITOOL)
|
||||
if(!I.multitool_check_buffer(user, I))
|
||||
return COMPONENT_NO_AFTERATTACK
|
||||
var/obj/item/multitool/M = I
|
||||
if (!QDELETED(M.buffer) && istype(M.buffer, /obj/machinery/ore_silo))
|
||||
if (silo == M.buffer)
|
||||
|
||||
@@ -89,7 +89,7 @@
|
||||
/datum/component/simple_rotation/proc/WrenchRot(datum/source, obj/item/I, mob/living/user)
|
||||
if(!can_be_rotated.Invoke(user,default_rotation_direction) || !can_user_rotate.Invoke(user,default_rotation_direction))
|
||||
return
|
||||
if(istype(I,/obj/item/wrench))
|
||||
if(I.tool_behaviour == TOOL_WRENCH)
|
||||
BaseRot(user,default_rotation_direction)
|
||||
return COMPONENT_NO_AFTERATTACK
|
||||
|
||||
|
||||
Reference in New Issue
Block a user