mirror of
https://github.com/WWhiteDreamProject/wwdpublic.git
synced 2026-04-18 05:59:03 +03:00
* add: Flip on hit system
* WD EDIT
* fix: animation
* fix: sound
* fix: sound
* Revert "fix: sound"
This reverts commit 64a12861ce.
* fix: sound
18 lines
506 B
C#
18 lines
506 B
C#
using Content.Shared._White.Animations;
|
|
using Robust.Shared.Player;
|
|
|
|
namespace Content.Server._White.Animations;
|
|
|
|
public sealed class FlipOnHitSystem : SharedFlipOnHitSystem
|
|
{
|
|
protected override void PlayAnimation(EntityUid user)
|
|
{
|
|
var filter = Filter.Pvs(user, entityManager: EntityManager);
|
|
|
|
if (TryComp<ActorComponent>(user, out var actor))
|
|
filter.RemovePlayer(actor.PlayerSession);
|
|
|
|
RaiseNetworkEvent(new FlipOnHitEvent(GetNetEntity(user)), filter);
|
|
}
|
|
}
|