Custom player animations not replicating to server

  1. What do you want to achieve?
    We want to have 2 different animation sets, for example the default animations for when the user has no gun equipped, but when they equip the gun it will have different a idle animation, running/walking and jumping/falling animations.

  2. What is the issue?
    The issue is that the animations work basically all of the time on the client, but doesn’t replicate to the server and other players.

  3. What solutions have you tried so far?
    In the character, I have the default animation script, that I have copied from my own character once I had unequiped all animations in the avatar editor.
    Ways I have tried to make this work completely include:

Tool.Equipped:Connect(function()
	Char.Animate.walk.WalkAnim.AnimationId = "AnimationIDHere"
	Char.Animate.run.RunAnim.AnimationId = "AnimationIDHere"
	Char.Animate.idle.Animation1.AnimationId = "AnimationIDHere"
	Char.Animate.idle.Animation2.AnimationId = "AnimationIDHere"
	Char.Animate.jump.JumpAnim.AnimationId = "AnimationIDHere"
	Char.Animate.fall.FallAnim.AnimationId = "AnimationIDHere"
end)

Tool.Unequipped:Connect(function()
	Char.Animate.walk.WalkAnim.AnimationId = DefaultWalkAnim
	Char.Animate.run.RunAnim.AnimationId = DefaultRunAnim
	Char.Animate.idle.Animation1.AnimationId = DefaultIdleAnim
	Char.Animate.idle.Animation2.AnimationId = DefaultIdleAnim
	Char.Animate.jump.JumpAnim.AnimationId = DefaultJumpAnim
	Char.Animate.fall.FallAnim.AnimationId = DefaultFallAnim
end)

--The problem with this script is that is shows no animation, view below.
--Note: I've tried this script on both the server and the client.

Client View:
https://gyazo.com/bca30a727fb325e7cf9d6db0e97a0b03
(Shows the same on the server)

Tool.Equipped:Connect(function()
	Char.Animate.Disabled = true
	
    --GunAnimate is a another Animate script, but configured with the animations for the gun.
	local GunAnimate = Gun.GunAnimate:Clone()
	GunAnimate.Parent = Char
end)

Tool.Unequipped:Connect(function()
	if Char:FindFirstChild("GunAnimate") then
		Char.GunAnimate:Destroy()
	end

	Char.Animate.Disabled = false
    --The problem with this script is shown below.
    --Note: I've tried this script on both the server and the client as well.
end)

Client View:
https://gyazo.com/44c1e84522e9dbaeae5ae411f797b594

Server View:
https://gyazo.com/6d0af2e28d3dff6817b91df436b6746f

Any help is greatly appreciated.

Have you made sure to wait for the Animator before loading your animations?

Yep, doesn’t seem to affect it.

I’ve resolved this by settings the animations to core, previously they were set to action.

1 Like