Prevent inventory events from being relayed to pockets (#6074)
Co-authored-by: ShadowCommander <10494922+ShadowCommander@users.noreply.github.com>
This commit is contained in:
@@ -1,8 +1,9 @@
|
||||
using Robust.Shared.GameObjects;
|
||||
using Content.Shared.Inventory;
|
||||
using Robust.Shared.GameObjects;
|
||||
|
||||
namespace Content.Server.Atmos
|
||||
{
|
||||
public abstract class PressureEvent : EntityEventArgs
|
||||
public abstract class PressureEvent : EntityEventArgs, IInventoryRelayEvent
|
||||
{
|
||||
/// <summary>
|
||||
/// The environment pressure.
|
||||
@@ -28,6 +29,11 @@ namespace Content.Server.Atmos
|
||||
/// </remarks>
|
||||
public float Multiplier { get; set; } = 1f;
|
||||
|
||||
/// <summary>
|
||||
/// The inventory slots that should be checked for pressure protecting equipment.
|
||||
/// </summary>
|
||||
public SlotFlags TargetSlots { get; } = ~SlotFlags.POCKET;
|
||||
|
||||
protected PressureEvent(float pressure)
|
||||
{
|
||||
Pressure = pressure;
|
||||
|
||||
@@ -8,6 +8,7 @@ using Content.Server.Temperature.Components;
|
||||
using Content.Shared.Alert;
|
||||
using Content.Shared.Damage;
|
||||
using Content.Shared.Database;
|
||||
using Content.Shared.Inventory;
|
||||
using Robust.Shared.GameObjects;
|
||||
using Robust.Shared.IoC;
|
||||
|
||||
@@ -212,8 +213,10 @@ namespace Content.Server.Temperature.Systems
|
||||
}
|
||||
}
|
||||
|
||||
public class ModifyChangedTemperatureEvent : EntityEventArgs
|
||||
public class ModifyChangedTemperatureEvent : EntityEventArgs, IInventoryRelayEvent
|
||||
{
|
||||
public SlotFlags TargetSlots { get; } = ~SlotFlags.POCKET;
|
||||
|
||||
public float TemperatureDelta;
|
||||
|
||||
public ModifyChangedTemperatureEvent(float temperature)
|
||||
|
||||
Reference in New Issue
Block a user