im making a local script that platformstands player when u have 20 hp but i dont know how to make it work

script.Parent.Humanoid.HealthChanged:Connect(function()
	if script.Parent.Humanoid.Health <= 20 then
		script.Parent.Humanoid.PlatformStand = true
	else
		script.Parent.Humanoid.PlatformStand = false
		
		
		Instance.new("Decal", script.Parent["Left Leg"])
		script.Parent["Left Leg"].Decal.Texture = "rbxassetid://508050906"
		script.Parent["Left Leg"].Decal.Face = Region3int16
		
		Instance.new("Decal", script.Parent.Head)
		script.Parent.Head.Decal.Texture = "rbxassetid://176678128"
		script.Parent.Head.Decal.Face = "Back"
	end
end)

this is local script its in StarterCharacterscripts