add 20 fps limit and loop break when nodes are almost not moving