Add action to pull down mask (#9015)
* Add action to pull down mask * Update based on review comments * fix access * cleanup * Update based on review comments * revert change to ToggleableClothingSystem * switch to unequip * Specify the unequip is for togglemaskevent only * fix issue of activating mask in hands with something else in mask slot * Update based on review comments * switch to dependency for ActionSystem for consistency * whoops other instance too * review changes
This commit is contained in:
20
Content.Server/Clothing/Components/MaskComponent.cs
Normal file
20
Content.Server/Clothing/Components/MaskComponent.cs
Normal file
@@ -0,0 +1,20 @@
|
||||
using Content.Shared.Actions;
|
||||
using Content.Shared.Actions.ActionTypes;
|
||||
|
||||
namespace Content.Server.Clothing.Components
|
||||
{
|
||||
[Access(typeof(MaskSystem))]
|
||||
[RegisterComponent]
|
||||
public sealed class MaskComponent : Component
|
||||
{
|
||||
/// <summary>
|
||||
/// This mask can be toggled (pulled up/down)
|
||||
/// </summary>
|
||||
[DataField("toggleAction")]
|
||||
public InstantAction? ToggleAction = null;
|
||||
|
||||
public bool IsToggled = false;
|
||||
}
|
||||
|
||||
public sealed class ToggleMaskEvent : InstantActionEvent { }
|
||||
}
|
||||
Reference in New Issue
Block a user