                           :ships => %{}},
               :explosions => [],
               :collision_pid => collision_pid,
+              :min_asteroid_count => asteroid_count,
               :clock_ms => Clock.now_ms,
               :kby => %{}}
     start_ticker(self(), fps)

    d = World.Point.distance(ox, oy, sx, sy)

    theta = :math.atan2(sy - oy, sx - ox)
    |> World.Velocity.wrap_angle()
    |> World.Velocity.round_theta()



  # Asteroids

  def new_asteroid_in_game(a, game) do
    id = Identifiers.next(game.ids)
    {:ok, pid} = Asteroid.start_link(id, a)
    put_in(game.pids.asteroids[id], pid)
  end

  defp maybe_spawn_asteroid(game) do
    active_asteroid_count = length(Map.keys(game.pids.asteroids))
    if active_asteroid_count < game.min_asteroid_count do
      new_asteroid_in_game(Asteroid.random_asteroid, game)
    else
      game
    end
  end

  # Game state
