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
@@ -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."