How to animate without Humanoid?

I tried to animate my zombie, but seems like zombie doesn’t do animation, I have no errors or warnings too.

local Animations = script.Parent.Parent.Animations
spawn(function()
	local animController = Instance.new("AnimationController", script.Parent.Parent)
	local animTape = Animations:WaitForChild("WALK")
	local animTrack = animController:LoadAnimation(animTape)
	animTrack.Priority = Enum.AnimationPriority.Action
	animTrack:Play()
end)

5 Likes

First thing is to make sure that the walk animation belongs to you, is in your inventory, or was made by roblox.

2 Likes

What @Ninja_Deer said is most likely the problem… I really wish roblox would improve the animation system, but until now we just got to work with what we have… You absolutely have to own the animation for it to work in-game… It will work in studio though… I made a tutorial a while back on animation and rigging models

In this tutorial I discussed everything from rigging the model, to animating it, to finally playing the animation… In the end I did use an Animation controller so you may want to look into it!

(Replied to wrong person, I apologize, mean’t to reply to @Daw588)

4 Likes

I own them, so I don’t know why then.

Try deleting the spawn. I’m not sure what the issue is, but it might do something.

i tried remove ‘spawn’ this doesn’t matter

Is this in a localscript or a script?
If its a script, try having the animation controller already there instead of instancing it.

2 Likes

It is an script, ok, I will try your method :v

Is this a group place? if it is you gotta upload it as group animation.

It is not an group place, it’s just my place published on my account.

Kinda off subject but the parent argument of instance.new() is depreciated, I doubt it will fix the issue but change the way you parent this instance. :slight_smile:

The parent argument is not deprecated, it is simply not recommended if you change properties later due to performance-related problems.

See the following thread:

OP does not edit any properties of the controller so using the parent argument is fine in this scenario. Nothing needs to change, though for consistency’s sake it’d be preferred not to use it.

4 Likes