2024-04-02 20:59:40 +03:00
using Robust.Shared.Prototypes ;
2024-04-20 11:51:04 +03:00
namespace Content.Shared._CP14.LockKey.Components ;
2024-04-02 20:59:40 +03:00
/// <summary>
/// A component of a lock that stores its keyhole shape, complexity, and current state.
/// </summary>
[RegisterComponent]
2024-04-20 11:51:04 +03:00
public sealed partial class CP14LockComponent : Component
2024-04-02 20:59:40 +03:00
{
[DataField]
public List < int > ? LockShape = null ;
[DataField]
public float LockPickDamageChance = 0.2f ;
/// <summary>
/// On which element of the shape sequence the lock is now located. It's necessary for the mechanics of breaking and entering.
/// </summary>
[DataField]
2024-10-21 14:20:05 +03:00
public int LockPickStatus = 0 ;
2024-04-02 20:59:40 +03:00
/// <summary>
/// after a lock is broken into, it leaves a description on it that it's been tampered with.
/// </summary>
[DataField]
2024-10-21 14:20:05 +03:00
public bool LockPickedFailMarkup = false ;
2024-04-02 20:59:40 +03:00
/// <summary>
/// If not null, automatically generates a lock for the specified category on initialization. This ensures that the lock will be opened with a key of the same category.
/// </summary>
[DataField]
2024-04-20 11:51:04 +03:00
public ProtoId < CP14LockCategoryPrototype > ? AutoGenerateShape = null ;
2024-04-02 20:59:40 +03:00
}