Replace usages of customTypeSerializer PrototypeIdListSerializer with something that doesn't take 20 separate words to type out (#37959)
* Replace usages of customTypeSerializer PrototypeIdListSerializer with something that doesn't take 20 separate words to type out * Missed one * Missed another * Fix data field ids
This commit is contained in:
@@ -1,24 +1,24 @@
|
||||
using Content.Shared.Chemistry.Components;
|
||||
using Content.Shared.Chemistry.Components.SolutionManager;
|
||||
using Content.Shared.Chemistry.Reaction;
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
using Content.Shared.Examine;
|
||||
using Content.Shared.FixedPoint;
|
||||
using Content.Shared.Verbs;
|
||||
using JetBrains.Annotations;
|
||||
using Robust.Shared.Containers;
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Utility;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
using System.Linq;
|
||||
using System.Numerics;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Text;
|
||||
using Content.Shared.Chemistry.Components;
|
||||
using Content.Shared.Chemistry.Components.SolutionManager;
|
||||
using Content.Shared.Chemistry.Reaction;
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
using Content.Shared.Containers;
|
||||
using Content.Shared.Examine;
|
||||
using Content.Shared.FixedPoint;
|
||||
using Content.Shared.Hands.Components;
|
||||
using Content.Shared.Hands.EntitySystems;
|
||||
using Content.Shared.Verbs;
|
||||
using JetBrains.Annotations;
|
||||
using Robust.Shared.Containers;
|
||||
using Robust.Shared.Map;
|
||||
using Robust.Shared.Network;
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Utility;
|
||||
using Dependency = Robust.Shared.IoC.DependencyAttribute;
|
||||
|
||||
namespace Content.Shared.Chemistry.EntitySystems;
|
||||
@@ -61,14 +61,14 @@ public partial record struct SolutionAccessAttemptEvent(string SolutionName)
|
||||
[UsedImplicitly]
|
||||
public abstract partial class SharedSolutionContainerSystem : EntitySystem
|
||||
{
|
||||
[Dependency] protected readonly IPrototypeManager PrototypeManager = default!;
|
||||
[Dependency] protected readonly ChemicalReactionSystem ChemicalReactionSystem = default!;
|
||||
[Dependency] protected readonly ExamineSystemShared ExamineSystem = default!;
|
||||
[Dependency] protected readonly SharedAppearanceSystem AppearanceSystem = default!;
|
||||
[Dependency] protected readonly SharedHandsSystem Hands = default!;
|
||||
[Dependency] protected readonly SharedContainerSystem ContainerSystem = default!;
|
||||
[Dependency] protected readonly MetaDataSystem MetaDataSys = default!;
|
||||
[Dependency] protected readonly INetManager NetManager = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly IPrototypeManager PrototypeManager = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly ChemicalReactionSystem ChemicalReactionSystem = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly ExamineSystemShared ExamineSystem = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly SharedAppearanceSystem AppearanceSystem = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly SharedHandsSystem Hands = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly SharedContainerSystem ContainerSystem = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly MetaDataSystem MetaDataSys = default!;
|
||||
[Robust.Shared.IoC.Dependency] protected readonly INetManager NetManager = default!;
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
@@ -376,6 +376,7 @@ public abstract partial class SharedSolutionContainerSystem : EntitySystem
|
||||
/// <summary>
|
||||
/// Splits a solution without the specified reagent(s).
|
||||
/// </summary>
|
||||
[Obsolete("Use SplitSolutionWithout with params ProtoId<ReagentPrototype>")]
|
||||
public Solution SplitSolutionWithout(Entity<SolutionComponent> soln, FixedPoint2 quantity, params string[] reagents)
|
||||
{
|
||||
var (uid, comp) = soln;
|
||||
@@ -386,6 +387,19 @@ public abstract partial class SharedSolutionContainerSystem : EntitySystem
|
||||
return splitSol;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Splits a solution without the specified reagent(s).
|
||||
/// </summary>
|
||||
public Solution SplitSolutionWithout(Entity<SolutionComponent> soln, FixedPoint2 quantity, params ProtoId<ReagentPrototype>[] reagents)
|
||||
{
|
||||
var (uid, comp) = soln;
|
||||
var solution = comp.Solution;
|
||||
|
||||
var splitSol = solution.SplitSolutionWithout(quantity, reagents);
|
||||
UpdateChemicals(soln);
|
||||
return splitSol;
|
||||
}
|
||||
|
||||
public void RemoveAllSolution(Entity<SolutionComponent> soln)
|
||||
{
|
||||
var (uid, comp) = soln;
|
||||
|
||||
Reference in New Issue
Block a user