I want this animation to look like the video provided of the completed animation. This is an equip animation for a tool I plan to use in my game.
The top video (or the one that looks right) is what I want, but for some reason the animation works for the character, but not the shovel, and I’m confused.
I’ve tried everything, but I’ve been pulling out my hair because for the life of me, I cannot figure out what is wrong, maybe it’s a silly mistake or I’m stupid, but I’ve tried everything, I have spent hours searching the Forum to anything relating to my issue, but to no avail, I am questioning either its something I did wrong or its a Roblox related issue. I have already set the animation priority to Movement, Action, actually I have tried all the priority’s, I’ve tried welds, motor6d, changing how the script receives the animation but nothing has worked. I honestly don’t know what to do, but this is my last ditch effort to fixing this issue. Sorry for the yap, but I pray someone can help me.
The Equip Script (Local Script)
local anim = Instance.new("Animation")
anim.AnimationId = "rbxassetid://94035431726343"
local player = game.Players.LocalPlayer
local char = player.Character or player.CharacterAdded:Wait()
local humanoid = char:WaitForChild("Humanoid")
local animTrack = humanoid:LoadAnimation(anim)
script.Parent.Equipped:Connect(function()
animTrack:Play()
end)
script.Parent.Unequipped:Connect(function()
animTrack:Stop()
end)
The attach script (Server script)
(also because I use a part instead of a handle, this is where I originally got it from: How to animate Tool Parts (Guns, Knifes etc.) - #5 by ap_ek )
game.Players.PlayerAdded:Connect(function(plr)
plr.CharacterAdded:Connect(function(char)
local M6D = char:FindFirstChild("ToolGrip") or Instance.new("Motor6D")
M6D.Name = "ToolGrip"
M6D.Part0 = char:FindFirstChild("RightArm")
M6D.Parent = char
local function onToolAdded(child)
if child:IsA("Tool") and child:FindFirstChild("BodyAttach") then
M6D.Part1 = child.BodyAttach
end
end
char.ChildAdded:Connect(onToolAdded)
for _, child in ipairs(char:GetChildren()) do
onToolAdded(child)
end
end)
end)