snake game using a * algorithm