* electrocution * slippery * flashibg * Update SlipperyComponent.cs * Update SlipperySystem.cs
40 lines
1.1 KiB
C#
40 lines
1.1 KiB
C#
using Content.Shared.Flash;
|
|
using Robust.Shared.Audio;
|
|
using Robust.Shared.GameStates;
|
|
|
|
namespace Content.Shared.Flash.Components
|
|
{
|
|
[RegisterComponent, NetworkedComponent, Access(typeof(SharedFlashSystem))]
|
|
public sealed partial class FlashComponent : Component
|
|
{
|
|
|
|
[DataField("duration")]
|
|
[ViewVariables(VVAccess.ReadWrite)]
|
|
public int FlashDuration { get; set; } = 5000;
|
|
|
|
[DataField("range")]
|
|
[ViewVariables(VVAccess.ReadWrite)]
|
|
public float Range { get; set; } = 7f;
|
|
|
|
[ViewVariables(VVAccess.ReadWrite)]
|
|
[DataField("aoeFlashDuration")]
|
|
public int AoeFlashDuration { get; set; } = 2000;
|
|
|
|
[DataField("slowTo")]
|
|
[ViewVariables(VVAccess.ReadWrite)]
|
|
public float SlowTo { get; set; } = 0.5f;
|
|
|
|
[ViewVariables(VVAccess.ReadWrite)]
|
|
[DataField("sound")]
|
|
public SoundSpecifier Sound { get; set; } = new SoundPathSpecifier("/Audio/Weapons/flash.ogg")
|
|
{
|
|
Params = AudioParams.Default.WithVolume(1f).WithMaxDistance(3f)
|
|
};
|
|
|
|
public bool Flashing;
|
|
|
|
[DataField]
|
|
public float Probability = 1f;
|
|
}
|
|
}
|