local tool = script.Parent
local player = tool.Parent.Parent
local char = player.Character
local equip = script.Parent["Equip Sound"]
local animate = char.Animate

tool.Equipped:Connect(function()
	char["Right Arm"]:WaitForChild("RightGrip"):Destroy()
	local Motor6D = Instance.new("Motor6D", char["Right Arm"])
	Motor6D.Name = "HandleMotor6D"
	Motor6D.Part0 = char["Right Arm"]
	Motor6D.Part1 = tool.Handle
	
	char.Humanoid.WalkSpeed = 0
	char.Humanoid.JumpPower = 0
	local anim = Instance.new("Animation")
	anim.AnimationId = "rbxassetid://5200201796"
	animTrack = char.Humanoid:LoadAnimation(anim)
	animTrack:Play()
	equip:Play()
	
	animate.toolnone.ToolNoneAnim.AnimationId = "rbxassetid://5200205288"
	animate.walk.WalkAnim.AnimationId = "rbxassetid://5200428780"
	char.Humanoid.WalkSpeed = 16
	char.Humanoid.JumpPower = 50
	
end)

tool.Unequipped:Connect(function()
	if char["Right Arm"]:FindFirstChild("HandleMotor6D")then
		char["Right Arm"].HandleMotor6D:Destroy()
	end
	animate.toolnone.ToolNoneAnim.AnimationId = "http://www.roblox.com/asset/?id=182393478"
	animate.walk.WalkAnim.AnimationId = "http://www.roblox.com/asset/?id=180426354"
end)

It working incorrectly: https://gyazo.com/9de31af556c8b512ea1008509dc8f00e

5 comments

0

try rbxassetid://(asset)

0

didn't fully fix it

0

what does it says in the output?

0

I have tool animations in my game, when i want to animate them i just equip the tool in the char while creating the animation...

0

it has no errors it jst isnt working how its supposed to