Cuff enhancements (#3087)
* Cuff enhancements * Cuffs now have an OnClick for the alert to remove them * nullables * Use default interaction range so highlights are accurate * Cuffing fails more gracely * Make shared abstract and add component references to client / server * Don't cache AudioSystem and HandsComponent given cuffs are rarely used * Fix test Co-authored-by: Metal Gear Sloth <metalgearsloth@gmail.com>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using Content.Shared.GameObjects.Components.ActionBlocking;
|
||||
#nullable enable
|
||||
using Content.Shared.GameObjects.Components.ActionBlocking;
|
||||
using Robust.Client.GameObjects;
|
||||
using Robust.Client.Graphics;
|
||||
using Robust.Shared.GameObjects;
|
||||
@@ -6,9 +7,10 @@ using Robust.Shared.GameObjects;
|
||||
namespace Content.Client.GameObjects.Components.ActionBlocking
|
||||
{
|
||||
[RegisterComponent]
|
||||
[ComponentReference(typeof(SharedHandcuffComponent))]
|
||||
public class HandcuffComponent : SharedHandcuffComponent
|
||||
{
|
||||
public override void HandleComponentState(ComponentState curState, ComponentState nextState)
|
||||
public override void HandleComponentState(ComponentState? curState, ComponentState? nextState)
|
||||
{
|
||||
if (curState is not HandcuffedComponentState state)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user