refactor asteroids