mirror of
https://github.com/WWhiteDreamProject/wwdpublic.git
synced 2026-04-17 13:37:47 +03:00
# Description This is a port of https://github.com/Fansana/floofstation1/pull/445 Except I despise that this wasn't upstreamed so much that I didn't even cherrypick it. # Changelog 🆑 - add: Footprints are now cleaned in a small radius around the mouse cursor when mopping them. (cherry picked from commit 11678af96950f6af75f7effef40fc92a7af33350)
51 lines
1.6 KiB
C#
51 lines
1.6 KiB
C#
using Content.Shared.Audio;
|
|
using Content.Shared.FixedPoint;
|
|
using Robust.Shared.Audio;
|
|
using Robust.Shared.GameStates;
|
|
|
|
namespace Content.Shared.Fluids;
|
|
|
|
/// <summary>
|
|
/// For entities that can clean up puddles
|
|
/// </summary>
|
|
[RegisterComponent, NetworkedComponent]
|
|
public sealed partial class AbsorbentComponent : Component
|
|
{
|
|
public const string SolutionName = "absorbed";
|
|
|
|
public Dictionary<Color, float> Progress = new();
|
|
|
|
/// <summary>
|
|
/// How much solution we can transfer in one interaction.
|
|
/// </summary>
|
|
[DataField("pickupAmount")]
|
|
public FixedPoint2 PickupAmount = FixedPoint2.New(100);
|
|
|
|
[DataField("pickupSound")]
|
|
public SoundSpecifier PickupSound = new SoundPathSpecifier("/Audio/Effects/Fluids/watersplash.ogg")
|
|
{
|
|
Params = AudioParams.Default.WithVariation(SharedContentAudioSystem.DefaultVariation),
|
|
};
|
|
|
|
[DataField("transferSound")] public SoundSpecifier TransferSound =
|
|
new SoundPathSpecifier("/Audio/Effects/Fluids/slosh.ogg")
|
|
{
|
|
Params = AudioParams.Default.WithVariation(SharedContentAudioSystem.DefaultVariation).WithVolume(-3f),
|
|
};
|
|
|
|
public static readonly SoundSpecifier DefaultTransferSound =
|
|
new SoundPathSpecifier("/Audio/Effects/Fluids/slosh.ogg")
|
|
{
|
|
Params = AudioParams.Default.WithVariation(SharedContentAudioSystem.DefaultVariation).WithVolume(-3f),
|
|
};
|
|
|
|
[DataField]
|
|
public float FootprintCleaningRange = 0.2f;
|
|
|
|
/// <summary>
|
|
/// How many footprints within <see cref="FootprintCleaningRange"/> can be cleaned at once.
|
|
/// </summary>
|
|
[DataField]
|
|
public int MaxCleanedFootprints = 5;
|
|
}
|