Refactors sound groups to use decls instead of a massive switch with dozens of global lists. (#9702)

This commit is contained in:
Matt Atlas
2020-08-28 20:47:00 +02:00
committed by GitHub
parent db1b0cece0
commit 0dd08df5b2
125 changed files with 629 additions and 557 deletions
@@ -82,7 +82,7 @@
if(emag_act(INFINITY, user, "The locker has been sliced open by [user] with \an [blade]!", "You hear metal being sliced and sparks flying."))
blade.spark_system.queue()
playsound(loc, 'sound/weapons/blade.ogg', 50, 1)
playsound(loc, "sparks", 50, 1)
playsound(loc, /decl/sound_category/spark_sound, 50, 1)
else
to_chat(user, "<span class='warning'>Access Denied</span>")
return
@@ -170,7 +170,7 @@
if(emag_act(INFINITY, user, "<span class='danger'>The locker has been sliced open by [user] with \an [W]</span>!", "<span class='danger'>You hear metal being sliced and sparks flying.</span>"))
spark(src, 5)
playsound(loc, 'sound/weapons/blade.ogg', 50, 1)
playsound(loc, "sparks", 50, 1)
playsound(loc, /decl/sound_category/spark_sound, 50, 1)
else if(W.iswelder())
var/obj/item/weldingtool/WT = W
if(WT.isOn())
@@ -351,7 +351,7 @@
add_overlay(emag)
add_overlay(sparks)
CUT_OVERLAY_IN(sparks, 6)
playsound(loc, "sparks", 60, 1)
playsound(loc, /decl/sound_category/spark_sound, 60, 1)
locked = 0
broken = 1
to_chat(user, "<span class='notice'>You unlock \the [src].</span>")