Change wide swing sprites to be that of the weapon used (#21050)

Co-authored-by: notquitehadouken <1isthisameme>
This commit is contained in:
I.K
2023-10-17 20:12:00 -05:00
committed by GitHub
parent b33b57509e
commit df81532469
53 changed files with 160 additions and 103 deletions

View File

@@ -214,7 +214,7 @@ public sealed class MeleeWeaponSystem : SharedMeleeWeaponSystem
return Math.Clamp(chance, 0f, 1f);
}
public override void DoLunge(EntityUid user, Angle angle, Vector2 localPos, string? animation, bool predicted = true)
public override void DoLunge(EntityUid user, EntityUid weapon, Angle angle, Vector2 localPos, string? animation, bool predicted = true)
{
Filter filter;
@@ -227,7 +227,7 @@ public sealed class MeleeWeaponSystem : SharedMeleeWeaponSystem
filter = Filter.Pvs(user, entityManager: EntityManager);
}
RaiseNetworkEvent(new MeleeLungeEvent(GetNetEntity(user), angle, localPos, animation), filter);
RaiseNetworkEvent(new MeleeLungeEvent(GetNetEntity(user), GetNetEntity(weapon), angle, localPos, animation), filter);
}
private void OnSpeechHit(EntityUid owner, MeleeSpeechComponent comp, MeleeHitEvent args)