lib/bitpoker/duel.rb
def play_round
      # Don't perform deal if a game is finished
      return nil if finished?

      @round_counter += 1

      # Init new round
      round = Round.new(@bots)

      # Proceed round process until it is finished
      until round.state == Round::STATE_FINISHED
        @croupier.perform_next_step(round)
      end

      # Update total score
      @total_score[0] += round.score[0]
      @total_score[1] += round.score[1]

      self
    end
# Play one round of the BitPoker
#
# @return [Duel]
Play one round of the BitPoker
Play one round of the BitPoker
def play_round
      return nil if finished?
      @round_counter += 1
      round = Round.new(@bots)
      until round.state == Round::STATE_FINISHED
        @croupier.perform_next_step(round)
      end
      @total_score[0] += round.score[0]
      @total_score[1] += round.score[1]
      self
    end
def play_round return nil if finished? @round_counter += 1 round = Round . new ( @bots ) until round . state == Round :: STATE_FINISHED @croupier . perform_next_step ( round ) end @total_score [ 0 ] += round . score [ 0 ] @total_score [ 1 ] += round . score [ 1 ] self end
Play one round of the BitPoker
Play one round of the BitPoker
# Don't perform deal if a game is finished # Init new round # Proceed round process until it is finished # Update total score
None
Duel