This commit is contained in:
2021-04-06 23:42:42 +02:00
parent ca32be4d0d
commit 6b73203860

View File

@@ -28,7 +28,9 @@ namespace ReallifeGamemode.Server.Util
string animationName = animations.ElementAt(0); string animationName = animations.ElementAt(0);
List<string> nextAnimations = animations.Skip(1).ToList(); List<string> nextAnimations = animations.Skip(1).ToList();
player.SyncAnimation(animationName); player.SyncAnimation(animationName);
player.TriggerEvent("SERVER:QueueAnimations", nextAnimations.ToArray(), animationName);
if (nextAnimations.Count != 0)
player.TriggerEvent("SERVER:QueueAnimations", nextAnimations.ToArray(), animationName);
} }
/// <summary>Check if Player has any Animation playing. /// <summary>Check if Player has any Animation playing.
@@ -62,6 +64,7 @@ namespace ReallifeGamemode.Server.Util
[RemoteEvent("CLIENT:AnimPairTransition")] [RemoteEvent("CLIENT:AnimPairTransition")]
public void AnimPairTransition(Player player, string[] transitionTo) public void AnimPairTransition(Player player, string[] transitionTo)
{ {
player.SendChatMessage(transitionTo.ToString());
player.SyncAnimation(transitionTo.ToList<string>()); player.SyncAnimation(transitionTo.ToList<string>());
} }