Removed the StateType property from every component. This field was completely unused except for a debug assertion.
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
using System;
|
||||
using Content.Shared.GameObjects;
|
||||
using Content.Shared.GameObjects;
|
||||
using Content.Shared.GameObjects.Components.Inventory;
|
||||
using Content.Shared.GameObjects.Components.Items;
|
||||
using Robust.Client.Graphics;
|
||||
@@ -16,7 +15,6 @@ namespace Content.Client.GameObjects.Components.Clothing
|
||||
private FemaleClothingMask _femaleMask;
|
||||
public override string Name => "Clothing";
|
||||
public override uint? NetID => ContentNetIDs.CLOTHING;
|
||||
public override Type StateType => typeof(ClothingComponentState);
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public string ClothingEquippedPrefix { get; set; }
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
using System;
|
||||
using Content.Shared.GameObjects;
|
||||
using Content.Shared.GameObjects;
|
||||
using Content.Shared.GameObjects.Components.Items;
|
||||
using Robust.Client.Graphics;
|
||||
using Robust.Client.Interfaces.ResourceManagement;
|
||||
@@ -18,7 +17,6 @@ namespace Content.Client.GameObjects
|
||||
{
|
||||
public override string Name => "Item";
|
||||
public override uint? NetID => ContentNetIDs.ITEM;
|
||||
public override Type StateType => typeof(ItemComponentState);
|
||||
|
||||
[ViewVariables] protected ResourcePath RsiPath;
|
||||
|
||||
|
||||
@@ -70,7 +70,6 @@ namespace Content.Client.GameObjects.Components.Weapons.Ranged
|
||||
|
||||
public override string Name => "BallisticMagazineWeapon";
|
||||
public override uint? NetID => ContentNetIDs.BALLISTIC_MAGAZINE_WEAPON;
|
||||
public override Type StateType => typeof(BallisticMagazineWeaponComponentState);
|
||||
|
||||
private StatusControl _statusControl;
|
||||
|
||||
|
||||
@@ -17,7 +17,6 @@ namespace Content.Client.GameObjects.Components
|
||||
{
|
||||
public override string Name => "Welder";
|
||||
public override uint? NetID => ContentNetIDs.WELDER;
|
||||
public override Type StateType => typeof(WelderComponentState);
|
||||
|
||||
[ViewVariables] public float FuelCapacity { get; private set; }
|
||||
[ViewVariables] public float Fuel { get; private set; }
|
||||
|
||||
@@ -19,7 +19,6 @@ namespace Content.Server.GameObjects
|
||||
{
|
||||
public override string Name => "Clothing";
|
||||
public override uint? NetID => ContentNetIDs.CLOTHING;
|
||||
public override Type StateType => typeof(ClothingComponentState);
|
||||
|
||||
public SlotFlags SlotFlags = SlotFlags.PREVENTEQUIP; //Different from None, NONE allows equips if no slot flags are required
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
using System;
|
||||
using Content.Server.GameObjects.EntitySystems;
|
||||
using Content.Server.GameObjects.EntitySystems;
|
||||
using Content.Server.Interfaces.GameObjects;
|
||||
using Content.Shared.GameObjects;
|
||||
using Content.Shared.GameObjects.Components.Items;
|
||||
@@ -21,7 +20,6 @@ namespace Content.Server.GameObjects
|
||||
{
|
||||
public override string Name => "Item";
|
||||
public override uint? NetID => ContentNetIDs.ITEM;
|
||||
public override Type StateType => typeof(ItemComponentState);
|
||||
|
||||
#pragma warning disable 649
|
||||
[Dependency] private readonly IRobustRandom _robustRandom;
|
||||
|
||||
@@ -10,7 +10,6 @@ namespace Content.Shared.GameObjects.Components.Cargo
|
||||
{
|
||||
public sealed override string Name => "CargoOrderDatabase";
|
||||
public sealed override uint? NetID => ContentNetIDs.CARGO_ORDER_DATABASE;
|
||||
public sealed override Type StateType => typeof(CargoOrderDatabaseState);
|
||||
}
|
||||
|
||||
[NetSerializable, Serializable]
|
||||
|
||||
@@ -13,7 +13,6 @@ namespace Content.Shared.GameObjects.Components.Cargo
|
||||
{
|
||||
public sealed override string Name => "GalacticMarket";
|
||||
public sealed override uint? NetID => ContentNetIDs.GALACTIC_MARKET;
|
||||
public sealed override Type StateType => typeof(GalacticMarketState);
|
||||
|
||||
protected List<CargoProductPrototype> _products = new List<CargoProductPrototype>();
|
||||
|
||||
|
||||
@@ -66,9 +66,6 @@ namespace Content.Shared.GameObjects.Components.Chemistry
|
||||
/// <inheritdoc />
|
||||
public sealed override uint? NetID => ContentNetIDs.SOLUTION;
|
||||
|
||||
/// <inheritdoc />
|
||||
public sealed override Type StateType => typeof(SolutionComponentState);
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void ExposeData(ObjectSerializer serializer)
|
||||
{
|
||||
|
||||
@@ -9,7 +9,6 @@ namespace Content.Shared.GameObjects
|
||||
{
|
||||
public override string Name => "Damageable";
|
||||
public sealed override uint? NetID => ContentNetIDs.DAMAGEABLE;
|
||||
public sealed override Type StateType => typeof(DamageComponentState);
|
||||
}
|
||||
|
||||
// The IDs of the items get synced over the network.
|
||||
|
||||
@@ -19,7 +19,6 @@ namespace Content.Shared.GameObjects
|
||||
|
||||
public sealed override string Name => "Inventory";
|
||||
public sealed override uint? NetID => ContentNetIDs.STORAGE;
|
||||
public sealed override Type StateType => typeof(InventoryComponentState);
|
||||
|
||||
[ViewVariables]
|
||||
protected Inventory InventoryInstance { get; private set; }
|
||||
|
||||
@@ -12,7 +12,6 @@ namespace Content.Shared.GameObjects.Components.Items
|
||||
public sealed class ItemCooldownComponent : Component
|
||||
{
|
||||
public override string Name => "ItemCooldown";
|
||||
public override Type StateType => typeof(ItemCooldownComponentState);
|
||||
public override uint? NetID => ContentNetIDs.ITEMCOOLDOWN;
|
||||
|
||||
private TimeSpan? _cooldownEnd;
|
||||
|
||||
@@ -9,7 +9,6 @@ namespace Content.Shared.GameObjects
|
||||
{
|
||||
public sealed override string Name => "Hands";
|
||||
public sealed override uint? NetID => ContentNetIDs.HANDS;
|
||||
public sealed override Type StateType => typeof(HandsComponentState);
|
||||
}
|
||||
|
||||
// The IDs of the items get synced over the network.
|
||||
|
||||
@@ -8,7 +8,6 @@ namespace Content.Shared.GameObjects.Components.Mobs
|
||||
{
|
||||
public sealed override uint? NetID => ContentNetIDs.COMBATMODE;
|
||||
public override string Name => "CombatMode";
|
||||
public sealed override Type StateType => typeof(CombatModeComponentState);
|
||||
|
||||
[Serializable, NetSerializable]
|
||||
protected sealed class CombatModeComponentState : ComponentState
|
||||
|
||||
@@ -13,7 +13,6 @@ namespace Content.Shared.GameObjects.Components.Mobs
|
||||
|
||||
public sealed override string Name => "HumanoidAppearance";
|
||||
public sealed override uint? NetID => ContentNetIDs.HUMANOID_APPEARANCE;
|
||||
public sealed override Type StateType => typeof(HumanoidAppearanceComponentState);
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public virtual HumanoidCharacterAppearance Appearance
|
||||
|
||||
@@ -11,7 +11,6 @@ namespace Content.Shared.GameObjects.Components.Mobs
|
||||
{
|
||||
public override string Name => "OverlayEffectsUI";
|
||||
public sealed override uint? NetID => ContentNetIDs.OVERLAYEFFECTS;
|
||||
public sealed override Type StateType => typeof(OverlayEffectComponentState);
|
||||
}
|
||||
|
||||
public enum ScreenEffects
|
||||
|
||||
@@ -13,8 +13,6 @@ namespace Content.Shared.GameObjects.Components.Mobs
|
||||
{
|
||||
public override string Name => "StatusEffectsUI";
|
||||
public override uint? NetID => ContentNetIDs.STATUSEFFECTS;
|
||||
public sealed override Type StateType => typeof(StatusEffectComponentState);
|
||||
|
||||
}
|
||||
|
||||
[Serializable, NetSerializable]
|
||||
|
||||
@@ -13,7 +13,6 @@ namespace Content.Shared.GameObjects.Components.Research
|
||||
{
|
||||
public override string Name => "LatheDatabase";
|
||||
public override uint? NetID => ContentNetIDs.LATHE_DATABASE;
|
||||
public override Type StateType => typeof(LatheDatabaseState);
|
||||
|
||||
private List<LatheRecipePrototype> _recipes = new List<LatheRecipePrototype>();
|
||||
|
||||
|
||||
@@ -14,7 +14,6 @@ namespace Content.Shared.GameObjects.Components.Research
|
||||
protected virtual Dictionary<string, int> Storage { get; set; }
|
||||
public override string Name => "MaterialStorage";
|
||||
public sealed override uint? NetID => ContentNetIDs.MATERIAL_STORAGE;
|
||||
public sealed override Type StateType => typeof(MaterialStorageState);
|
||||
|
||||
public int this[string ID]
|
||||
{
|
||||
|
||||
@@ -14,7 +14,6 @@ namespace Content.Shared.GameObjects.Components.Research
|
||||
{
|
||||
public override string Name => "ProtolatheDatabase";
|
||||
public sealed override uint? NetID => ContentNetIDs.PROTOLATHE_DATABASE;
|
||||
public sealed override Type StateType => typeof(ProtolatheDatabaseState);
|
||||
|
||||
private List<LatheRecipePrototype> _protolatheRecipes = new List<LatheRecipePrototype>();
|
||||
|
||||
|
||||
@@ -13,7 +13,6 @@ namespace Content.Shared.GameObjects.Components.Research
|
||||
{
|
||||
public override string Name => "TechnologyDatabase";
|
||||
public override uint? NetID => ContentNetIDs.TECHNOLOGY_DATABASE;
|
||||
public override Type StateType => typeof(TechnologyDatabaseState);
|
||||
|
||||
protected List<TechnologyPrototype> _technologies = new List<TechnologyPrototype>();
|
||||
|
||||
|
||||
@@ -8,7 +8,6 @@ namespace Content.Shared.GameObjects.Components
|
||||
{
|
||||
public sealed override string Name => "HandheldLight";
|
||||
public sealed override uint? NetID => ContentNetIDs.HANDHELD_LIGHT;
|
||||
public sealed override Type StateType => typeof(HandheldLightComponentState);
|
||||
|
||||
[Serializable, NetSerializable]
|
||||
protected sealed class HandheldLightComponentState : ComponentState
|
||||
|
||||
@@ -8,7 +8,6 @@ namespace Content.Shared.GameObjects.Components
|
||||
{
|
||||
public sealed override string Name => "Stack";
|
||||
public sealed override uint? NetID => ContentNetIDs.STACK;
|
||||
public sealed override Type StateType => typeof(StackComponentState);
|
||||
|
||||
[Serializable, NetSerializable]
|
||||
protected sealed class StackComponentState : ComponentState
|
||||
|
||||
Submodule RobustToolbox updated: 343667442b...df9be436c4
Reference in New Issue
Block a user