Reaction sound re-added (#2990)

* Reaction sound re-added

* Moves reaction sound file to reaction prototype

Co-authored-by: py01 <pyronetics01@gmail.com>
This commit is contained in:
py01
2021-01-14 01:06:23 -06:00
committed by GitHub
parent 6a19dd9f02
commit 4c80082555
5 changed files with 39 additions and 6 deletions

View File

@@ -0,0 +1,17 @@
using Content.Shared.Chemistry;
using Content.Shared.GameObjects.EntitySystems;
using Robust.Server.GameObjects.EntitySystems;
using Robust.Shared.Interfaces.GameObjects;
namespace Content.Server.GameObjects.EntitySystems.NewFolder
{
public class ChemicalReactionSystem : SharedChemicalReactionSystem
{
protected override void OnReaction(ReactionPrototype reaction, IEntity owner, ReagentUnit unitReactions)
{
base.OnReaction(reaction, owner, unitReactions);
Get<AudioSystem>().PlayAtCoords(reaction.Sound, owner.Transform.Coordinates);
}
}
}