Fix enumerate()

This commit is contained in:
Worros 2010-01-16 13:55:01 +08:00
parent 776405982b
commit 3f0dfd2b26

View File

@ -350,8 +350,9 @@ class DerivedStats():
CG: CheckCall would be a much better name for this.
"""
for i, street in enumerate(hand.actionStreets[2:], start=1):
actions = hand.actions[hand.actionStreets[i]]
#for i, street in enumerate(hand.actionStreets[2:], start=1):
for i, street in enumerate(hand.actionStreets[2:]):
actions = hand.actions[hand.actionStreets[i+1]]
checkers = set()
initial_raiser = None
for action in actions:
@ -361,8 +362,8 @@ class DerivedStats():
elif act == 'checks' and initial_raiser is None:
checkers.add(pname)
elif initial_raiser is not None and pname in checkers:
self.handsplayers[pname]['street%dCheckCallRaiseChance' % i] = True
self.handsplayers[pname]['street%dCheckCallRaiseDone' % i] = act!='folds'
self.handsplayers[pname]['street%dCheckCallRaiseChance' % (i+1)] = True
self.handsplayers[pname]['street%dCheckCallRaiseDone' % (i+1)] = act!='folds'
def seen(self, hand, i):
pas = set()