Refactor serialization copying to use source generators (#19412)

This commit is contained in:
DrSmugleaf
2023-08-22 18:14:33 -07:00
committed by GitHub
parent 08b43990ab
commit a88e747a0b
1737 changed files with 2532 additions and 2521 deletions

View File

@@ -6,7 +6,7 @@ namespace Content.Shared.Sound.Components
/// Base sound emitter which defines most of the data fields.
/// Accepts both single sounds and sound collections.
/// </summary>
public abstract class BaseEmitSoundComponent : Component
public abstract partial class BaseEmitSoundComponent : Component
{
public static readonly AudioParams DefaultParams = AudioParams.Default.WithVolume(-2f);

View File

@@ -6,7 +6,7 @@ namespace Content.Shared.Sound.Components;
/// Simple sound emitter that emits sound on ActivateInWorld
/// </summary>
[RegisterComponent, NetworkedComponent]
public sealed class EmitSoundOnActivateComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnActivateComponent : BaseEmitSoundComponent
{
/// <summary>
/// Whether or not to mark an interaction as handled after playing the sound. Useful if this component is

View File

@@ -4,7 +4,7 @@ using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom;
namespace Content.Shared.Sound.Components;
[RegisterComponent, NetworkedComponent]
public sealed class EmitSoundOnCollideComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnCollideComponent : BaseEmitSoundComponent
{
public static readonly TimeSpan CollideCooldown = TimeSpan.FromSeconds(0.2);

View File

@@ -6,6 +6,6 @@ namespace Content.Shared.Sound.Components;
/// Simple sound emitter that emits sound on entity drop
/// </summary>
[RegisterComponent, NetworkedComponent]
public sealed class EmitSoundOnDropComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnDropComponent : BaseEmitSoundComponent
{
}

View File

@@ -6,6 +6,6 @@ namespace Content.Shared.Sound.Components;
/// Simple sound emitter that emits sound on LandEvent
/// </summary>
[RegisterComponent, NetworkedComponent]
public sealed class EmitSoundOnLandComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnLandComponent : BaseEmitSoundComponent
{
}

View File

@@ -6,6 +6,6 @@ namespace Content.Shared.Sound.Components;
/// Simple sound emitter that emits sound on entity pickup
/// </summary>
[RegisterComponent, NetworkedComponent]
public sealed class EmitSoundOnPickupComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnPickupComponent : BaseEmitSoundComponent
{
}

View File

@@ -6,6 +6,6 @@ namespace Content.Shared.Sound.Components;
/// Simple sound emitter that emits sound on entity spawn.
/// </summary>
[RegisterComponent, NetworkedComponent]
public sealed class EmitSoundOnSpawnComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnSpawnComponent : BaseEmitSoundComponent
{
}

View File

@@ -6,6 +6,6 @@ namespace Content.Shared.Sound.Components;
/// Simple sound emitter that emits sound on ThrowEvent
/// </summary>
[RegisterComponent, NetworkedComponent]
public sealed class EmitSoundOnThrowComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnThrowComponent : BaseEmitSoundComponent
{
}

View File

@@ -6,7 +6,7 @@ namespace Content.Shared.Sound.Components;
/// Simple sound emitter that emits sound on UseInHand
/// </summary>
[RegisterComponent]
public sealed class EmitSoundOnUseComponent : BaseEmitSoundComponent
public sealed partial class EmitSoundOnUseComponent : BaseEmitSoundComponent
{
/// <summary>
/// Whether or not to mark an interaction as handled after playing the sound. Useful if this component is