Thieving component and Thieving Gloves (#9158)
* Thieving component and gloves * Fixes popup issue * Forgot to add it for hands * Adds a bool datafield * Comments * Requested changes
This commit is contained in:
21
Content.Shared/Strip/ThievingSystem.cs
Normal file
21
Content.Shared/Strip/ThievingSystem.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using Content.Shared.Inventory;
|
||||
using Content.Shared.Strip.Components;
|
||||
|
||||
namespace Content.Shared.Strip;
|
||||
|
||||
public sealed class ThievingSystem : EntitySystem
|
||||
{
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
base.Initialize();
|
||||
|
||||
SubscribeLocalEvent<ThievingComponent, BeforeStripEvent>(OnBeforeStrip);
|
||||
}
|
||||
|
||||
private void OnBeforeStrip(EntityUid uid, ThievingComponent component, BeforeStripEvent args)
|
||||
{
|
||||
args.Stealth = component.Stealthy;
|
||||
args.Additive -= component.StealTime;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user