Files
wwdpublic/Content.Server/StationEvents/Components/GasLeakRuleComponent.cs
Spatison 7c4bf63a33 [Feature] TG Gases / TG Газы (#147)
* 237.2.0

* feat: /tg/ gases

* Revert "237.2.0"

This reverts commit 08ecd6b145.

* fix: sound

* Revert "237.2.0"

This reverts commit 08ecd6b145.

* tweak: AI rewie

* fix: tupo

* Revert "237.2.0"

This reverts commit 08ecd6b145.

* fix: tupo
2024-12-17 14:08:35 +07:00

53 lines
1.3 KiB
C#

using Content.Server.StationEvents.Events;
using Content.Shared.Atmos;
using Robust.Shared.Map;
namespace Content.Server.StationEvents.Components;
[RegisterComponent, Access(typeof(GasLeakRule))]
public sealed partial class GasLeakRuleComponent : Component
{
public readonly Gas[] LeakableGases =
{
Gas.Ammonia,
Gas.Plasma,
Gas.Tritium,
Gas.Frezon,
Gas.WaterVapor,
// WD EDIT START
Gas.BZ,
Gas.Hydrogen,
Gas.Halon,
// WD EDIT END
};
/// <summary>
/// Running cooldown of how much time until another leak.
/// </summary>
public float TimeUntilLeak;
/// <summary>
/// How long between more gas being added to the tile.
/// </summary>
public float LeakCooldown = 1.0f;
// Event variables
public EntityUid TargetStation;
public EntityUid TargetGrid;
public Vector2i TargetTile;
public EntityCoordinates TargetCoords;
public bool FoundTile;
public Gas LeakGas;
public float MolesPerSecond;
public readonly int MinimumMolesPerSecond = 80;
/// <summary>
/// Don't want to make it too fast to give people time to flee.
/// </summary>
public int MaximumMolesPerSecond = 200;
public int MinimumGas = 1000;
public int MaximumGas = 4000;
public float SparkChance = 0.05f;
}