Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

how to make part that animate npc?

how to make part that animate npc? not player

1 answer

✓ Accepted answer
local target = script.Parent -- Change this to point to the part you want to trigger the event

target.Touched:Connect(function() -- When the player touches the part
	local dummy = workspace.Dummy -- Refer to the NPC, Change this to point to the NPC
	local animator = dummy.Humanoid.Animator -- Refer to the animator
	local animation = animator:LoadAnimation() -- Loads the animation, Insert a Animation ID into LoadAnimation()
	animation:Play() -- Play the animation
end)

Insert it into a Script on a Part.

This discussion is preserved as it was. New answers, comments, and votes are closed.