Why the idle animation isn't playing?

  1. What do you i to achieve? Basically i want that when this script runs, when the player runs or walks then play an animation, when the player is idle then play another one.

  2. What is the issue? The IdleAnimation is not playing when the avatr is stopped (in the idle form)

This is a localscript (i also tried to fireserver, but it didn’t work)

	if character:FindFirstChild("Animate") then
		
		local animate = character:FindFirstChild("Animate")
		
		if 	animate.walk.WalkAnim then
		
		  animate.walk.WalkAnim.AnimationId = "rbxassetid://12992206205"
			
			
			end
		
		if 	animate.run.RunAnim then

			animate.run.RunAnim.AnimationId = "rbxassetid://12992206205"
			
			
			
		end
		
		if animate.idle.Animation1 and animate.idle.Animation2 then
			
		animate.idle.Animation1.AnimationId = "rbxassetid://12992211045"
		animate.idle.Animation2.AnimationId = "rbxassetid://12992211045"
			
			
			animate.idle.Animation1.Weight.Value = 10
			animate.idle.Animation2.Weight.Value = 10

		end
				
	end

All answers are welcome ;D