Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

how to detect if a model is moving?

i have a model with Humanoid in it, and i want to play a walking animation when it moves, but ive tried velocity and running but they dont seem to work. (is my model supposed to be slightly sliding away? even when its not supposed to move?)

1 answer

I think that this will help:

model:FindFirstChild('Humanoid').Running:connect(function(speed)
    if speed > 0 then
        print("The model is moving")
    else
        print("The model isn't moving")
    end
end)

3 comments

0

iirc, The humanoid is allways moving, very slightly.

0

how would i prevent this? regular npcs dont move right?

0

Do if speed > 3 or >10

This discussion is preserved as it was. New answers, comments, and votes are closed.