How do you change the player's Walking Animation based off of an if statement

Okay so sorry im really bad at wording things, but basically I am making a downing system. How would I change the player’s walking animation based on their health?

I tried to add a variable in the animate script to where different animations play depending on the players health which was simple, but it didn’t work.

local animPlaceholder = nil

if Humanoid.Health <= 15 then
	animPlaceholder = "https://www.roblox.com/asset/?id=13155332561"

	
else
	
	animPlaceholder = "http://www.roblox.com/asset/?id=180426354"

end
walk = 	{ 	
		{ id = animPlaceholder, weight = 10 } 
			}, 

im not entirely sure what to do, could anyone help?

is it possible to detect whether the player is walking, and then play the animation?
im not really sure what to do

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.