Check if an NPC / Player is moving?

I’m working on J-Dude’s Tremors graboids and I need to find an appropriate function that checks if a Player or an NPC is moving, Obviously for when the Graboid checks for surface movement to snatch prey…
IsNPCMoving is alright, but I’m looking for a function that applies to both entities & players.

[lua]if ent:GetVelocity():Length() > 0 then
– your code
end[/lua]

There may be subtle movement so the best bet is to use 5.

Thanks very much!
I will not be able to test this for some time until GMod stops acting up on this computer but if it doesn’t work the first time, I’ll try numbers around five or higher.