mirror of
https://github.com/KabKebab/GS13.git
synced 2026-08-25 05:56:27 +01:00
COMPLETELY FUCKING REFACTORS TOOL CHECKING CODE
dear FUCKING GOD why was it like this, it hurts soooo bad DDDD:
This commit is contained in:
@@ -187,14 +187,14 @@ GLOBAL_LIST_EMPTY(gravity_generators) // We will keep track of this by adding ne
|
||||
/obj/machinery/gravity_generator/main/attackby(obj/item/I, mob/user, params)
|
||||
switch(broken_state)
|
||||
if(GRAV_NEEDS_SCREWDRIVER)
|
||||
if(istype(I, /obj/item/screwdriver))
|
||||
if(I.tool_behavior == TOOL_SCREWDRIVER)
|
||||
to_chat(user, "<span class='notice'>You secure the screws of the framework.</span>")
|
||||
I.play_tool_sound(src)
|
||||
broken_state++
|
||||
update_icon()
|
||||
return
|
||||
if(GRAV_NEEDS_WELDING)
|
||||
if(istype(I, /obj/item/weldingtool))
|
||||
if(I.tool_behavior == TOOL_WELDER)
|
||||
if(I.use_tool(src, user, 0, volume=50, amount=1))
|
||||
to_chat(user, "<span class='notice'>You mend the damaged framework.</span>")
|
||||
broken_state++
|
||||
@@ -213,7 +213,7 @@ GLOBAL_LIST_EMPTY(gravity_generators) // We will keep track of this by adding ne
|
||||
to_chat(user, "<span class='warning'>You need 10 sheets of plasteel!</span>")
|
||||
return
|
||||
if(GRAV_NEEDS_WRENCH)
|
||||
if(istype(I, /obj/item/wrench))
|
||||
if(I.tool_behaviour == TOOL_WRENCH)
|
||||
to_chat(user, "<span class='notice'>You secure the plating to the framework.</span>")
|
||||
I.play_tool_sound(src)
|
||||
set_fix()
|
||||
|
||||
Reference in New Issue
Block a user