How do I play the animation in a script made by Moon Animator? this is my script and explorer.
local player = game.Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local debounce = false
local onetwo = true
local sword = script.Parent
local oneanim = script.SwordSwing1
local twoanim = script.SwordSwing2
sword.Activated:Connect(function()
if debounce == false then
if onetwo == true then
oneanim:Play()
onetwo = false
else
twoanim:Play()
onetwo = true
end
end
end)```
just right click SwordSwing1 and click “Save To Roblox”
when it shows you the id, click the copy button should look something like this
next you would have to create a couple variables and script a bit
local Animatior = character.Humanoid.Animator
local oneanim = instance.new("Animation", script)
oneanim.AnimationId = "rbxassetid://".. -- id you copied goes here
oneanim = Animator:LoadAnimation(oneanim)
-- then run oneanim:Play() and it should play the animation
there we go, just do the second code example again for adding another animation.