Help with tool holding

Hello i have made a crate tool and a holding animation but i am not sure on how to implement the animation into the tool. How would i be able to do this?

Please send me a roblox documentation link if its explained there

Set your animation type to action so it doesn’t interfere with the walking animation, then turn off can collide so it doesn’t collide with the players character, then load up your animation onto an Animator and play it when your crate/tool is equipped.

you can use tool.Equipped for the event.

1 Like

local function onEquipped(_mouse)
	local Players = game:GetService("Players")
	local player = Players.LocalPlayer
	local character = player.Character or player.CharacterAdded:Wait()


	local humanoid = character:WaitForChild("Humanoid")
	local animator = humanoid:WaitForChild("Animator")

	
	local kickAnimation = Instance.new("Animation")
	kickAnimation.AnimationId = "rbxassetid://122064464197678"  

	local kickAnimationTrack = animator:LoadAnimation(kickAnimation)


	kickAnimationTrack:Play()

	kickAnimationTrack:GetMarkerReachedSignal("KickEnd"):Connect(function(paramString)
		print(paramString)
	end)
end

Tool.Equipped:Connect(onEquipped)  

this is the code that i got from the documentation site but its not working i apologize if this is completely wrong but could you help me fix it? i didnt see any errors in the output

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.