Implement usesound/toolspeed

This commit is contained in:
Markolie
2017-03-07 16:46:28 +01:00
parent 3b73053bc4
commit 3aa1399995
179 changed files with 875 additions and 764 deletions
+1 -1
View File
@@ -61,7 +61,7 @@
/obj/machinery/arcade/attackby(var/obj/item/O as obj, var/mob/user as mob, params)
if(istype(O, /obj/item/weapon/screwdriver) && anchored)
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, O.usesound, 50, 1)
panel_open = !panel_open
to_chat(user, "You [panel_open ? "open" : "close"] the maintenance panel.")
update_icon()
+1 -1
View File
@@ -41,7 +41,7 @@
to_chat(user, "<span class='warning'>\The [T] seems stuck to your hand!</span>")
return
if(istype(O, /obj/item/weapon/screwdriver) && anchored)
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, O.usesound, 50, 1)
panel_open = !panel_open
to_chat(user, "You [panel_open ? "open" : "close"] the maintenance panel.")
update_icon()
+2
View File
@@ -10,6 +10,8 @@
throw_speed = 3
throw_range = 10
origin_tech = "magnets=1"
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
var/bomb_name = "bomb" // used for naming bombs / mines
+2 -2
View File
@@ -201,7 +201,7 @@ BLIND // can't see anything
/obj/item/clothing/gloves/attackby(obj/item/weapon/W, mob/user, params)
if(istype(W, /obj/item/weapon/wirecutters))
if(!clipped)
playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1)
playsound(src.loc, W>usesound, 100, 1)
user.visible_message("<span class='warning'>[user] snips the fingertips off [src].</span>","<span class='warning'>You snip the fingertips off [src].</span>")
clipped = 1
name = "mangled [name]"
@@ -399,7 +399,7 @@ BLIND // can't see anything
if(istype(I, /obj/item/weapon/wirecutters))
if(can_cut_open)
if(!cut_open)
playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1)
playsound(src.loc, I.usesound, 100, 1)
user.visible_message("<span class='warning'>[user] cuts open the toes of [src].</span>","<span class='warning'>You cut open the toes of [src].</span>")
cut_open = 1
icon_state = "[icon_state]_opentoe"
+1 -1
View File
@@ -78,7 +78,7 @@
if(istype(W, /obj/item/weapon/wirecutters))
if(can_be_cut && icon_state == initial(icon_state))//only if not dyed
to_chat(user, "<span class='notice'>You snip the fingertips off of [src].</span>")
playsound(user.loc,'sound/items/Wirecutter.ogg', rand(10,50), 1)
playsound(user.loc, W.usesound, rand(10,50), 1)
var/obj/item/clothing/gloves/fingerless/F = new/obj/item/clothing/gloves/fingerless(user.loc)
if(pickpocket)
F.pickpocket = 1
@@ -13,6 +13,8 @@
desc = "It looks pretty sciency."
icon = 'icons/obj/rig_modules.dmi'
icon_state = "module"
toolspeed = 1
var/damage = 0
var/obj/item/weapon/rig/holder
@@ -73,7 +75,7 @@
to_chat(user, "You start mending the damaged portions of \the [src]...")
if(!do_after(user,30, target = src) || !W || !src)
if(!do_after(user, 30 * W.toolspeed, target = src) || !W || !src)
return
var/obj/item/stack/nanopaste/paste = W
@@ -98,7 +100,7 @@
return
to_chat(user, "You start mending the damaged portions of \the [src]...")
if(!do_after(user, 30, target = src) || !W || !src)
if(!do_after(user, 30 * W.toolspeed, target = src) || !W || !src)
return
damage = 1
+1 -1
View File
@@ -1025,7 +1025,7 @@
if(!can_touch(user, wearer) || !has_emergency_release)
return can_touch(user,wearer)
usr.visible_message("<span class='warning'>[user] starts activating \the [src] emergency seals release!</span>")
if(!do_after(user,240, target = wearer))
if(!do_after(user, 240, target = wearer))
to_chat(user, "<span class='notice'>You need to focus on activating the emergency release.</span>")
return 0
usr.visible_message("<span class='warning'>[user] activated \the [src] emergency seals release!</span>")
@@ -80,7 +80,7 @@
var/obj/item/rig_module/mod = W
to_chat(user, "You begin installing \the [mod] into \the [src].")
if(!do_after(user,40, target = src))
if(!do_after(user, 40 * W.toolspeed, target = src))
return
if(!user || !W)
return
@@ -65,7 +65,7 @@
var/obj/item/clothing/under/U = H.w_uniform
if(istype(U))
user.visible_message("<span class='notice'>[user] is putting a [src.name] on [H]'s [U.name]!</span>", "<span class='notice'>You begin to put a [src.name] on [H]'s [U.name]...</span>")
if(do_after(user,40,target=H) && H.w_uniform == U)
if(do_after(user, 40, target=H) && H.w_uniform == U)
user.visible_message("<span class='notice'>[user] puts a [src.name] on [H]'s [U.name]!</span>", "<span class='notice'>You finish putting a [src.name] on [H]'s [U.name].</span>")
U.attackby(src, user)
else
+27 -23
View File
@@ -18,6 +18,8 @@
var/frame_desc = null
var/datum/file/program/OS = new/datum/file/program/ntos
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
/obj/machinery/computer3/proc/disassemble(mob/user as mob) // todo
return
@@ -30,6 +32,8 @@
icon = 'icons/obj/stock_parts.dmi'
icon_state = "0"
var/state = 0
var/remove_sound = 'sound/items/Crowbar.ogg'
var/obj/item/part/computer/circuitboard/circuit = null
var/completed = /obj/machinery/computer
@@ -80,8 +84,8 @@
switch(state)
if(0)
if(istype(P, /obj/item/weapon/wrench))
playsound(src.loc, 'sound/items/Ratchet.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(src.loc, P.usesound, 50, 1)
if(do_after(user, 20 * P.toolspeed, target = src))
to_chat(user, "\blue You wrench the frame into place.")
src.anchored = 1
src.state = 1
@@ -90,23 +94,23 @@
if(!WT.remove_fuel(0, user))
to_chat(user, "The welding tool must be on to complete this task.")
return
playsound(src.loc, 'sound/items/Welder.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(src.loc, WT.usesound, 50, 1)
if(do_after(user, 20 * WT.toolspeed, target = src))
if(!src || !WT.isOn()) return
to_chat(user, "\blue You deconstruct the frame.")
new /obj/item/stack/sheet/metal( src.loc, 5 )
qdel(src)
if(1)
if(istype(P, /obj/item/weapon/wrench))
playsound(src.loc, 'sound/items/Ratchet.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(src.loc, P.usesound, 50, 1)
if(do_after(user, 20 * P.toolspeed, target = src))
to_chat(user, "\blue You unfasten the frame.")
src.anchored = 0
src.state = 0
if(istype(P, /obj/item/weapon/circuitboard) && !circuit)
var/obj/item/weapon/circuitboard/B = P
if(B.board_type == "computer")
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
playsound(src.loc, B.usesound, 50, 1)
to_chat(user, "\blue You place the circuit board inside the frame.")
src.icon_state = "1"
src.circuit = P
@@ -115,12 +119,12 @@
else
to_chat(user, "\red This frame does not accept circuit boards of this type!")
if(istype(P, /obj/item/weapon/screwdriver) && circuit)
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, P.usesound, 50, 1)
to_chat(user, "\blue You screw the circuit board into place.")
src.state = 2
src.icon_state = "2"
if(istype(P, /obj/item/weapon/crowbar) && circuit)
playsound(src.loc, 'sound/items/Crowbar.ogg', 50, 1)
playsound(src.loc, P.usesound, 50, 1)
to_chat(user, "\blue You remove the circuit board.")
src.state = 1
src.icon_state = "0"
@@ -128,15 +132,15 @@
src.circuit = null
if(2)
if(istype(P, /obj/item/weapon/screwdriver) && circuit)
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, P.usesound, 50, 1)
to_chat(user, "\blue You unfasten the circuit board.")
src.state = 1
src.icon_state = "1"
if(istype(P, /obj/item/weapon/crowbar))
if(battery)
playsound(src.loc, 'sound/items/Crowbar.ogg', 50, 1)
if(do_after(10, target = src))
playsound(src.loc, P.usesound, 50, 1)
if(do_after(10 * P.toolspeed, target = src))
battery.loc = loc
to_chat(user, "\blue You remove [battery].")
battery = null
@@ -145,8 +149,8 @@
if(istype(P, /obj/item/weapon/stock_parts/cell))
if(!battery)
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
if(do_after(5, target = src))
playsound(src.loc, P.usesound, 50, 1)
if(do_after(5 * P.toolspeed, target = src))
battery = P
P.loc = src
to_chat(user, "\blue You insert [battery].")
@@ -156,8 +160,8 @@
if(istype(P, /obj/item/stack/cable_coil))
if(P:amount >= 5)
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(src.loc, P.usesound, 50, 1)
if(do_after(user, 20 * P.toolspeed, target = src))
if(P)
P:amount -= 5
if(!P:amount) qdel(P)
@@ -169,7 +173,7 @@
if(components.len)
to_chat(user, "There are parts in the way!")
return
playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1)
playsound(src.loc, P.usesound, 50, 1)
to_chat(user, "\blue You remove the cables.")
src.state = 2
src.icon_state = "2"
@@ -181,8 +185,8 @@
if(istype(P, /obj/item/stack/sheet/glass))
if(P:amount >= 2)
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(src.loc, P.usesound, 50, 1)
if(do_after(user, 20 * P.toolspeed, target = src))
if(P)
P:use(2)
to_chat(user, "\blue You put in the glass panel.")
@@ -190,13 +194,13 @@
src.icon_state = "4"
if(4)
if(istype(P, /obj/item/weapon/crowbar))
playsound(src.loc, 'sound/items/Crowbar.ogg', 50, 1)
playsound(src.loc, P.usesound, 50, 1)
to_chat(user, "\blue You remove the glass panel.")
src.state = 3
src.icon_state = "3"
new /obj/item/stack/sheet/glass( src.loc, 2 )
if(istype(P, /obj/item/weapon/screwdriver))
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, P.usesound, 50, 1)
to_chat(user, "\blue You connect the monitor.")
var/obj/machinery/computer3/B = new src.circuit.build_path ( src.loc, built=1 )
/*if(circuit.powernet) B:powernet = circuit.powernet
@@ -226,8 +230,8 @@
I = input(usr, "Remove which component?","Remove component", null) as null|obj in components
if(I)
playsound(src.loc, 'sound/items/Crowbar.ogg', 50, 1)
if(do_after(usr,25, target = src))
playsound(src.loc, remove_sound, 50, 1)
if(do_after(usr, 25, target = src))
if(I==hdd)
components -= hdd
hdd.loc = loc
+4 -2
View File
@@ -26,6 +26,8 @@
var/tattoo_r = 1 // RGB values for the body markings
var/tattoo_g = 1
var/tattoo_b = 1
toolspeed = 1
usesound = 'sound/items/Welder2.ogg'
/obj/item/device/fluff/tattoo_gun/attack(mob/living/carbon/M as mob, mob/user as mob)
if(user.a_intent == "harm")
@@ -61,7 +63,7 @@
else
user.visible_message("<span class='notice'>[user] begins to apply a [tattoo_name] [target] with the [src].</span>", "<span class='notice'>You begin to tattoo [target] with the [src]!</span>")
if(!do_after(user,30, target = M))
if(!do_after(user, 30 * toolspeed, target = M))
return
user.visible_message("<span class='notice'>[user] finishes the [tattoo_name] on [target].</span>", "<span class='notice'>You finish the [tattoo_name].</span>")
@@ -69,7 +71,7 @@
target.change_markings(tattoo_icon, "body")
target.change_marking_color(rgb(tattoo_r, tattoo_g, tattoo_b), "body")
playsound(src.loc, 'sound/items/Welder2.ogg', 20, 1)
playsound(src.loc, usesound, 20, 1)
used = 1
update_icon()
@@ -25,6 +25,7 @@
volume = 5
can_be_placed_into = null
flags = OPENCONTAINER | NOBLUDGEON
var/wipespeed = 30
/obj/item/weapon/reagent_containers/glass/rag/attack(atom/target as obj|turf|area, mob/user as mob , flag)
if(ismob(target) && target.reagents && reagents.total_volume)
@@ -39,7 +40,7 @@
if(!proximity) return
if(istype(A) && src in user)
user.visible_message("[user] starts to wipe down [A] with [src]!")
if(do_after(user,30, target = A))
if(do_after(user, wipespeed, target = A))
user.visible_message("[user] finishes wiping off the [A]!")
A.clean_blood()
return
+4 -3
View File
@@ -606,6 +606,7 @@
if(user.a_intent == I_HELP)
if(W.isOn())
if(cur_health < max_health)
playsound(loc, W.usesound, 50, 1)
to_chat(usr, "You repair some of the cracks on \the [src].")
cur_health += 20
check_health()
@@ -613,7 +614,7 @@
to_chat(usr, "There is no damage to fix!")
else
if(cur_health < max_health)
to_chat(usr, "[W.name] must on to repair this damage.")
to_chat(usr, "[W.name] must be on to repair this damage.")
else
user.changeNext_move(CLICK_CD_MELEE)
hit(W.force)
@@ -672,8 +673,8 @@
if(istype(O, /obj/item/weapon/wrench))
if(water_level == 0)
to_chat(usr, "<span class='notice'>Now disassembling [src].</span>")
playsound(src.loc, 'sound/items/Ratchet.ogg', 50, 1)
if(do_after(user,50, target = src))
playsound(src.loc, O.usesound, 50, 1)
if(do_after(user, 50 * O.toolspeed, target = src))
destroy(1)
else
to_chat(usr, "[src] must be empty before you disassemble it!")
@@ -41,7 +41,7 @@
/obj/machinery/bottler/attackby(obj/item/O, mob/user, params)
if(iswrench(O)) //This being before the canUnequip check allows borgs to (un)wrench bottlers in case they need move them to fix stuff
playsound(src, 'sound/items/Ratchet.ogg', 50, 1)
playsound(src, O.usesound, 50, 1)
if(anchored)
anchored = 0
to_chat(user, "<span class='alert'>[src] can now be moved.</span>")
@@ -65,7 +65,7 @@
if(exchange_parts(user, O))
return
if(!broken && istype(O, /obj/item/weapon/wrench))
playsound(src, 'sound/items/Ratchet.ogg', 50, 1)
playsound(src, O.usesound, 50, 1)
if(anchored)
anchored = 0
to_chat(user, "<span class='alert'>\The [src] can now be moved.</span>")
@@ -83,7 +83,7 @@
"<span class='notice'>[user] starts to fix part of \the [src].</span>", \
"<span class='notice'>You start to fix part of \the [src].</span>" \
)
if(do_after(user,20, target = src))
if(do_after(user, 20 * O.toolspeed, target = src))
user.visible_message( \
"<span class='notice'>[user] fixes part of \the [src].</span>", \
"<span class='notice'>You have fixed part of \the [src].</span>" \
@@ -94,7 +94,7 @@
"<span class='notice'>[user] starts to fix part of \the [src].</span>", \
"<span class='notice'>You start to fix part of \the [src].</span>" \
)
if(do_after(user,20, target = src))
if(do_after(user, 20 * O.toolspeed, target = src))
user.visible_message( \
"<span class='notice'>[user] fixes \the [src].</span>", \
"<span class='notice'>You have fixed \the [src].</span>" \
@@ -112,7 +112,7 @@
"<span class='notice'>[user] starts to clean \the [src].</span>", \
"<span class='notice'>You start to clean \the [src].</span>" \
)
if(do_after(user,20, target = src))
if(do_after(user, 20 * O.toolspeed, target = src))
user.visible_message( \
"<span class='notice'>[user] has cleaned \the [src].</span>", \
"<span class='notice'>You have cleaned \the [src].</span>" \
+8 -8
View File
@@ -874,8 +874,8 @@
if(!anchored && !isinspace())
user.visible_message("[user] begins to wrench [src] into place.", "<span class='notice'>You begin to wrench [src] in place...</span>")
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
if (do_after(user, 20, target = src))
playsound(loc, O.usesound, 50, 1)
if (do_after(user, 20 * O.toolspeed, target = src))
if(anchored)
return
anchored = 1
@@ -884,8 +884,8 @@
else if(anchored)
user.visible_message("[user] begins to unwrench [src].", \
"<span class='notice'>You begin to unwrench [src]...</span>")
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
if (do_after(user, 20, target = src))
playsound(loc, O.usesound, 50, 1)
if (do_after(user, 20 * O.toolspeed, target = src))
if(!anchored)
return
anchored = 0
@@ -894,7 +894,7 @@
else if(iswirecutter(O) && wrenchable)
using_irrigation = !using_irrigation
playsound(src, 'sound/items/Wirecutter.ogg', 50, 1)
playsound(src, O.usesound, 50, 1)
user.visible_message("<span class='notice'>[user] [using_irrigation ? "" : "dis"]connects [src]'s irrigation hoses.</span>", \
"<span class='notice'>You [using_irrigation ? "" : "dis"]connect [src]'s irrigation hoses.</span>")
for(var/obj/machinery/hydroponics/h in range(1,src))
@@ -905,11 +905,11 @@
to_chat(user, "<span class='warning'>[src] doesn't have any plants or weeds!</span>")
return
user.visible_message("<span class='notice'>[user] starts digging out [src]'s plants...</span>", "<span class='notice'>You start digging out [src]'s plants...</span>")
playsound(src, 'sound/effects/shovel_dig.ogg', 50, 1)
if(!do_after(user, 50, target = src) || (!myseed && !weedlevel))
playsound(src, O.usesound, 50, 1)
if(!do_after(user, 25 * O.toolspeed, target = src) || (!myseed && !weedlevel))
return
user.visible_message("<span class='notice'>[user] digs out the plants in [src]!</span>", "<span class='notice'>You dig out all of [src]'s plants!</span>")
playsound(src, 'sound/effects/shovel_dig.ogg', 50, 1)
playsound(src, O.usesound, 50, 1)
if(myseed) //Could be that they're just using it as a de-weeder
age = 0
plant_health = 0
+5 -5
View File
@@ -31,7 +31,7 @@
I.forceMove(src)
update_icon()
/obj/structure/bookcase/attackby(obj/O as obj, mob/user as mob, params)
/obj/structure/bookcase/attackby(obj/item/O as obj, mob/user as mob, params)
if(busy) //So that you can't mess with it while deconstructing
return 1
if(is_type_in_list(O, allowed_books))
@@ -51,11 +51,11 @@
else if(istype(O, /obj/item/weapon/wrench))
user.visible_message("<span class='warning'>[user] starts disassembling \the [src].</span>", \
"<span class='notice'>You start disassembling \the [src].</span>")
playsound(get_turf(src), 'sound/items/Ratchet.ogg', 50, 1)
playsound(get_turf(src), O.usesound, 50, 1)
busy = 1
if(do_after(user,50, target = src))
playsound(get_turf(src), 'sound/items/Deconstruct.ogg', 75, 1)
if(do_after(user, 50 * O.toolspeed, target = src))
playsound(get_turf(src), O.usesound, 75, 1)
user.visible_message("<span class='warning'>[user] disassembles \the [src].</span>", \
"<span class='notice'>You disassemble \the [src].</span>")
busy = 0
@@ -276,7 +276,7 @@
if(carved)
return 1
to_chat(user, "<span class='notice'>You begin to carve out [title].</span>")
if(do_after(user, 30, target = src))
if(do_after(user, 30 * W.toolspeed, target = src))
to_chat(user, "<span class='notice'>You carve out the pages from [title]! You didn't want to read it anyway.</span>")
carved = 1
return 1
+28 -21
View File
@@ -89,6 +89,8 @@
sharp = 1
edge = 1
var/excavation_amount = 100
usesound = 'sound/effects/picaxe1.ogg'
toolspeed = 1
/obj/item/weapon/pickaxe/proc/playDigSound()
playsound(src, pick(digsound),20,1)
@@ -100,6 +102,16 @@
digspeed = 30 //mines faster than a normal pickaxe, bought from mining vendor
origin_tech = "materials=3;engineering=2"
desc = "A silver-plated pickaxe that mines slightly faster than standard-issue."
toolspeed = 0.75
/obj/item/weapon/pickaxe/gold
name = "golden pickaxe"
icon_state = "gpickaxe"
item_state = "gpickaxe"
digspeed = 20
origin_tech = "materials=4;engineering=2"
desc = "A gold-plated pickaxe that mines faster than standard-issue."
toolspeed = 0.6
/obj/item/weapon/pickaxe/diamond
name = "diamond-tipped pickaxe"
@@ -108,6 +120,7 @@
digspeed = 20 //mines twice as fast as a normal pickaxe, bought from mining vendor
origin_tech = "materials=4;engineering=3"
desc = "A pickaxe with a diamond pick head. Extremely robust at cracking rock walls and digging up dirt."
toolspeed = 0.5
/obj/item/weapon/pickaxe/drill
name = "mining drill"
@@ -116,8 +129,10 @@
digspeed = 25 //available from roundstart, faster than a pickaxe.
digsound = list('sound/weapons/drill.ogg')
hitsound = 'sound/weapons/drill.ogg'
usesound = 'sound/weapons/drill.ogg'
origin_tech = "materials=2;powerstorage=3;engineering=2"
desc = "An electric mining drill for the especially scrawny."
toolspeed = 0.5
/obj/item/weapon/pickaxe/drill/cyborg
name = "cyborg mining drill"
@@ -130,6 +145,7 @@
digspeed = 10
origin_tech = "materials=6;powerstorage=4;engineering=5"
desc = "Yours is the drill that will pierce the heavens!"
toolspeed = 0.25
/obj/item/weapon/pickaxe/diamonddrill/traitor //Pocket-sized traitor diamond drill.
name = "supermatter drill"
@@ -142,6 +158,7 @@
name = "diamond-tipped cyborg mining drill" //To inherit the NODROP flag, and easier to change borg specific drill mechanics.
icon_state = "diamonddrill"
digspeed = 10
toolspeed = 0.25
/obj/item/weapon/pickaxe/drill/jackhammer
name = "sonic jackhammer"
@@ -151,23 +168,10 @@
origin_tech = "materials=3;powerstorage=2;engineering=2"
digsound = list('sound/weapons/sonic_jackhammer.ogg')
hitsound = 'sound/weapons/sonic_jackhammer.ogg'
usesound = 'sound/weapons/sonic_jackhammer.ogg'
desc = "Cracks rocks with sonic blasts, and doubles as a demolition power tool for smashing walls."
toolspeed = 0.1
/obj/item/weapon/pickaxe/silver
name = "silver pickaxe"
icon_state = "spickaxe"
item_state = "spickaxe"
digspeed = 30
origin_tech = "materials=3"
desc = "This makes no metallurgic sense."
/obj/item/weapon/pickaxe/gold
name = "golden pickaxe"
icon_state = "gpickaxe"
item_state = "gpickaxe"
digspeed = 20
origin_tech = "materials=4"
desc = "This makes no metallurgic sense."
/*****************************Shovel********************************/
/obj/item/weapon/shovel
@@ -184,6 +188,8 @@
materials = list(MAT_METAL=50)
origin_tech = "materials=1;engineering=1"
attack_verb = list("bashed", "bludgeoned", "thrashed", "whacked")
usesound = 'sound/effects/shovel_dig.ogg'
toolspeed = 1
/obj/item/weapon/shovel/spade
name = "spade"
@@ -193,6 +199,7 @@
force = 5.0
throwforce = 7.0
w_class = 2
toolspeed = 2
/**********************Mining car (Crate like thing, not the rail car)**************************/
@@ -393,10 +400,10 @@
/obj/item/device/gps/computer/attackby(obj/item/weapon/W, mob/user, params)
if(istype(W, /obj/item/weapon/wrench))
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
playsound(loc, W.usesound, 50, 1)
user.visible_message("<span class='warning'>[user] disassembles the gps.</span>", \
"<span class='notice'>You start to disassemble the gps...</span>", "You hear clanking and banging noises.")
if(do_after(user, 20, target = src))
if(do_after(user, 20 * W.toolspeed, target = src))
new /obj/item/device/gps(loc)
qdel(src)
return ..()
@@ -471,10 +478,10 @@
/obj/structure/fans/attackby(obj/item/weapon/W, mob/user, params)
if(istype(W, /obj/item/weapon/wrench))
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
playsound(loc, W.usesound, 50, 1)
user.visible_message("<span class='warning'>[user] disassembles the fan.</span>", \
"<span class='notice'>You start to disassemble the fan...</span>", "You hear clanking and banging noises.")
if(do_after(user, 20, target = src))
if(do_after(user, 20 * W.toolspeed, target = src))
deconstruct()
return ..()
@@ -522,10 +529,10 @@
/obj/structure/tubes/attackby(obj/item/weapon/W, mob/user, params)
if(istype(W, /obj/item/weapon/wrench))
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
playsound(loc, W.usesound, 50, 1)
user.visible_message("<span class='warning'>[user] disassembles [src].</span>", \
"<span class='notice'>You start to disassemble [src]...</span>", "You hear clanking and banging noises.")
if(do_after(user, 20, target = src))
if(do_after(user, 20 * W.toolspeed, target = src))
new /obj/item/stack/rods(loc)
qdel(src)
return ..()
+7 -10
View File
@@ -470,14 +470,14 @@ var/global/list/rockTurfEdgeCache = list(
src.gets_dug()
return
/turf/simulated/floor/plating/airless/asteroid/attackby(obj/item/weapon/W as obj, mob/user as mob, params)
/turf/simulated/floor/plating/airless/asteroid/attackby(obj/item/weapon/W, mob/user, params)
//note that this proc does not call ..()
if(!W || !user)
return 0
if((istype(W, /obj/item/weapon/shovel)))
var/turf/T = user.loc
if(!( istype(T, /turf) ))
var/turf/T = get_turf(user)
if(!istype(T))
return
if(dug)
@@ -485,17 +485,15 @@ var/global/list/rockTurfEdgeCache = list(
return
to_chat(user, "<span class='notice'>You start digging...</span>")
sleep(20)
if((user.loc == T && user.get_active_hand() == W))
if(do_after(user, 20 * W.toolspeed, target = src))
to_chat(user, "<span class='notice'>You dig a hole.</span>")
gets_dug()
return
if((istype(W, /obj/item/weapon/pickaxe)))
var/obj/item/weapon/pickaxe/P = W
var/turf/T = user.loc
if(!( istype(T, /turf) ))
var/turf/T = get_turf(user)
if(!istype(T))
return
if(dug)
@@ -504,8 +502,7 @@ var/global/list/rockTurfEdgeCache = list(
to_chat(user, "<span class='notice'>You start digging...</span>")
sleep(P.digspeed)
if((user.loc == T && user.get_active_hand() == W))
if(do_after(user, P.digspeed, target = src))
to_chat(user, "<span class='notice'>You dig a hole.</span>")
gets_dug()
return
@@ -86,7 +86,7 @@
custom_emote(1, "[src]'s chest opens up, revealing a large mass of explosives and tangled wires!")
if(inactivity_period <= 0)
inactivity_period = 9999 // technically infinite
if(do_after(src, 60, target=traitorTarget))
if(do_after(src, 60, target = traitorTarget))
custom_emote(1, "A fire bursts from [src]'s eyes, igniting white hot and consuming their body in a flaming explosion!")
explosion(src, 6, 6, 6)
else
@@ -66,21 +66,21 @@
M.visible_message("<span class='notice'>[M] begins to violently pull off [H]'s antennae.</span>")
to_chat(H, "<span class='danger'><B>[M] grips your antennae and starts violently pulling!<B></span>")
do_after(H, 250, target = src)
if(p_loc == M.loc && p_loc_m == H.loc)
var/obj/item/organ/internal/wryn/hivenode/node = new /obj/item/organ/internal/wryn/hivenode
H.remove_language("Wryn Hivemind")
node.remove(H)
node.loc = M.loc
to_chat(M, "<span class='notice'>You hear a loud crunch as you mercilessly pull off [H]'s antennae.</span>")
to_chat(H, "<span class='danger'><B>You hear a loud crunch as your antennae is ripped off your head by [M].</span></B>")
to_chat(H, "<span class='danger'><span class='danger'><B>It's so quiet...</B></span>")
head_organ.h_style = "Bald"
H.update_hair()
if(do_after(H, 250, target = src))
if(p_loc == M.loc && p_loc_m == H.loc)
var/obj/item/organ/internal/wryn/hivenode/node = new /obj/item/organ/internal/wryn/hivenode
H.remove_language("Wryn Hivemind")
node.remove(H)
node.loc = M.loc
to_chat(M, "<span class='notice'>You hear a loud crunch as you mercilessly pull off [H]'s antennae.</span>")
to_chat(H, "<span class='danger'><B>You hear a loud crunch as your antennae is ripped off your head by [M].</span></B>")
to_chat(H, "<span class='danger'><span class='danger'><B>It's so quiet...</B></span>")
head_organ.h_style = "Bald"
H.update_hair()
M.create_attack_log("<font color='red'>removed antennae [H.name] ([H.ckey])</font>")
H.create_attack_log("<font color='orange'>Has had their antennae removed by [M.name] ([M.ckey])</font>")
msg_admin_attack("[key_name(M)] removed [key_name(H)]'s antennae")
M.create_attack_log("<font color='red'>removed antennae [H.name] ([H.ckey])</font>")
H.create_attack_log("<font color='orange'>Has had their antennae removed by [M.name] ([M.ckey])</font>")
msg_admin_attack("[key_name(M)] removed [key_name(H)]'s antennae")
return 0
/datum/species/nucleation
+2 -2
View File
@@ -1062,7 +1062,7 @@ var/list/ai_verbs_default = list(
if(istype(W, /obj/item/weapon/wrench))
if(anchored)
user.visible_message("\blue \The [user] starts to unbolt \the [src] from the plating...")
if(!do_after(user,40, target = src))
if(!do_after(user, 40 * W.toolspeed, target = src))
user.visible_message("\blue \The [user] decides not to unbolt \the [src].")
return
user.visible_message("\blue \The [user] finishes unfastening \the [src]!")
@@ -1070,7 +1070,7 @@ var/list/ai_verbs_default = list(
return
else
user.visible_message("\blue \The [user] starts to bolt \the [src] to the plating...")
if(!do_after(user,40, target = src))
if(!do_after(user, 40 * W.toolspeed, target = src))
user.visible_message("\blue \The [user] decides not to bolt \the [src].")
return
user.visible_message("\blue \The [user] finishes fastening down \the [src]!")
@@ -203,7 +203,7 @@
to_chat(D, "<span class='warning'>You begin decompiling the other drone.</span>")
if(!do_after(D,50, target = target))
if(!do_after(D, 50, target = target))
to_chat(D, "<span class='warning'>You need to remain still while decompiling such a large object.</span>")
return
@@ -617,7 +617,7 @@ var/list/robot_verbs_default = list(
var/obj/item/weapon/weldingtool/WT = W
user.changeNext_move(CLICK_CD_MELEE)
if(WT.remove_fuel(0))
playsound(src.loc, 'sound/items/Welder2.ogg', 50, 1)
playsound(src.loc, W.usesound, 50, 1)
adjustBruteLoss(-30)
updatehealth()
add_fingerprint(user)
@@ -651,7 +651,7 @@ var/list/robot_verbs_default = list(
return
to_chat(user, "You jam the crowbar into the robot and begin levering [mmi].")
if(do_after(user,3 SECONDS, target = src))
if(do_after(user, 30 * W.toolspeed, target = src))
to_chat(user, "You damage some parts of the chassis, but eventually manage to rip out [mmi]!")
var/obj/item/robot_parts/robot_suit/C = new/obj/item/robot_parts/robot_suit(loc)
C.l_leg = new/obj/item/robot_parts/l_leg(C)
@@ -326,7 +326,7 @@
to_chat(user, "<span class='warning'>Close the access panel before manipulating the personality slot!</span>")
else
to_chat(user, "<span class='notice'>You attempt to pull [paicard] free...</span>")
if(do_after(user, 30, target = src))
if(do_after(user, 30 * W.toolspeed, target = src))
if(paicard)
user.visible_message("<span class='notice'>[user] uses [W] to pull [paicard] out of [bot_name]!</span>","<span class='notice'>You pull [paicard] out of [bot_name] with [W].</span>")
ejectpai(user)
@@ -139,10 +139,11 @@
to_chat(user, "<span class='warning'>You need one length of cable to wire the ED-209!</span>")
return
to_chat(user, "<span class='notice'>You start to wire [src]...</span>")
if(do_after(user, 40, target = src))
if(do_after(user, 40 * W.toolspeed, target = src))
if(coil.get_amount() >= 1 && build_step == 6)
coil.use(1)
build_step = 7
playsound(loc, W.usesound, 50, 1)
to_chat(user, "<span class='notice'>You wire the ED-209 assembly.</span>")
name = "wired ED-209 assembly"
@@ -174,9 +175,9 @@
if(8)
if(istype(W, /obj/item/weapon/screwdriver))
playsound(loc, 'sound/items/Screwdriver.ogg', 100, 1)
playsound(loc, W.usesound, 100, 1)
to_chat(user, "<span class='notice'>You start attaching the gun to the frame...</span>")
if(do_after(user, 40, target = src))
if(do_after(user, 40 * W.toolspeed, target = src))
build_step++
name = "armed [name]"
to_chat(user, "<span class='notice'>Taser gun attached.</span>")
@@ -87,9 +87,9 @@
to_chat(user, "<span class='warning'>You can't shave this corgi, it's already been shaved!</span>")
return
user.visible_message("[user] starts to shave [src] using \the [O].", "<span class='notice'>You start to shave [src] using \the [O]...</span>")
if(do_after(user, 50, target = src))
if(do_after(user, 50 * O.toolspeed, target = src))
user.visible_message("[user] shaves [src]'s hair using \the [O].")
playsound(loc, 'sound/items/Welder2.ogg', 20, 1)
playsound(loc, O.usesound, 20, 1)
shaved = 1
icon_living = "[initial(icon_living)]_shaved"
icon_dead = "[initial(icon_living)]_shaved_dead"
+1 -1
View File
@@ -1057,7 +1057,7 @@ var/list/slot_equipment_priority = list( \
visible_implants += O
return visible_implants
mob/proc/yank_out_object()
/mob/proc/yank_out_object()
set category = "Object"
set name = "Yank out object"
set desc = "Remove an embedded item at the cost of bleeding and pain."
+1 -1
View File
@@ -6,7 +6,7 @@
var/obj/item/weapon/stock_parts/cell/CELL
if(CELL.maxcharge > cell.maxcharge && suitGloves)
to_chat(U, "<span class='notice'>Higher maximum capacity detected.\nUpgrading...</span>")
if(n_gloves && n_gloves.candrain && do_after(U,s_delay, target = U))
if(n_gloves && n_gloves.candrain && do_after(U, s_delay, target = U))
U.drop_item()
CELL.loc = src
CELL.charge = min(CELL.charge+cell.charge, CELL.maxcharge)
+1 -1
View File
@@ -43,7 +43,7 @@
icon_state = initial(icon_state)
updateUsrDialog()
else if(istype(P, /obj/item/weapon/wrench))
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
playsound(loc, P.usesound, 50, 1)
anchored = !anchored
to_chat(user, "<span class='notice'>You [anchored ? "wrench" : "unwrench"] \the [src].</span>")
else
+8 -6
View File
@@ -3,6 +3,8 @@
desc = "Its patented design allows it to be folded larger or smaller to accommodate standard paper, photo, and poster, and canvas sizes."
icon = 'icons/obj/bureaucracy.dmi'
usesound = 'sound/items/Deconstruct.ogg'
var/icon_base
var/obj/displayed
@@ -58,7 +60,7 @@
/obj/item/weapon/picture_frame/attackby(obj/item/I, mob/user)
if(istype(I, /obj/item/weapon/screwdriver))
if(displayed)
playsound(src, 'sound/items/Screwdriver.ogg', 100, 1)
playsound(src, I.usesound, 100, 1)
user.visible_message("<span class=warning>[user] unfastens \the [displayed] out of \the [src].</span>", "<span class=warning>You unfasten \the [displayed] out of \the [src].</span>")
if(istype(displayed, /obj/structure/sign/poster))
@@ -72,7 +74,7 @@
else
to_chat(user, "<span class=notice>There is nothing to remove from \the [src].</span>")
else if(istype(I, /obj/item/weapon/crowbar))
playsound(src, 'sound/items/Crowbar.ogg', 100, 1)
playsound(src, I.usesound, 100, 1)
user.visible_message("<span class=warning>[user] breaks down \the [src].</span>", "<span class=warning>You break down \the [src].</span>")
for(var/A in contents)
if(istype(A, /obj/structure/sign/poster))
@@ -135,7 +137,7 @@
PF.pixel_x = px
PF.pixel_y = py
playsound(PF.loc, 'sound/items/Deconstruct.ogg', 100, 1)
playsound(PF.loc, usesound, 100, 1)
/obj/item/weapon/picture_frame/examine(mob/user, var/distance = -1, var/infix = "", var/suffix = "")
..()
@@ -213,10 +215,10 @@
/obj/structure/sign/picture_frame/attackby(obj/item/I, mob/user)
if(istype(I, /obj/item/weapon/screwdriver))
playsound(src, 'sound/items/Screwdriver.ogg', 100, 1)
playsound(src, I.usesound, 100, 1)
user.visible_message("<span class=warning>[user] begins to unfasten \the [src] from the wall.</span>", "<span class=warning>You begin to unfasten \the [src] from the wall.</span>")
if(do_after(user, 100, target = src))
playsound(src, 'sound/items/Deconstruct.ogg', 100, 1)
if(do_after(user, 100 * I.toolspeed, target = src))
playsound(src, I.usesound, 100, 1)
user.visible_message("<span class=warning>[user] unfastens \the [src] from the wall.</span>", "<span class=warning>You unfasten \the [src] from the wall.</span>")
frame.forceMove(user.loc)
frame = null
+1 -1
View File
@@ -150,7 +150,7 @@
else
to_chat(user, "<span class='notice'>This cartridge is not yet ready for replacement! Use up the rest of the toner.</span>")
else if(istype(O, /obj/item/weapon/wrench))
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
playsound(loc, O.usesound, 50, 1)
anchored = !anchored
to_chat(user, "<span class='notice'>You [anchored ? "wrench" : "unwrench"] \the [src].</span>")
else if(istype(O, /obj/item/weapon/grab)) //For ass-copying.
+16 -13
View File
@@ -126,6 +126,8 @@
w_class = 2
item_state = "electronic"
flags = CONDUCT
usesound = 'sound/items/Deconstruct.ogg'
toolspeed = 1
/obj/machinery/power/apc/connect_to_network()
//Override because the APC does not directly connect to the network; it goes through a terminal.
@@ -431,10 +433,10 @@
if(terminal)
to_chat(user, "<span class='warning'>Disconnect wires first.</span>")
return
playsound(src.loc, 'sound/items/Crowbar.ogg', 50, 1)
playsound(src.loc, W.usesound, 50, 1)
to_chat(user, "You are trying to remove the power control board...")//lpeters - fixed grammar issues
if(do_after(user, 50, target = src))
if(do_after(user, 50 * W.toolspeed, target = src))
if(has_electronics==1)
has_electronics = 0
if((stat & BROKEN) || malfhack)
@@ -472,6 +474,7 @@
user.visible_message(\
"<span class='warning'>[user.name] has inserted the power cell to [src.name]!</span>",\
"You insert the power cell.")
playsound(loc, W.usesound, 50, 1)
chargecount = 0
update_icon()
else if(istype(W, /obj/item/weapon/screwdriver)) // haxing
@@ -484,12 +487,12 @@
if(has_electronics==1 && terminal)
has_electronics = 2
stat &= ~MAINT
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, W.usesound, 50, 1)
to_chat(user, "You screw the circuit electronics into place.")
else if(has_electronics==2)
has_electronics = 1
stat |= MAINT
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, W.usesound, 50, 1)
to_chat(user, "You unfasten the electronics.")
else /* has_electronics==0 */
to_chat(user, "<span class='warning'>There is nothing to secure.</span>")
@@ -527,8 +530,8 @@
to_chat(user, "<span class='warning'>You need more wires.</span>")
return
to_chat(user, "You start adding cables to the APC frame...")
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(src.loc, C.usesound, 50, 1)
if(do_after(user, 20 * C.toolspeed, target = src))
if(C.amount >= 10 && !terminal && opened && has_electronics != 2)
var/turf/T = get_turf(src)
var/obj/structure/cable/N = T.get_cable_node()
@@ -548,8 +551,8 @@
to_chat(user, "<span class='warning'>You must remove the floor plating in front of the APC first.</span>")
return
to_chat(user, "You begin to cut the cables...")
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
if(do_after(user, 50, target = src))
playsound(src.loc, W.usesound, 50, 1)
if(do_after(user, 50 * W.toolspeed, target = src))
if(terminal && opened && has_electronics!=2)
if(prob(50) && electrocute_mob(usr, terminal.powernet, terminal))
var/datum/effect/system/spark_spread/s = new /datum/effect/system/spark_spread
@@ -561,8 +564,8 @@
qdel(terminal) // qdel
else if(istype(W, /obj/item/weapon/apc_electronics) && opened && has_electronics==0 && !((stat & BROKEN) || malfhack))
to_chat(user, "You trying to insert the power control board into the frame...")
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
if(do_after(user, 10, target = src))
playsound(src.loc, W.usesound, 50, 1)
if(do_after(user, 10 * W.toolspeed, target = src))
if(has_electronics==0)
has_electronics = 1
to_chat(user, "<span class='notice'>You place the power control board inside the frame.</span>")
@@ -578,8 +581,8 @@
user.visible_message("<span class='warning'>[user.name] welds [src].</span>", \
"You start welding the APC frame...", \
"You hear welding.")
playsound(src.loc, 'sound/items/Welder.ogg', 50, 1)
if(do_after(user, 50, target = src))
playsound(src.loc, WT.usesound, 50, 1)
if(do_after(user, 50 * WT.toolspeed, target = src))
if(!src || !WT.remove_fuel(3, user)) return
if(emagged || malfhack || (stat & BROKEN) || opened==2)
new /obj/item/stack/sheet/metal(loc)
@@ -609,7 +612,7 @@
to_chat(user, "You cannot repair this APC until you remove the electronics still inside.")
return
to_chat(user, "You begin to replace the damaged APC frame...")
if(do_after(user, 50, target = src))
if(do_after(user, 50 * W.toolspeed, target = src))
user.visible_message(\
"<span class='notice'>[user.name] has replaced the damaged APC frame with new one.</span>",\
"You replace the damaged APC frame with new one.")
+2
View File
@@ -480,6 +480,8 @@ var/global/list/datum/stack_recipe/cable_coil_recipes = list(
slot_flags = SLOT_BELT
item_state = "coil"
attack_verb = list("whipped", "lashed", "disciplined", "flogged")
usesound = 'sound/items/Deconstruct.ogg'
toolspeed = 1
/obj/item/stack/cable_coil/suicide_act(mob/user)
if(locate(/obj/structure/stool) in user.loc)
+1 -1
View File
@@ -166,7 +166,7 @@
power_change()
else
connect()
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
playsound(loc, W.usesound, 50, 1)
to_chat(user, "<span class='notice'>You [anchored ? "secure" : "unsecure"] the bolts holding [src] to the floor.</span>")
else if(ismultitool(W))
if(cold_dir == WEST)
+4 -4
View File
@@ -184,14 +184,14 @@ var/const/GRAV_NEEDS_WRENCH = 3
if(GRAV_NEEDS_SCREWDRIVER)
if(istype(I, /obj/item/weapon/screwdriver))
to_chat(user, "<span class='notice'>You secure the screws of the framework.</span>")
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
broken_state++
if(GRAV_NEEDS_WELDING)
if(istype(I, /obj/item/weapon/weldingtool))
var/obj/item/weapon/weldingtool/WT = I
if(WT.remove_fuel(1, user))
to_chat(user, "<span class='notice'>You mend the damaged framework.</span>")
playsound(src.loc, 'sound/items/Welder2.ogg', 50, 1)
playsound(src.loc, WT.usesound, 50, 1)
broken_state++
if(GRAV_NEEDS_PLASTEEL)
if(istype(I, /obj/item/stack/sheet/plasteel))
@@ -199,14 +199,14 @@ var/const/GRAV_NEEDS_WRENCH = 3
if(PS.amount >= 10)
PS.use(10)
to_chat(user, "<span class='notice'>You add the plating to the framework.</span>")
playsound(src.loc, 'sound/machines/click.ogg', 75, 1)
playsound(src.loc, PS.usesound, 75, 1)
broken_state++
else
to_chat(user, "<span class='notice'>You need 10 sheets of plasteel.</span>")
if(GRAV_NEEDS_WRENCH)
if(istype(I, /obj/item/weapon/wrench))
to_chat(user, "<span class='notice'>You secure the plating to the framework.</span>")
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc, I.usesound, 75, 1)
set_fix()
else
..()
+7 -6
View File
@@ -40,14 +40,14 @@
src.add_fingerprint(user)
if(istype(W, /obj/item/weapon/wrench))
if(src.stage == 1)
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc, W.usesound, 75, 1)
to_chat(usr, "You begin deconstructing [src].")
if(!do_after(usr, 30, target = src))
if(!do_after(usr, 30 * W.toolspeed, target = src))
return
new /obj/item/stack/sheet/metal( get_turf(src.loc), sheets_refunded )
user.visible_message("[user.name] deconstructs [src].", \
"You deconstruct [src].", "You hear a noise.")
playsound(src.loc, 'sound/items/Deconstruct.ogg', 75, 1)
playsound(src.loc, W.usesound, 75, 1)
qdel(src)
if(src.stage == 2)
to_chat(usr, "You have to remove the wires first.")
@@ -68,7 +68,7 @@
new /obj/item/stack/cable_coil(get_turf(src.loc), 1, COLOR_RED)
user.visible_message("[user.name] removes the wiring from [src].", \
"You remove the wiring from [src].", "You hear a noise.")
playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1)
playsound(loc, W.usesound, 100, 1)
return
if(istype(W, /obj/item/stack/cable_coil))
@@ -81,6 +81,7 @@
if("bulb")
src.icon_state = "bulb-construct-stage2"
src.stage = 2
playsound(loc, coil.usesound, 50, 1)
user.visible_message("[user.name] adds wires to [src].", \
"You add wires to [src].")
return
@@ -95,7 +96,7 @@
src.stage = 3
user.visible_message("[user.name] closes [src]'s casing.", \
"You close [src]'s casing.", "You hear a noise.")
playsound(src.loc, 'sound/items/Screwdriver.ogg', 75, 1)
playsound(src.loc, W.usesound, 75, 1)
switch(fixture_type)
@@ -348,7 +349,7 @@
// attempt to stick weapon into light socket
else if(status == LIGHT_EMPTY)
if(istype(W, /obj/item/weapon/screwdriver)) //If it's a screwdriver open it.
playsound(src.loc, 'sound/items/Screwdriver.ogg', 75, 1)
playsound(src.loc, W.usesound, 75, 1)
user.visible_message("[user.name] opens [src]'s casing.", \
"You open [src]'s casing.", "You hear a noise.")
var/obj/machinery/light_construct/newlight = null
+2 -2
View File
@@ -288,12 +288,12 @@
disconnect_from_network()
to_chat(user, "<span class='notice'>You unsecure the generator from the floor.</span>")
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
playsound(src.loc, O.usesound, 50, 1)
anchored = !anchored
else if(istype(O, /obj/item/weapon/screwdriver))
panel_open = !panel_open
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, O.usesound, 50, 1)
if(panel_open)
to_chat(user, "<span class='notice'>You open the access panel.</span>")
else
+1 -1
View File
@@ -74,7 +74,7 @@ var/global/list/rad_collectors = list()
if(P)
to_chat(user, "\blue Remove the plasma tank first.")
return 1
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc, W.usesound, 75, 1)
src.anchored = !src.anchored
user.visible_message("[user.name] [anchored? "secures":"unsecures"] the [src.name].", \
"You [anchored? "secure":"undo"] the external bolts.", \
+6 -6
View File
@@ -236,14 +236,14 @@
switch(state)
if(0)
state = 1
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc, W.usesound, 75, 1)
user.visible_message("[user.name] secures [src.name] to the floor.", \
"You secure the external reinforcing bolts to the floor.", \
"You hear a ratchet")
src.anchored = 1
if(1)
state = 0
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc,W.usesound, 75, 1)
user.visible_message("[user.name] unsecures [src.name] reinforcing bolts from the floor.", \
"You undo the external reinforcing bolts.", \
"You hear a ratchet")
@@ -262,11 +262,11 @@
to_chat(user, "\red The [src.name] needs to be wrenched to the floor.")
if(1)
if(WT.remove_fuel(0,user))
playsound(src.loc, 'sound/items/Welder2.ogg', 50, 1)
playsound(src.loc, WT.usesound, 50, 1)
user.visible_message("[user.name] starts to weld the [src.name] to the floor.", \
"You start to weld the [src] to the floor.", \
"You hear welding")
if(do_after(user,20, target = src))
if(do_after(user, 20 * WT.toolspeed, target = src))
if(!src || !WT.isOn()) return
state = 2
to_chat(user, "You weld the [src] to the floor.")
@@ -275,11 +275,11 @@
to_chat(user, "\red You need more welding fuel to complete this task.")
if(2)
if(WT.remove_fuel(0,user))
playsound(src.loc, 'sound/items/Welder2.ogg', 50, 1)
playsound(src.loc, WT.usesound, 50, 1)
user.visible_message("[user.name] starts to cut the [src.name] free from the floor.", \
"You start to cut the [src] free from the floor.", \
"You hear welding")
if(do_after(user,20, target = src))
if(do_after(user, 20 * WT.toolspeed, target = src))
if(!src || !WT.isOn()) return
state = 1
to_chat(user, "You cut the [src] free from the floor.")
@@ -87,14 +87,14 @@ field_generator power level display
if(FG_UNSECURED)
if(isinspace()) return
state = FG_SECURED
playsound(loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(loc, W.usesound, 75, 1)
user.visible_message("[user.name] secures [name] to the floor.", \
"<span class='notice'>You secure the external reinforcing bolts to the floor.</span>", \
"<span class='italics'>You hear ratchet.</span>")
anchored = 1
if(FG_SECURED)
state = FG_UNSECURED
playsound(loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(loc, W.usesound, 75, 1)
user.visible_message("[user.name] unsecures [name] reinforcing bolts from the floor.", \
"<span class='notice'>You undo the external reinforcing bolts.</span>", \
"<span class='italics'>You hear ratchet.</span>")
@@ -110,11 +110,11 @@ field_generator power level display
if(FG_SECURED)
if(WT.remove_fuel(0,user))
playsound(loc, 'sound/items/Welder2.ogg', 50, 1)
playsound(loc, WT.usesound, 50, 1)
user.visible_message("[user.name] starts to weld the [name] to the floor.", \
"<span class='notice'>You start to weld \the [src] to the floor...</span>", \
"<span class='italics'>You hear welding.</span>")
if(do_after(user,20, target = src))
if(do_after(user, 20 * WT.toolspeed, target = src))
if(!src || !WT.isOn())
return
state = FG_WELDED
@@ -122,11 +122,11 @@ field_generator power level display
if(FG_WELDED)
if(WT.remove_fuel(0,user))
playsound(loc, 'sound/items/Welder2.ogg', 50, 1)
playsound(loc, WT.usesound, 50, 1)
user.visible_message("[user.name] starts to cut the [name] free from the floor.", \
"<span class='notice'>You start to cut \the [src] free from the floor...</span>", \
"<span class='italics'>You hear welding.</span>")
if(do_after(user,20, target = src))
if(do_after(user, 20 * WT.toolspeed, target = src))
if(!src || !WT.isOn())
return
state = FG_SECURED
+1 -1
View File
@@ -23,7 +23,7 @@
/obj/machinery/the_singularitygen/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/weapon/wrench))
anchored = !anchored
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc, W.usesound, 75, 1)
if(anchored)
user.visible_message("[user.name] secures [src.name] to the floor.", \
"You secure the [src.name] to the floor.", \
@@ -214,7 +214,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
return 0
/obj/structure/particle_accelerator/proc/process_tool_hit(var/obj/O, var/mob/user)
/obj/structure/particle_accelerator/proc/process_tool_hit(var/obj/item/O, var/mob/user)
if(!(O) || !(user))
return 0
if(!ismob(user) || !isobj(O))
@@ -224,14 +224,14 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
switch(construction_state)//TODO:Might be more interesting to have it need several parts rather than a single list of steps
if(0)
if(iswrench(O) && !isinspace())
playsound(loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(loc, O.usesound, 50, 1)
anchored = 1
user.visible_message("[user.name] secures the [name] to the floor.", \
"You secure the external bolts.")
temp_state++
if(1)
if(iswrench(O))
playsound(loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(loc, O.usesound, 50, 1)
anchored = 0
user.visible_message("[user.name] detaches the [name] from the floor.", \
"You remove the external bolts.")
@@ -239,6 +239,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
else if(iscoil(O))
var/obj/item/stack/cable_coil/C = O
if(C.use(1))
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] adds wires to the [name].", \
"You add some wires.")
temp_state++
@@ -247,15 +248,18 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
return
if(2)
if(iswirecutter(O))//TODO:Shock user if its on?
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] removes some wires from the [name].", \
"You remove some wires.")
temp_state--
else if(isscrewdriver(O))
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] closes the [name]'s access panel.", \
"You close the access panel.")
temp_state++
if(3)
if(isscrewdriver(O))
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] opens the [name]'s access panel.", \
"You open the access panel.")
temp_state--
@@ -352,7 +356,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
return 0
/obj/machinery/particle_accelerator/proc/process_tool_hit(var/obj/O, var/mob/user)
/obj/machinery/particle_accelerator/proc/process_tool_hit(var/obj/item/O, var/mob/user)
if(!(O) || !(user))
return 0
if(!ismob(user) || !isobj(O))
@@ -361,7 +365,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
switch(construction_state)//TODO:Might be more interesting to have it need several parts rather than a single list of steps
if(0)
if(iswrench(O))
playsound(loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(loc, O.usesound, 50, 1)
anchored = 1
user.visible_message("[user.name] secures the [name] to the floor.", \
"You secure the external bolts.")
@@ -369,7 +373,7 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
power_change()
if(1)
if(iswrench(O))
playsound(loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(loc, O.usesound, 50, 1)
anchored = 0
user.visible_message("[user.name] detaches the [name] from the floor.", \
"You remove the external bolts.")
@@ -377,20 +381,24 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
power_change()
else if(iscoil(O))
if(O:use(1))
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] adds wires to the [name].", \
"You add some wires.")
temp_state++
if(2)
if(iswirecutter(O))//TODO:Shock user if its on?
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] removes some wires from the [name].", \
"You remove some wires.")
temp_state--
else if(isscrewdriver(O))
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] closes the [name]'s access panel.", \
"You close the access panel.")
temp_state++
if(3)
if(isscrewdriver(O))
playsound(loc, O.usesound, 50, 1)
user.visible_message("[user.name] opens the [name]'s access panel.", \
"You open the access panel.")
temp_state--
+2 -2
View File
@@ -180,9 +180,9 @@
return
to_chat(user, "<span class='notice'>You begin to dismantle the power terminal...</span>")
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
if(do_after(user, 50, target = src))
if(do_after(user, 50 * I.toolspeed, target = src))
if(prob(50) && electrocute_mob(usr, terminal.powernet, terminal)) //animate the electrocution if uncautious and unlucky
var/datum/effect/system/spark_spread/s = new /datum/effect/system/spark_spread
s.set_up(5, 1, src)
+9 -8
View File
@@ -60,12 +60,12 @@
if(istype(W, /obj/item/weapon/crowbar))
playsound(src.loc, 'sound/machines/click.ogg', 50, 1)
user.visible_message("[user] begins to take the glass off the solar panel.", "<span class='notice'>You begin to take the glass off the solar panel...</span>")
if(do_after(user, 50, target = src))
if(do_after(user, 50 * W.toolspeed, target = src))
var/obj/item/solar_assembly/S = locate() in src
if(S)
S.loc = src.loc
S.give_glass()
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
playsound(src.loc, W.usesound, 50, 1)
user.visible_message("[user] takes the glass off the solar panel.", "<span class='notice'>You take the glass off the solar panel.</span>")
qdel(src)
return
@@ -227,20 +227,20 @@
if(istype(W, /obj/item/weapon/wrench))
anchored = 1
user.visible_message("[user] wrenches the solar assembly into place.", "<span class='notice'>You wrench the solar assembly into place.</span>")
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc, W.usesound, 50, 1)
return 1
else
if(istype(W, /obj/item/weapon/wrench))
anchored = 0
user.visible_message("[user] unwrenches the solar assembly from its place.", "<span class='notice'>You unwrench the solar assembly from its place.</span>")
playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1)
playsound(src.loc, W.usesound, 50, 1)
return 1
if(istype(W, /obj/item/stack/sheet/glass) || istype(W, /obj/item/stack/sheet/rglass))
var/obj/item/stack/sheet/S = W
if(S.use(2))
glass_type = W.type
playsound(src.loc, 'sound/machines/click.ogg', 50, 1)
playsound(loc, S.usesound, 50, 1)
user.visible_message("[user] places the glass on the solar assembly.", "<span class='notice'>You place the glass on the solar assembly.</span>")
if(tracker)
new /obj/machinery/power/tracker(get_turf(src), src)
@@ -263,6 +263,7 @@
if(istype(W, /obj/item/weapon/crowbar))
new /obj/item/weapon/tracker_electronics(src.loc)
tracker = 0
playsound(loc, W.usesound, 50, 1)
user.visible_message("[user] takes out the electronics from the solar assembly.", "<span class='notice'>You take out the electronics from the solar assembly.</span>")
return 1
..()
@@ -411,10 +412,10 @@
return data
/obj/machinery/power/solar_control/attackby(I as obj, user as mob, params)
/obj/machinery/power/solar_control/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/weapon/screwdriver))
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(src.loc, I.usesound, 50, 1)
if(do_after(user, 20 * I.toolspeed, target = src))
if(src.stat & BROKEN)
to_chat(user, "<span class='notice'>The broken glass falls out.</span>")
var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc )
+2 -2
View File
@@ -63,12 +63,12 @@
if(istype(W, /obj/item/weapon/crowbar))
playsound(src.loc, 'sound/machines/click.ogg', 50, 1)
user.visible_message("<span class='notice'>[user] begins to take the glass off the solar tracker.</span>")
if(do_after(user, 50, target = src))
if(do_after(user, 50 * W.toolspeed, target = src))
var/obj/item/solar_assembly/S = locate() in src
if(S)
S.loc = src.loc
S.give_glass()
playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1)
playsound(src.loc, W.usesound, 50, 1)
user.visible_message("<span class='notice'>[user] takes the glass off the tracker.</span>")
qdel(src) // qdel
return
@@ -34,7 +34,7 @@
if(istype(A, /obj/item/weapon/crowbar))
if(modkits.len)
to_chat(user, "<span class='notice'>You pry the modifications out.</span>")
playsound(loc, 'sound/items/Crowbar.ogg', 100, 1)
playsound(loc, A.usesound, 100, 1)
for(var/obj/item/borg/upgrade/modkit/M in modkits)
M.uninstall(src)
else
@@ -230,6 +230,7 @@
origin_tech = "programming=2;materials=2;magnets=4"
require_module = 1
module_type = /obj/item/weapon/robot_module/miner
usesound = 'sound/items/Screwdriver.ogg'
var/denied_type = null
var/maximum_of_type = 1
var/cost = 30
@@ -266,7 +267,7 @@
if(KA.get_remaining_mod_capacity() >= cost)
if(.)
to_chat(user, "<span class='notice'>You install the modkit.</span>")
playsound(loc, 'sound/items/Screwdriver.ogg', 100, 1)
playsound(loc, usesound, 100, 1)
user.unEquip(src)
forceMove(KA)
KA.modkits += src
@@ -139,6 +139,8 @@
origin_tech = "combat=1;materials=3;magnets=2;plasmatech=2;engineering=1"
ammo_type = list(/obj/item/ammo_casing/energy/plasma)
fire_sound = 'sound/weapons/laser.ogg'
usesound = 'sound/items/Welder.ogg'
toolspeed = 1
flags = CONDUCT | OPENCONTAINER
attack_verb = list("attacked", "slashed", "cut", "sliced")
force = 12
@@ -121,7 +121,7 @@
afterattack(user, user) //you know the drill
user.visible_message("<span class='danger'>[src] goes off!</span>", "<span class='userdanger'>[src] goes off in your face!</span>")
return
if(do_after(user, 30, target = src))
if(do_after(user, 30 * A.toolspeed, target = src))
if(magazine.ammo_count())
to_chat(user, "<span class='warning'>You can't modify it!</span>")
return
@@ -134,7 +134,7 @@
afterattack(user, user) //and again
user.visible_message("<span class='danger'>[src] goes off!</span>", "<span class='userdanger'>[src] goes off in your face!</span>")
return
if(do_after(user, 30, target = src))
if(do_after(user, 30 * A.toolspeed, target = src))
if(magazine.ammo_count())
to_chat(user, "<span class='warning'>You can't modify it!</span>")
return
@@ -358,7 +358,7 @@
return
if(istype(I, /obj/item/weapon/wrench))
playsound(src, 'sound/items/Ratchet.ogg', 50, 1)
playsound(src, I.usesound, 50, 1)
if(anchored)
anchored = 0
to_chat(user, "<span class='caution'>[src] can now be moved.</span>")
+2 -1
View File
@@ -129,12 +129,13 @@
var/obj/item/conveyor_construct/C = new/obj/item/conveyor_construct(src.loc)
C.id = id
transfer_fingerprints_to(C)
playsound(loc, I.usesound, 50, 1)
to_chat(usr,"<span class='notice'>You remove the conveyor belt.</span>")
qdel(src)
else if(istype(I, /obj/item/weapon/wrench))
if(!(stat & BROKEN))
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
playsound(loc, I.usesound, 50, 1)
dir = turn(dir,-45)
update_move_direction()
to_chat(user, "<span class='notice'>You rotate [src].</span>")
@@ -212,16 +212,16 @@
else
density = 1 // We don't want disposal bins or outlets to go density 0
to_chat(user, "You attach the [nicetype] to the underfloor.")
playsound(src.loc, 'sound/items/Ratchet.ogg', 100, 1)
playsound(src.loc, I.usesound, 100, 1)
update()
else if(istype(I, /obj/item/weapon/weldingtool))
if(anchored)
var/obj/item/weapon/weldingtool/W = I
if(W.remove_fuel(0,user))
playsound(src.loc, 'sound/items/Welder2.ogg', 100, 1)
playsound(src.loc, W.usesound, 100, 1)
to_chat(user, "Welding the [nicetype] in place.")
if(do_after(user, 20, target = src))
if(do_after(user, 20 * W.toolspeed, target = src))
if(!src || !W.isOn()) return
to_chat(user, "The [nicetype] has been welded in place!")
update() // TODO: Make this neat
+16 -21
View File
@@ -74,12 +74,12 @@
return
if(mode==0) // It's off but still not unscrewed
mode=-1 // Set it to doubleoff l0l
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
to_chat(user, "You remove the screws around the power connection.")
return
else if(mode==-1)
mode=0
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
to_chat(user, "You attach the screws around the power connection.")
return
else if(istype(I,/obj/item/weapon/weldingtool) && mode==-1)
@@ -88,10 +88,10 @@
return
var/obj/item/weapon/weldingtool/W = I
if(W.remove_fuel(0,user))
playsound(src.loc, 'sound/items/Welder2.ogg', 100, 1)
playsound(src.loc, W.usesound, 100, 1)
to_chat(user, "You start slicing the floorweld off the disposal unit.")
if(do_after(user,20, target = src))
if(do_after(user, 20 * W.toolspeed, target = src))
if(!src || !W.isOn()) return
to_chat(user, "You sliced the floorweld off the disposal unit.")
var/obj/structure/disposalconstruct/C = new (src.loc)
@@ -882,8 +882,8 @@
var/obj/item/weapon/weldingtool/W = I
if(W.remove_fuel(0, user))
to_chat(user, "<span class='notice'>You begin slicing \the [src].</span>")
playsound(loc, 'sound/items/Welder2.ogg', 100, 1)
if(do_after(user, 30, target = src))
playsound(loc, W.usesound, 100, 1)
if(do_after(user, 30 * W.toolspeed, target = src))
to_chat(user, "<span class='notice'>You finish slicing \the [src].</span>")
welded()
else
@@ -1190,19 +1190,14 @@
var/obj/item/weapon/weldingtool/W = I
if(W.remove_fuel(0,user))
playsound(src.loc, 'sound/items/Welder2.ogg', 100, 1)
// check if anything changed over 2 seconds
var/turf/uloc = user.loc
var/atom/wloc = W.loc
to_chat(user, "Slicing the disposal pipe.")
sleep(30)
if(!W.isOn()) return
if(user.loc == uloc && wloc == W.loc)
playsound(loc, W.usesound, 100, 1)
to_chat(user, "<span class='notice'>Slicing the disposal pipe.</span>")
if(do_after(user, 30 * W.toolspeed, target = src))
if(!W.isOn())
return
welded()
else
to_chat(user, "You must stay still while welding the pipe.")
else
to_chat(user, "You need more welding fuel to cut the pipe.")
to_chat(user, "<span class='warning'>You need more welding fuel to cut the pipe.</span>")
return
// would transfer to next pipe segment, but we are in a trunk
@@ -1308,20 +1303,20 @@
if(istype(I, /obj/item/weapon/screwdriver))
if(mode==0)
mode=1
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
to_chat(user, "You remove the screws around the power connection.")
return
else if(mode==1)
mode=0
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
to_chat(user, "You attach the screws around the power connection.")
return
else if(istype(I,/obj/item/weapon/weldingtool) && mode==1)
var/obj/item/weapon/weldingtool/W = I
if(W.remove_fuel(0,user))
playsound(src.loc, 'sound/items/Welder2.ogg', 100, 1)
playsound(src.loc, W.usesound, 100, 1)
to_chat(user, "You start slicing the floorweld off the disposal outlet.")
if(do_after(user,20, target = src))
if(do_after(user, 20 * W.toolspeed, target = src))
if(!src || !W.isOn()) return
to_chat(user, "You sliced the floorweld off the disposal outlet.")
var/obj/structure/disposalconstruct/C = new (src.loc)
+4 -4
View File
@@ -331,20 +331,20 @@
if(istype(I, /obj/item/weapon/screwdriver))
if(c_mode==0)
c_mode=1
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
to_chat(user, "You remove the screws around the power connection.")
return
else if(c_mode==1)
c_mode=0
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src.loc, I.usesound, 50, 1)
to_chat(user, "You attach the screws around the power connection.")
return
else if(istype(I,/obj/item/weapon/weldingtool) && c_mode==1)
var/obj/item/weapon/weldingtool/W = I
if(W.remove_fuel(0,user))
playsound(src.loc, 'sound/items/Welder2.ogg', 100, 1)
playsound(src.loc, W.usesound, 100, 1)
to_chat(user, "You start slicing the floorweld off the delivery chute.")
if(do_after(user,20, target = src))
if(do_after(user, 20 * W.toolspeed, target = src))
if(!src || !W.isOn()) return
to_chat(user, "You sliced the floorweld off the delivery chute.")
var/obj/structure/disposalconstruct/C = new (src.loc)
@@ -80,7 +80,7 @@
if(istype(W, /obj/item/device/measuring_tape))
var/obj/item/device/measuring_tape/P = W
user.visible_message("\blue[user] extends [P] towards [src].","\blue You extend [P] towards [src].")
if(do_after(user,40, target = src))
if(do_after(user, 40, target = src))
to_chat(user, "\blue [bicon(P)] [src] has been excavated to a depth of [2*src.excavation_level]cm.")
return
@@ -89,7 +89,7 @@
to_chat(user, "\red You start [P.drill_verb] [src].")
if(!do_after(user,P.digspeed, target = src))
if(!do_after(user, P.digspeed, target = src))
return
to_chat(user, "\blue You finish [P.drill_verb] [src].")
+3 -3
View File
@@ -55,7 +55,7 @@
return 0
return connectedparts
/obj/item/pod_parts/pod_frame/attackby(var/obj/O, mob/user)
/obj/item/pod_parts/pod_frame/attackby(var/obj/item/O, mob/user)
if(istype(O, /obj/item/stack/rods))
var/obj/item/stack/rods/R = O
var/list/linkedparts = find_square()
@@ -71,12 +71,12 @@
//log_admin("Repositioning")
pod.loc = F.loc
qdel(F)
playsound(get_turf(src), 'sound/items/Ratchet.ogg', 50, 1)
playsound(get_turf(src), O.usesound, 50, 1)
if(istype(O, /obj/item/weapon/wrench))
to_chat(user, "<span class='notice'>You [!anchored ? "secure \the [src] in place." : "remove the securing bolts."]</span>")
anchored = !anchored
density = anchored
playsound(get_turf(src), 'sound/items/Ratchet.ogg', 50, 1)
playsound(get_turf(src), O.usesound, 50, 1)
/obj/item/pod_parts/pod_frame/verb/rotate()
set name = "Rotate Frame"
+4 -4
View File
@@ -311,7 +311,7 @@
if(iscrowbar(W))
if(!equipment_system.lock_system || unlocked || hatch_open)
hatch_open = !hatch_open
playsound(loc, 'sound/items/Crowbar.ogg', 50, 1)
playsound(loc, W.usesound, 50, 1)
to_chat(user, "<span class='notice'>You [hatch_open ? "open" : "close"] the maintenance hatch.</span>")
else
to_chat(user, "<span class='warning'>The hatch is locked shut!</span>")
@@ -369,8 +369,8 @@
return
if(health < initial(health))
to_chat(user, "\blue You start welding the spacepod...")
playsound(loc, 'sound/items/Welder.ogg', 50, 1)
if(do_after(user, 20, target = src))
playsound(loc, W.usesound, 50, 1)
if(do_after(user, 20 * W.toolspeed, target = src))
if(!src || !WT.remove_fuel(3, user)) return
repair_damage(10)
to_chat(user, "\blue You mend some [pick("dents","bumps","damage")] with \the [WT]")
@@ -383,7 +383,7 @@
if(L.on && equipment_system.lock_system)
user.visible_message(user, "<span class='warning'>[user] is drilling through the [src]'s lock!</span>",
"<span class='notice'>You start drilling through the [src]'s lock!</span>")
if(do_after(user, 100, target = src))
if(do_after(user, 100 * W.toolspeed, target = src))
qdel(equipment_system.lock_system)
equipment_system.lock_system = null
user.visible_message(user, "<span class='warning'>[user] has destroyed the [src]'s lock!</span>",
+3 -2
View File
@@ -4,6 +4,7 @@
icon_state = "autoimplanter"
item_state = "walkietalkie"//left as this so as to intentionally not have inhands
w_class = 2
usesound = 'sound/weapons/circsawhit.ogg'
var/obj/item/organ/internal/cyberimp/storedorgan
/obj/item/device/autoimplanter/attack_self(mob/user)//when the object it used...
@@ -12,7 +13,7 @@
return
storedorgan.insert(user)//insert stored organ into the user
user.visible_message("<span class='notice'>[user] presses a button on [src], and you hear a short mechanical noise.</span>", "<span class='notice'>You feel a sharp sting as [src] plunges into your body.</span>")
playsound(get_turf(user), 'sound/weapons/circsawhit.ogg', 50, 1)
playsound(get_turf(user), usesound, 50, 1)
storedorgan = null
/obj/item/device/autoimplanter/attackby(obj/item/I, mob/user, params)
@@ -32,4 +33,4 @@
storedorgan.forceMove(get_turf(user))
storedorgan = null
to_chat(user, "<span class='notice'>You remove the [storedorgan] from [src].</span>")
playsound(get_turf(user), 'sound/items/Screwdriver.ogg', 50, 1)
playsound(get_turf(user), I.usesound, 50, 1)
+1 -3
View File
@@ -113,9 +113,7 @@
if(prob_chance > 100)//if we are using a super tool
time = time/prob_chance //PLACEHOLDER VALUES
if(do_after(user, time, target = target))
if(do_after(user, time * tool.toolspeed, target = target))
if(prob(prob_chance) || isrobot(user))
if(end_step(user, target, target_zone, tool, surgery))
advance = 1
+4
View File
@@ -9,6 +9,8 @@
points = 50
var/blink_range = 8 // The teleport range when crushed/thrown at someone.
refined_type = /obj/item/stack/sheet/bluespace_crystal
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
/obj/item/weapon/ore/bluespace_crystal/New()
..()
@@ -58,6 +60,8 @@ var/global/list/datum/stack_recipe/bluespace_crystal_recipes = list(new/datum/st
desc = "A stable polycrystal, made of fused-together bluespace crystals. You could probably break one off."
origin_tech = "bluespace=4;materials=3"
attack_verb = list("bluespace polybashed", "bluespace polybattered", "bluespace polybludgeoned", "bluespace polythrashed", "bluespace polysmashed")
toolspeed = 1
usesound = 'sound/items/Deconstruct.ogg'
/obj/item/stack/sheet/bluespace_crystal/New()
..()
+6 -4
View File
@@ -67,7 +67,7 @@
var/stage = 0
/obj/machinery/telepad_cargo/attackby(obj/item/weapon/W as obj, mob/user as mob, params)
if(istype(W, /obj/item/weapon/wrench))
playsound(src, 'sound/items/Ratchet.ogg', 50, 1)
playsound(src, W.usesound, 50, 1)
if(anchored)
anchored = 0
to_chat(user, "<span class = 'caution'> The [src] can now be moved.</span>")
@@ -76,15 +76,15 @@
to_chat(user, "<span class = 'caution'> The [src] is now secured.</span>")
if(istype(W, /obj/item/weapon/screwdriver))
if(stage == 0)
playsound(src, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src, W.usesound, 50, 1)
to_chat(user, "<span class = 'caution'> You unscrew the telepad's tracking beacon.</span>")
stage = 1
else if(stage == 1)
playsound(src, 'sound/items/Screwdriver.ogg', 50, 1)
playsound(src, W.usesound, 50, 1)
to_chat(user, "<span class = 'caution'> You screw in the telepad's tracking beacon.</span>")
stage = 0
if(istype(W, /obj/item/weapon/weldingtool) && stage == 1)
playsound(src, 'sound/items/Welder.ogg', 50, 1)
playsound(src, W.usesound, 50, 1)
to_chat(user, "<span class = 'caution'> You disassemble the telepad.</span>")
new /obj/item/stack/sheet/metal(get_turf(src))
new /obj/item/stack/sheet/glass(get_turf(src))
@@ -119,6 +119,8 @@
throwforce = 10.0
throw_speed = 2
throw_range = 5
toolspeed = 1
usesound = 'sound/machines/click.ogg'
var/obj/item/weapon/stock_parts/cell/high/rcell = null
var/obj/machinery/pad = null
var/mode = 0