#Custom tool equip animation works in Roblox Studio but can fail in Live Server

1 messages · Page 1 of 1 (latest)

lost crystal
#

I'm having an issue where an animation appears to play (AnimationTrack.IsPlaying returns true), but there's no visible movement on the character.

This only happens in the live game (real experience) — it works perfectly in Roblox Studio.

I'm using a custom setup where a Motor6D named "QToolGrip" is added to the character's Right Arm on spawn, and Part1 is set to a BodyAttach part inside the equipped Tool. Both the server and the client perform this setup.

I've confirmed that ToolGrip.Part1 is correctly assigned before playing the animation, and I’ve also tried waiting before triggering the animation. Despite this, the animation still doesn’t visually play, even though the console confirms it’s "playing." I've ensured that the rig type matches (R6), and the animation works in Studio previews.

Any ideas on what could be causing this in live games only?

#

All other functions of the framework work perfectly and there's no errors in both the studio and the live server's console. The bug never happens in studio, and happens by chance in live.

#

This is my first time animating, so I followed this guide to help me animate with a tool.

#

These are the relevant scripts:

Serverscript:

game.Players.PlayerAdded:Connect(function(plr)            
    plr.CharacterAdded:Connect(function(char)
        local M6D = Instance.new("Motor6D")
        M6D.Name = "QToolGrip"
        M6D.Part0 = char:FindFirstChild("Right Arm")
        M6D.Parent = char:FindFirstChild("Right Arm")

        char.ChildAdded:Connect(function(child)
            if child:IsA("Tool") and child:FindFirstChild("BodyAttach") then
                M6D.Part1 = child.BodyAttach
            end
        end)
    end)
end)

Localscript:

    local function onEquip(mouse)
        equipped = true
        showTool(false)
        if not hasPreloaded then
            preloadAssets()
            hasPreloaded = true
        end
        
        storedMouse = mouse
        mouse.Icon = customCursor
        playSound(BodyAttach.Equip)
        showTool(true)
        
        local humanoid = localPlayer.Character:FindFirstChild("Humanoid")
        setStance("equip", 16)
        
        bindActions()
        
        setButton1Connections(mouse)
    end
    local function setStance(type, walkSpeed)
        local humanoid = localPlayer.Character:FindFirstChild("Humanoid")
        
        stance = type
        
        stopAllAnims()
        
        if humanoid:FindFirstChild("GeneralStance").Value == "idle" then
            humanoid.WalkSpeed = walkSpeed
        end
        animTracks[type]:Play()
        task.wait()
        
        if animTracks[type].IsPlaying then
            print("Animation", type, "is playing")
        else
            warn("Animation", type, "failed to play")
        end
    end
plucky merlin
#

if so you need to publish the animations in the group too

#

basically you need to publish animations according to the game's publisher

lost crystal
jaunty canyonBOT
#

studio** You are now Level 1! **studio

plucky merlin
lost crystal
#

Plus, if the experience didn't have access to the animation, I would be able to see it as an error in the console. But in my case, there's no error, and when I checked the .IsPlaying boolean, it says it is.

        if animTracks[type].IsPlaying then
            print("Animation", type, "is playing")
        else
            warn("Animation", type, "failed to play")
        end
lost crystal
plucky merlin
#

maybe change the variable "type" name to something like "animationType" just to prevent conflicts with Lua's built-in type() function.

#

I'm just as confused as you are, my only real solution is to publish the animations as the game publisher but you've already done that

lost crystal
lost crystal
#

Up shyduck

ionic wave
lost crystal
ionic wave
#

if not then I don’t know

lost crystal
#

Well I doubt that's the case, I uploaded the anims almost a week ago. Plus it just sometimes works. It has a chance of failing/succeeding every respawn in live, but would always work in studio

lost crystal
#

Up up