if debug: print "6_8: placing 6 and 8, stake = %s" % stake2 if stake3 > line_bet and num_come_bets < 3: if come.play_come_bet(line_bet): num_come_bets += 1 stake3 -= line_bet if debug: print "Come: come bet %s stake = %s" % (line_bet, stake3) # print "Across:" # print across.show_bets() # print "\n6_8:" # print six_eight.show_bets() # print "\nCome:" # print come.show_bets() # Roll the dice game.roll_dice(verbose=False) # print "before winnings s1 = %s, s2 = %s, s3 = %s" % (stake1, stake2, stake3) # Check the winnings win1 = across.check_winnings(verbose=False) if win1: stake1 += win1 win2 = six_eight.check_winnings(verbose=False) if win2: stake2 += win2 win3 = come.check_winnings(verbose=False) if win3: stake3 += win3 # print "Roll<%s> s1 = %s, s2 = %s, s3 = %s" % (i, stake1, stake2, stake3) # make sure all come bets have odds for c_b in come.come_bets_wo_odds(): if come.play_come_bet_odds(c_b, line_odds):
stake -= line_odds if debug: print "pass line odds %s" % line_odds have_place = b.have_place_bets() if stake > 27 and g.is_button_on() and not have_place: for i in [4, 5, 6, 8, 9, 10]: if i != 6 and i != 8 and i != g.current_point: b.place_the_number(i, 5) stake -= 5 if i != g.current_point and (i == 6 or i == 8): b.place_the_number(i, 6) stake -= 6 if debug: print "placing across, stake = %s" % stake g.roll_dice(verbose=debug) if debug: print b.show_bets() win = b.check_winnings(verbose=debug) if win: stake += win if debug: print "Roll %s stake = %s" % (i, stake) print "Ending Stake = %s, ATM withdraws = %s" % (stake, atm) stakes.append(stake) atms.append(atm) profits.append(stake - atm) # print "Stake (min, mean, max) = (%s, %s, %s)" % (min(stakes), stats.mean(stakes), max(stakes)) # print "ATM (min, mean, max) = (%s, %s, %s)" % (min(atms), stats.mean(atms), max(atms))