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

how to i make a sword play 2 animation?

local plr = game.Players.LocalPlayer
local attack = false
    local mouse = plr:GetMouse()
    local char = plr.Character
script.Parent.Activated:Connect(function()
	
	local hum = char.Humanoid:LoadAnimation(script.Parent.Animation or script.Parent.Animationsd)
	script.Parent.Blade.Trail.Enabled = true
	hum:Play()
	attack = true
	wait(.50)
	hum:Stop()
	script.Parent.Blade.Trail.Enabled = false
	
	script.Parent.Blade.Touched:Connect(function(hit)
	
	local hum =  hit.Parent:FindFirstChild("Humanoid")
	if hum ~= nil and attack == true then
	hum.Health = 0
	attack = false
	end
end)
end)

4 comments

0

I'm pretty sure only one animation at a time can be played.

0

u can play mutiple animations at a time

0

Playing at the exact same time? Or do you mean different anims per sword swing but in the same script?

0

yeah

1 answer

✓ Accepted answer

You don't need to stop the animation, it stops automatically. If you want to disable the trail after it stops, use:

hum.Stopped:Wait()

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