Enable nullable in ReactionPrototype & ReagentPrototype (#3005)

* Enable nullable in ReactionPrototype & ReagentPrototype

* Remove unecessary sets

* Fix updates branch

* Review fixes

Co-authored-by: py01 <pyronetics01@gmail.com>
This commit is contained in:
py01
2021-01-14 23:40:10 -06:00
committed by GitHub
parent 3079ddd962
commit 138cdaba5b
3 changed files with 29 additions and 19 deletions

View File

@@ -1,3 +1,4 @@
#nullable enable
using Content.Shared.Chemistry;
using Content.Shared.GameObjects.EntitySystems;
using Robust.Server.GameObjects.EntitySystems;
@@ -11,7 +12,8 @@ namespace Content.Server.GameObjects.EntitySystems.NewFolder
{
base.OnReaction(reaction, owner, unitReactions);
Get<AudioSystem>().PlayAtCoords(reaction.Sound, owner.Transform.Coordinates);
if (reaction.Sound != null)
Get<AudioSystem>().PlayAtCoords(reaction.Sound, owner.Transform.Coordinates);
}
}
}