From: DrSmugleaf <10968691+DrSmugleaf@users.noreply.github.com> Date: Wed, 15 May 2024 03:26:02 +0000 (-0700) Subject: Fix the client not passing the weapon to can attack checks (#28040) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=c94751f2d2c0d3951d1252d2c3955b01cedb543e;p=space-station-14.git Fix the client not passing the weapon to can attack checks (#28040) --- diff --git a/Content.Client/Weapons/Melee/MeleeWeaponSystem.cs b/Content.Client/Weapons/Melee/MeleeWeaponSystem.cs index d59d471f1a..eba4f21acb 100644 --- a/Content.Client/Weapons/Melee/MeleeWeaponSystem.cs +++ b/Content.Client/Weapons/Melee/MeleeWeaponSystem.cs @@ -16,8 +16,6 @@ using Robust.Client.State; using Robust.Shared.Input; using Robust.Shared.Map; using Robust.Shared.Player; -using Robust.Shared.Prototypes; -using Robust.Shared.Timing; namespace Content.Client.Weapons.Melee; @@ -66,7 +64,7 @@ public sealed partial class MeleeWeaponSystem : SharedMeleeWeaponSystem if (!TryGetWeapon(entity, out var weaponUid, out var weapon)) return; - if (!CombatMode.IsInCombatMode(entity) || !Blocker.CanAttack(entity)) + if (!CombatMode.IsInCombatMode(entity) || !Blocker.CanAttack(entity, weapon: (weaponUid, weapon))) { weapon.Attacking = false; return;