FlammableComponent has an empty Damage field by default.
Prevents NRE exceptions when admemes are involved, etc?
This commit is contained in:
@@ -1,9 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
using Content.Server.Atmos.EntitySystems;
|
||||
using Content.Shared.Damage;
|
||||
using Robust.Shared.GameObjects;
|
||||
using Robust.Shared.Serialization.Manager.Attributes;
|
||||
using Robust.Shared.ViewVariables;
|
||||
|
||||
namespace Content.Server.Atmos.Components
|
||||
{
|
||||
@@ -32,6 +27,6 @@ namespace Content.Server.Atmos.Components
|
||||
|
||||
[DataField("damage", required: true)]
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public DamageSpecifier Damage = default!;
|
||||
public DamageSpecifier Damage = new(); // Empty by default, we don't want any funny NREs.
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user