Moves ExamineSystem to Shared & adds next step info to construction examine (#1567)

This commit is contained in:
Exp
2020-08-01 17:37:12 +02:00
committed by GitHub
parent 7f0c379e87
commit c61e6d541b
21 changed files with 159 additions and 83 deletions
@@ -1,6 +1,12 @@
using Content.Shared.Construction;
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Shared.Construction;
using Content.Shared.GameObjects.EntitySystems;
using Robust.Shared.GameObjects;
using Robust.Shared.GameObjects.Systems;
using Robust.Shared.IoC;
using Robust.Shared.Localization;
using Robust.Shared.Serialization;
using Robust.Shared.Utility;
using Robust.Shared.ViewVariables;
namespace Content.Server.GameObjects.Components.Construction
@@ -9,8 +15,11 @@ namespace Content.Server.GameObjects.Components.Construction
/// Holds data about an entity that is in the process of being constructed or destructed.
/// </summary>
[RegisterComponent]
public class ConstructionComponent : Component
public class ConstructionComponent : Component, IExamine
{
#pragma warning disable 649
[Dependency] private readonly ILocalizationManager _loc;
#pragma warning restore 649
/// <inheritdoc />
public override string Name => "Construction";
@@ -37,5 +46,10 @@ namespace Content.Server.GameObjects.Components.Construction
serializer.DataReadWriteFunction("stage", 0,
value => Stage = value, () => Stage);
}
void IExamine.Examine(FormattedMessage message, bool inDetailsRange)
{
EntitySystem.Get<SharedConstructionSystem>().DoExamine(message, Prototype, Stage, inDetailsRange);
}
}
}
@@ -24,6 +24,7 @@ using Robust.Shared.Serialization;
using Robust.Shared.Utility;
using Robust.Shared.ViewVariables;
using Timer = Robust.Shared.Timers.Timer;
using Content.Shared.GameObjects.EntitySystems;
namespace Content.Server.GameObjects.Components.Fluids
{
@@ -18,6 +18,7 @@ using Robust.Shared.Localization;
using Robust.Shared.Utility;
using Robust.Shared.ViewVariables;
using Robust.Shared.Serialization;
using Content.Shared.GameObjects.EntitySystems;
namespace Content.Server.GameObjects.Components.Interactable
{
@@ -1,5 +1,6 @@
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Shared.Audio;
using Content.Shared.GameObjects.EntitySystems;
using Content.Shared.Interfaces.GameObjects.Components;
using Robust.Server.GameObjects;
using Robust.Server.GameObjects.EntitySystems;
@@ -2,6 +2,7 @@
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Server.Interfaces;
using Content.Server.Utility;
using Content.Shared.GameObjects.EntitySystems;
using Content.Shared.Interfaces.GameObjects.Components;
using Content.Shared.Maps;
using Robust.Server.GameObjects.EntitySystems;
@@ -1,4 +1,5 @@
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Shared.GameObjects.EntitySystems;
using Robust.Shared.GameObjects;
using Robust.Shared.Localization;
using Robust.Shared.Serialization;
@@ -13,6 +13,7 @@ using Robust.Shared.Serialization;
using Robust.Shared.Timers;
using Robust.Shared.Utility;
using Robust.Shared.ViewVariables;
using Content.Shared.GameObjects.EntitySystems;
namespace Content.Server.GameObjects.Components.Mobs
{
@@ -5,6 +5,7 @@ using Content.Server.Interfaces.GameObjects.Components.Interaction;
using Content.Shared.Audio;
using Content.Shared.Chemistry;
using Content.Shared.GameObjects.Components.Nutrition;
using Content.Shared.GameObjects.EntitySystems;
using Content.Shared.Interfaces;
using Content.Shared.Interfaces.GameObjects.Components;
using Robust.Server.GameObjects;
@@ -26,7 +27,7 @@ namespace Content.Server.GameObjects.Components.Nutrition
{
[RegisterComponent]
[ComponentReference(typeof(IAfterInteract))]
public class DrinkComponent : Component, IUse, IAfterInteract, ISolutionChange,IExamine, ILand
public class DrinkComponent : Component, IUse, IAfterInteract, ISolutionChange, IExamine, ILand
{
#pragma warning disable 649
[Dependency] private readonly IPrototypeManager _prototypeManager;
@@ -1,5 +1,6 @@
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Shared.GameObjects.Components;
using Content.Shared.GameObjects.EntitySystems;
using Content.Shared.Interfaces.GameObjects.Components;
using Robust.Server.GameObjects;
using Robust.Server.GameObjects.Components.UserInterface;
@@ -12,6 +12,7 @@ using Content.Server.GameObjects.EntitySystems.Click;
using Robust.Shared.GameObjects.Components;
using Robust.Shared.Localization;
using Robust.Shared.Utility;
using Content.Shared.GameObjects.EntitySystems;
namespace Content.Server.GameObjects.Components.Power.ApcNetComponents
{
@@ -1,6 +1,7 @@
using System;
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Shared.GameObjects.Components;
using Content.Shared.GameObjects.EntitySystems;
using Content.Shared.Interfaces;
using Content.Shared.Interfaces.GameObjects.Components;
using Robust.Shared.GameObjects;
@@ -5,6 +5,7 @@ using Content.Server.GameObjects.Components.Power.ApcNetComponents;
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Server.Interfaces.GameObjects.Components.Interaction;
using Content.Shared.GameObjects.Components.VendingMachines;
using Content.Shared.GameObjects.EntitySystems;
using Content.Shared.Interfaces.GameObjects.Components;
using Content.Shared.VendingMachines;
using Robust.Server.GameObjects;
@@ -2,6 +2,7 @@
using Content.Server.GameObjects.Components.Mobs;
using Content.Server.GameObjects.EntitySystems.Click;
using Content.Shared.GameObjects.Components.Mobs;
using Content.Shared.GameObjects.EntitySystems;
using Content.Shared.Interfaces;
using Content.Shared.Interfaces.GameObjects.Components;
using Robust.Server.GameObjects;
@@ -28,6 +28,7 @@ using Robust.Shared.Random;
using Robust.Shared.Serialization;
using Robust.Shared.Utility;
using Content.Server.Interfaces;
using Content.Shared.GameObjects.EntitySystems;
namespace Content.Server.GameObjects.Components.Weapon.Ranged.Barrels
{