Fix missing sounds (#4466)

* Fix missing sounds

* Make SoundHitSpecies fallback to SoundHit

* Fix crayon YAML

* Update PlaySoundBehavior YAML

* Fix required
This commit is contained in:
ShadowCommander
2021-08-13 21:31:37 -07:00
committed by GitHub
parent e938234e8c
commit b8e6a996d4
29 changed files with 104 additions and 45 deletions

View File

@@ -100,8 +100,9 @@ namespace Content.Server.Light.Components
switch (CurrentState)
{
case ExpendableLightState.Lit:
{
SoundSystem.Play(Filter.Pvs(Owner), LitSound.GetSound(), Owner);
if (IconStateLit != string.Empty)
{
sprite.LayerSetState(2, IconStateLit);
@@ -110,18 +111,21 @@ namespace Content.Server.Light.Components
sprite.LayerSetVisible(1, true);
break;
}
case ExpendableLightState.Fading:
{
break;
}
default:
case ExpendableLightState.Dead:
SoundSystem.Play(Filter.Pvs(Owner), DieSound.GetSound(), Owner);
{
if (DieSound != null) SoundSystem.Play(Filter.Pvs(Owner), DieSound.GetSound(), Owner);
sprite.LayerSetState(0, IconStateSpent);
sprite.LayerSetShader(0, "shaded");
sprite.LayerSetVisible(1, false);
break;
}
}
}