Screwdrivers can now be recycled in autolathes (#21629)

* screwdriver can be put into autolathe

* Redundant and misspelt  comment

* minutia

Co-authored-by: JimKil3 <47290811+JimKil3@users.noreply.github.com>

* add COMSIG_TOOL_ATTACK

* tools can be inserted on harm intent

* use signal to allow screwdriver to be inserted into the autolathe

* accidental spaces

* parenthesis for clarity

* snake_case 1

Co-authored-by: JimKil3 <47290811+JimKil3@users.noreply.github.com>

* snake_case 2

Co-authored-by: JimKil3 <47290811+JimKil3@users.noreply.github.com>

* dont direct istype check the screwdriver

* . defaults to null

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

* add SIGNAL_HANDLER to the proc that handles a signal

---------

Co-authored-by: JimKil3 <47290811+JimKil3@users.noreply.github.com>
Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
This commit is contained in:
Fridge Burns
2023-08-12 18:21:17 +01:00
committed by GitHub
co-authored by JimKil3 Contrabang
parent 4748736c9e
commit 2f711fb321
4 changed files with 20 additions and 1 deletions
+3
View File
@@ -10,6 +10,9 @@
/obj/item/proc/tool_attack_chain(mob/user, atom/target)
if(!tool_behaviour)
return FALSE
if(SEND_SIGNAL(target, COMSIG_TOOL_ATTACK, src, user) & COMPONENT_CANCEL_TOOLACT)
return FALSE
return target.tool_act(user, src, tool_behaviour)
// Called when the item is in the active hand, and clicked; alternately, there is an 'activate held object' verb or you can hit pagedown.