Explosion Audio (#1057)

Adds directional audio for explosions and fixes a variety of sound issues with them.
Adds screenshaking for explosions
Tweaks volumes and adds missing sounds for several window/airlock interactions.

Also fixes some runtime errors here and there which were discovered during testing, mostly just adding safeties
This commit is contained in:
NanakoAC
2016-10-26 22:00:49 +03:00
committed by skull132
parent 479666a47d
commit e9f8cdf6b1
9 changed files with 149 additions and 61 deletions
+4 -5
View File
@@ -174,7 +174,7 @@
/obj/structure/window/attack_tk(mob/user as mob)
user.visible_message("<span class='notice'>Something knocks on [src].</span>")
playsound(loc, 'sound/effects/Glasshit.ogg', 50, 1)
playsound(loc, 'sound/effects/Glasshit.ogg', 60, 1)
/obj/structure/window/attack_hand(mob/user as mob)
if(HULK in user.mutations)
@@ -191,26 +191,25 @@
attack_generic(H,25)
return
playsound(src.loc, 'sound/effects/glassknock.ogg', 80, 1)
playsound(src.loc, 'sound/effects/glassknock.ogg', 90, 1)
user.do_attack_animation(src)
usr.visible_message("\red [usr.name] bangs against the [src.name]!",
"\red You bang against the [src.name]!",
"You hear a banging sound.")
else
playsound(src.loc, 'sound/effects/glassknock.ogg', 80, 1)
playsound(src.loc, 'sound/effects/glassknock.ogg', 60, 1)
usr.visible_message("[usr.name] knocks on the [src.name].",
"You knock on the [src.name].",
"You hear a knocking sound.")
return
/obj/structure/window/attack_generic(var/mob/user, var/damage)
if(!damage)
return
if(damage >= 10)
visible_message("<span class='danger'>[user] smashes into [src]!</span>")
take_damage(damage)
else
visible_message("<span class='notice'>\The [user] bonks \the [src] harmlessly.</span>")
playsound(src.loc, 'sound/effects/Glasshit.ogg', 7, 1, -1)
user.do_attack_animation(src)
return 1