Fix code that stopped animation immediately after starting it, due to thinking it has completed (Fixes #1370)