mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
[MIRROR] Refactors tool typechecks, refactors transforming tools, makes Altevian wrench into one (#7062)
Co-authored-by: Heroman3003 <31296024+Heroman3003@users.noreply.github.com> Co-authored-by: Nadyr <41974248+Darlantanis@users.noreply.github.com>
This commit is contained in:
@@ -70,7 +70,7 @@
|
||||
if((!A.secured) && (!secured))
|
||||
attach_assembly(A,user)
|
||||
return
|
||||
if(W.is_screwdriver())
|
||||
if(W.has_tool_quality(TOOL_SCREWDRIVER))
|
||||
if(toggle_secure())
|
||||
to_chat(user, "<span class='notice'>\The [src] is ready!</span>")
|
||||
else
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
..()
|
||||
|
||||
/obj/item/device/assembly_holder/attackby(var/obj/item/weapon/W, var/mob/user)
|
||||
if(W.is_screwdriver())
|
||||
if(W.has_tool_quality(TOOL_SCREWDRIVER))
|
||||
if(!a_left || !a_right)
|
||||
to_chat(user, "<span class='warning'> BUG:Assembly part missing, please report this!</span>")
|
||||
return
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
return
|
||||
|
||||
/obj/item/assembly/shock_kit/attackby(var/obj/item/weapon/W, var/mob/user)
|
||||
if(W.is_wrench() && !status)
|
||||
if(W.has_tool_quality(TOOL_WRENCH) && !status)
|
||||
var/turf/T = loc
|
||||
if(ismob(T))
|
||||
T = T.loc
|
||||
@@ -26,7 +26,7 @@
|
||||
part2 = null
|
||||
qdel(src)
|
||||
return
|
||||
if(W.is_screwdriver())
|
||||
if(W.has_tool_quality(TOOL_SCREWDRIVER))
|
||||
status = !status
|
||||
to_chat(user, "<span class='notice'>[src] is now [status ? "secured" : "unsecured"]!</span>")
|
||||
playsound(src, W.usesound, 50, 1)
|
||||
|
||||
Reference in New Issue
Block a user