script.Parent.ClickDetector.MouseClick:connect(function(playerWhoClicked)
local animation = Instance.new("Animation")
animation.AnimationId = "http://www.roblox.com/Asset?ID=147619125" -- your id here
local animTrack =script.Parent.Parent:FindFirstChild("Humanoid"):LoadAnimation(animation)
-- change Humanoid to the target's Humanoid
animTrack:Play()
end)
It works in test mode but not in a server

2 comments
Could you please use prints to tell where the execution stops working ?
It doesn't execute at all.