using Robust.Shared.GameStates;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Generic;
namespace Content.Shared.SubFloor
{
///
/// Simple component that automatically hides the sibling
/// when the tile it's on is not a sub floor
/// (plating).
///
///
[NetworkedComponent]
[RegisterComponent]
[Access(typeof(SharedSubFloorHideSystem))]
public sealed class SubFloorHideComponent : Component
{
///
/// Whether the entity's current position has a "Floor-type" tile above its current position.
///
[ViewVariables]
public bool IsUnderCover { get; set; } = false;
///
/// Whether interactions with this entity should be blocked while it is under floor tiles.
///
///
/// Useful for entities like vents, which are only partially hidden. Anchor attempts will still be blocked.
///
[DataField("blockInteractions")]
public bool BlockInteractions { get; set; } = true;
///
/// Whether this entity's ambience should be disabled when underneath the floor.
///
///
/// Useful for cables and piping, gives maint it's distinct noise.
///
[DataField("blockAmbience")]
public bool BlockAmbience { get; set; } = true;
///
/// When revealed using some scanning tool, what transparency should be used to draw this item?
///
[DataField("scannerTransparency")]
public float ScannerTransparency = 0.8f;
///
/// Sprite layer keys for the layers that are always visible, even if the entity is below a floor tile. E.g.,
/// the vent part of a vent is always visible, even though the piping is hidden.
///
[DataField("visibleLayers", customTypeSerializer:typeof(CustomHashSetSerializer