Purple ball changes direction when hits the wall