Refactor serialization copying to use source generators (#19412)
This commit is contained in:
@@ -6,19 +6,19 @@ namespace Content.Server.Traits.Assorted;
|
||||
/// This is used for the narcolepsy trait.
|
||||
/// </summary>
|
||||
[RegisterComponent, Access(typeof(NarcolepsySystem))]
|
||||
public sealed class NarcolepsyComponent : Component
|
||||
public sealed partial class NarcolepsyComponent : Component
|
||||
{
|
||||
/// <summary>
|
||||
/// The random time between incidents, (min, max).
|
||||
/// </summary>
|
||||
[DataField("timeBetweenIncidents", required: true)]
|
||||
public Vector2 TimeBetweenIncidents { get; }
|
||||
public Vector2 TimeBetweenIncidents { get; private set; }
|
||||
|
||||
/// <summary>
|
||||
/// The duration of incidents, (min, max).
|
||||
/// </summary>
|
||||
[DataField("durationOfIncident", required: true)]
|
||||
public Vector2 DurationOfIncident { get; }
|
||||
public Vector2 DurationOfIncident { get; private set; }
|
||||
|
||||
public float NextIncidentTime;
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ namespace Content.Server.Traits.Assorted;
|
||||
/// This is used for the uncloneable trait.
|
||||
/// </summary>
|
||||
[RegisterComponent]
|
||||
public sealed class UncloneableComponent : Component
|
||||
public sealed partial class UncloneableComponent : Component
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ namespace Content.Server.Traits.Assorted;
|
||||
/// On adding spawns wheelchair prototype and tries buckle player to it, then self removing
|
||||
/// </summary>
|
||||
[RegisterComponent, Access(typeof(WheelchairBoundSystem))]
|
||||
public sealed class WheelchairBoundComponent : Component
|
||||
public sealed partial class WheelchairBoundComponent : Component
|
||||
{
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
[DataField("wheelchairPrototype", customTypeSerializer: typeof(PrototypeIdSerializer<EntityPrototype>))]
|
||||
|
||||
Reference in New Issue
Block a user