Added basic stop conditions