#Animation not stopping

31 messages · Page 1 of 1 (latest)

ornate elk
#

Help!

#

(Starting the animation)

local AnimationTrack = Humanoid:LoadAnimation(ShovelAnim)
                AnimationTrack:Play()```
#

(Trying to stop it)

local AnimationTrack = Humanoid:LoadAnimation(ShovelAnim)
    AnimationTrack:Stop()```
#

When I try to stop the animation, I have made it so something fires an event and in that event it stops the Animation, could this be the reason why it wont stop?

late musk
#

an animation only needs to be loaded once and stopped by just referencing the one u loaded to start

#

so instead of stopping it and going local animationtrack = humanoid etc

#

just simply put AnimationTrack:Stop()

ornate elk
#

Ahh makes sense, can’t believe I didn’t think of that 🤦‍♂️

late musk
#

but it is important that the 2 are in the same script

#

the :play() and

#

:stop()

ornate elk
#

Yeah

late musk
#

if they aren't its nothing to worry about u can just use a for loop

#

and stop all the animations playing on the player

late musk
#

humanoid animations are depracated and can be unreliable

ornate elk
#

Is that where you would add the animation inside the script?

late musk
#

local AnimationTrack = Humanoid:LoadAnimation(ShovelAnim)

#

u would do

#

local AnimationTrack = Humanoid.Animator:LoadAnimation(ShovelAnim)

ornate elk
#

Yeah

late musk
#

more recent instance to load animations on

ornate elk
#

Awesome, I'll change that now

late musk
#

u can still use depracated stuff but its best to just use the latest stuff

#

in case roblox goes like sicko mode and removes it entirely lol

#

hope that helped

ornate elk
#

Yeah it did, thank you!

wild furnace
late musk