mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-10-09 18:31:17 +03:00
* Replace WithVolume() with AddVolume(), Remove AudioHelpers.WithVariation(), Use specifier options for audio params * Undo switching to AudioParams.AddVariation() * Replace AudioHelpers.WithVariation with AudioParams.AddVariation() * Test AudioParams.AddVariation() and change input parameters to sound like previous AudioHelpers.WithVariation() * Fix build error * Fix build error v2 * Remove DoAfter * fixes --------- Co-authored-by: AJCM-git <ajcm_mail@disroot.org>
78 lines
1.8 KiB
C#
78 lines
1.8 KiB
C#
using Content.Shared.DeviceLinking;
|
|
using Content.Shared.Materials;
|
|
using Robust.Shared.Audio;
|
|
using Robust.Shared.Containers;
|
|
using Robust.Shared.Prototypes;
|
|
using Robust.Shared.Serialization;
|
|
|
|
namespace Content.Shared.Cloning;
|
|
|
|
[RegisterComponent]
|
|
public sealed partial class CloningPodComponent : Component
|
|
{
|
|
[DataField]
|
|
public ProtoId<SinkPortPrototype> PodPort = "CloningPodReceiver";
|
|
|
|
[ViewVariables]
|
|
public ContainerSlot BodyContainer = default!;
|
|
|
|
/// <summary>
|
|
/// How long the cloning has been going on for.
|
|
/// </summary>
|
|
[ViewVariables]
|
|
public float CloningProgress = 0;
|
|
|
|
[ViewVariables]
|
|
public int UsedBiomass = 70;
|
|
|
|
[ViewVariables]
|
|
public bool FailedClone = false;
|
|
|
|
/// <summary>
|
|
/// The material that is used to clone entities.
|
|
/// </summary>
|
|
[DataField]
|
|
public ProtoId<MaterialPrototype> RequiredMaterial = "Biomass";
|
|
|
|
/// <summary>
|
|
/// The current amount of time it takes to clone a body.
|
|
/// </summary>
|
|
[DataField]
|
|
public float CloningTime = 30f;
|
|
|
|
/// <summary>
|
|
/// The mob to spawn on emag.
|
|
/// </summary>
|
|
[DataField]
|
|
public EntProtoId MobSpawnId = "MobAbomination";
|
|
|
|
/// <summary>
|
|
/// The sound played when a mob is spawned from an emagged cloning pod.
|
|
/// </summary>
|
|
[DataField]
|
|
public SoundSpecifier ScreamSound = new SoundCollectionSpecifier("ZombieScreams")
|
|
{
|
|
Params = AudioParams.Default.AddVolume(4),
|
|
};
|
|
|
|
[ViewVariables(VVAccess.ReadWrite)]
|
|
public CloningPodStatus Status;
|
|
|
|
[ViewVariables]
|
|
public EntityUid? ConnectedConsole;
|
|
}
|
|
|
|
[Serializable, NetSerializable]
|
|
public enum CloningPodVisuals : byte
|
|
{
|
|
Status
|
|
}
|
|
|
|
[Serializable, NetSerializable]
|
|
public enum CloningPodStatus : byte
|
|
{
|
|
Idle,
|
|
Cloning,
|
|
Gore,
|
|
NoMind
|
|
}
|