Fix dead mob sprites rotating on death (#16317)
This commit is contained in:
@@ -70,7 +70,7 @@ internal sealed class BuckleSystem : SharedBuckleSystem
|
||||
!buckled ||
|
||||
args.Sprite == null)
|
||||
{
|
||||
_rotationVisualizerSystem.SetHorizontalAngle(uid, RotationVisualsComponent.DefaultRotation, rotVisuals);
|
||||
_rotationVisualizerSystem.SetHorizontalAngle(uid, rotVisuals.DefaultRotation, rotVisuals);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -3,12 +3,16 @@ namespace Content.Client.Rotation;
|
||||
[RegisterComponent]
|
||||
public sealed class RotationVisualsComponent : Component
|
||||
{
|
||||
public static readonly Angle DefaultRotation = Angle.FromDegrees(90);
|
||||
[DataField("defaultRotation")]
|
||||
[ViewVariables(VVAccess.ReadOnly)]
|
||||
public readonly Angle DefaultRotation = Angle.FromDegrees(90);
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public Angle VerticalRotation = 0;
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)] public Angle HorizontalRotation = DefaultRotation;
|
||||
[DataField("horizontalRotation")]
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public Angle HorizontalRotation = Angle.FromDegrees(90);
|
||||
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public float AnimationTime = 0.125f;
|
||||
|
||||
@@ -130,6 +130,8 @@
|
||||
Brute: 5
|
||||
- type: Appearance
|
||||
- type: RotationVisuals
|
||||
defaultRotation: 0
|
||||
horizontalRotation: 0
|
||||
- type: FireVisuals
|
||||
sprite: Mobs/Effects/onfire.rsi
|
||||
normalState: Generic_mob_burning
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 475 B After Width: | Height: | Size: 490 B |
Binary file not shown.
|
Before Width: | Height: | Size: 465 B After Width: | Height: | Size: 484 B |
Binary file not shown.
|
Before Width: | Height: | Size: 456 B After Width: | Height: | Size: 457 B |
Reference in New Issue
Block a user