diff --git a/Content.Shared/Cuffs/SharedCuffableSystem.cs b/Content.Shared/Cuffs/SharedCuffableSystem.cs index 21d09c744c..a13b9df514 100644 --- a/Content.Shared/Cuffs/SharedCuffableSystem.cs +++ b/Content.Shared/Cuffs/SharedCuffableSystem.cs @@ -500,6 +500,16 @@ public bool TryCuffing(EntityUid user, EntityUid target, EntityUid handcuff, Han if (HasComp(target)) cuffTime = MathF.Max(0.1f, cuffTime - handcuffComponent.StunBonus); + if (TryComp(user, out var cuffer)) // Stories - CuffingSpeed - start + { + if (cuffer.TimeModifier == null) + { + _popup.PopupClient(Loc.GetString("handcuff-component-cannot-use-cuffs"), user, user); + return false; + } + cuffTime = cuffTime * (float)cuffer.TimeModifier; + } // Stories - CuffingSpeed - end + if (HasComp(target)) cuffTime = 0.0f; // cuff them instantly. diff --git a/Content.Shared/Stories/Cuffs/CufferComponent.cs b/Content.Shared/Stories/Cuffs/CufferComponent.cs new file mode 100644 index 0000000000..34750df8bb --- /dev/null +++ b/Content.Shared/Stories/Cuffs/CufferComponent.cs @@ -0,0 +1,8 @@ +namespace Content.Shared.Cuffs; + +[RegisterComponent] +public sealed partial class CufferComponent : Component +{ + [DataField("timeModifier")] + public float? TimeModifier = 1; +} diff --git a/Resources/Locale/ru-RU/cuffs/components/handcuff-component.ftl b/Resources/Locale/ru-RU/cuffs/components/handcuff-component.ftl index 9dc0a949fe..8d679077ea 100644 --- a/Resources/Locale/ru-RU/cuffs/components/handcuff-component.ftl +++ b/Resources/Locale/ru-RU/cuffs/components/handcuff-component.ftl @@ -16,3 +16,5 @@ handcuff-component-cuff-interrupt-other-message = Вы помешали { $other handcuff-component-cuff-interrupt-buckled-message = Вы не можете пристегнуться в наручниках! handcuff-component-cuff-interrupt-unbuckled-message = Вы не можете отстегнуться в наручниках! handcuff-component-cannot-drop-cuffs = Вы не можете надеть наручники на { $target } + +handcuff-component-cannot-use-cuffs = Ваши пальцы слишком толстые, чтобы использовать наручники! diff --git a/Resources/Prototypes/Stories/Entities/Mobs/Species/shadowling.yml b/Resources/Prototypes/Stories/Entities/Mobs/Species/shadowling.yml index d1ba65428c..dfed65792b 100644 --- a/Resources/Prototypes/Stories/Entities/Mobs/Species/shadowling.yml +++ b/Resources/Prototypes/Stories/Entities/Mobs/Species/shadowling.yml @@ -9,6 +9,8 @@ id: BaseMobShadowling abstract: true components: + - type: Cuffer + timeModifier: 2 - type: ZombieImmune - type: ThermalVision - type: ComplexInteraction