diff --git a/SharpPluginLoader.Core/Components/AnimationLayerComponent.cs b/SharpPluginLoader.Core/Components/AnimationLayerComponent.cs index 74a83cb..8e71a60 100644 --- a/SharpPluginLoader.Core/Components/AnimationLayerComponent.cs +++ b/SharpPluginLoader.Core/Components/AnimationLayerComponent.cs @@ -33,12 +33,25 @@ public AnimationLayerComponent() { } /// public ref float Speed => ref GetRef(0x11C); + /// + /// If locked, gets the locked speed of this animation layer. + /// + public float? LockedSpeed + { + get + { + if (SpeedLocks.TryGetValue(Instance, out float lockedSpeed)) + return lockedSpeed; + return null; + } + } + /// /// Gets or sets whether the animation is paused. /// public bool Paused { - get => SpeedLocks.ContainsKey(Instance) && SpeedLocks[Instance] == 0f; + get => LockedSpeed == (float?)0f; set { if (value) Pause();