def stop_playing(wait_for_confirmation = false)
      @was_playing_before = @playing
      @speaking = false
      @playing = false
      sleep IDEAL_LENGTH / 1000.0 if @was_playing_before

      return unless wait_for_confirmation

      @has_stopped_playing = false
      sleep IDEAL_LENGTH / 1000.0 until @has_stopped_playing
      @has_stopped_playing = false
    end
def stop_playing(wait_for_confirmation = false)
      @was_playing_before = @playing
      @speaking = false
      @playing = false
      sleep IDEAL_LENGTH / 1000.0 if @was_playing_before

      return unless wait_for_confirmation

      @has_stopped_playing = false
      sleep IDEAL_LENGTH / 1000.0 until @has_stopped_playing
      @has_stopped_playing = false
    end
Stops the current playback entirely.
 @param wait_for_confirmation [true, false] Whether the method should wait for confirmation from the playback
   method that the playback has actually stopped.