Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

Animation for Custom Rig only plays in Studio?

Asked by 7 years ago
Edited 7 years ago

Using MeshParts and Motor6D's I put together a custom rig for what's essentially a giant robot. Everything seems to be put together right and I created multiple animations for them, here's a few:

Walking Animation Running Animation Flying Animation

I wrote a short script for playing one of the animations, and running it in studio it seems to work perfectly but once I open the game in a live server the script doesn't appear to do anything. Something else that's interesting is that usually an NPC will only play an animation when loaded into an AnimationController, but this animation only plays in studio when loaded into the robot's Humanoid and not in game or in studio if I load it into an AnimationController. Here's the short script I wrote to play the animation:

function wyd()
--  local AC = Instance.new("AnimationController")
--  AC.Parent = script.Parent
    local AC = script.Parent.Humanoid
    local anim = Instance.new("Animation")
    anim.Parent = script.Parent
    anim.AnimationId = "http://www.roblox.com/asset/?id=440188691"
    local animTrack = AC:LoadAnimation(anim)
    animTrack:Play()
end

wyd()

Let me know if you see anything immediately wrong with my code or with how the rig itself might not be correctly set up? Thanks!

0
Is it a LocalScript? Because if it is, try switching to a normal Script. RiftTalon 98 — 7y
0
dude, ive been struggling with this, i have no idea whats been causing this but maybe taling a look at the animation updates may solve your problem. http://devforum.roblox.com/t/animation-updates/26323 Jumbuu 110 — 7y
0
Try double checking your script see if you missed anything, or capitalizations. jesusbeef 33 — 7y

Answer this question