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

How to make animation inside a tool work in game and not only in studio?

Asked by
NiKxzsu 13
6 years ago

I have a tool that has a local script in it that plays an animation on the player when the tool is activated. The amimation seems to work in studio but in game it doesn't. Help?

0
animation is local make sure its located in a local script TheGreatSailor 20 — 6y
0
One reason is that if you are playing an animation from a Script, use the "Animator" thing inside the Humanoid to call LoadAnimation, and if it's from a LocalScript, call LoadAnimation directly from the Humanoid. Can we see the script, though? UgOsMiLy 1074 — 6y
0

1 answer

Log in to vote
0
Answered by
dog6779 25
6 years ago
Edited 6 years ago

So here is a script I found on youtubue once. If you doing on a tool you can do this.

script.Parent.Activated:connect(function()
local dinnertime = script.Parent.Parent.Humanoid:LoadAnimation(script.eat)
dinnertime:Play()
end)

After that I will show a picture what you have to do.

https://gyazo.com/96b939ee88ed20bfcc6209737baf4a9c

Also, for the weld thing. You can use anykind of weld. But you don't have to put the weld script in it.

Also, if you are doing for a group. Make sure you make the animation ON the group animation. Or it won't work if you dare putting your own animation.You know what I mean. :)

And here is the weld script if you want it. https://www.roblox.com/library/1539165089/qPerfectionWeld-Script

Ad

Answer this question