Files
tbd-station-14/Content.Shared/Materials/PhysicalCompositionComponent.cs
Nemanja 57f2a768a0 Material Reclaimer (#14969)
* Material Reclaimer

* Fix this test

* autostack output, tweak volume, add upgrade examine

* whitelist AND blacklist support

why not

* trying so hard to get this fucking test to work

* EmoGarbage delves into MaterialArbitrageTest, never to return

* VV and restore cloth to glory

* make the system more robust

* even more stuff has composition; add blacklist for important items

* fix test fails

* convert recycling

* forgor :sadge:

* lol

* simply a modiCUM of doc commentary
2023-04-09 23:38:20 -05:00

31 lines
1.3 KiB
C#

using Content.Shared.Chemistry.Reagent;
using Content.Shared.FixedPoint;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom.Prototype.Dictionary;
namespace Content.Shared.Materials;
/// <summary>
/// This is used for assigning an innate material/chemical composition to an entity.
/// These aren't materials per se, but rather the materials which "make up" an entity.
/// This also isn't something that should exist simultaneously with <see cref="MaterialComponent"/>.
/// </summary>
/// <remarks>
/// The reason for duel material/chemical is for the eventual
/// combination of the two systems.
/// </remarks>
[RegisterComponent]
public sealed class PhysicalCompositionComponent : Component
{
/// <summary>
/// The materials that "make up" this entity
/// </summary>
[DataField("materialComposition", customTypeSerializer: typeof(PrototypeIdDictionarySerializer<int, MaterialPrototype>))]
public Dictionary<string, int> MaterialComposition = new();
/// <summary>
/// The chemicals that "make up" this entity
/// </summary>
[DataField("chemicalComposition", customTypeSerializer: typeof(PrototypeIdDictionarySerializer<FixedPoint2, ReagentPrototype>))]
public Dictionary<string, FixedPoint2> ChemicalComposition = new();
}