added HandsPlayers.sitout as discussed on ML
This commit is contained in:
parent
6e296cf38f
commit
6b417ebdd4
|
@ -75,7 +75,7 @@ except ImportError:
|
|||
use_numpy = False
|
||||
|
||||
|
||||
DB_VERSION = 122
|
||||
DB_VERSION = 123
|
||||
|
||||
|
||||
# Variance created as sqlite has a bunch of undefined aggregate functions.
|
||||
|
@ -1561,6 +1561,7 @@ class Database:
|
|||
pids[p],
|
||||
pdata[p]['startCash'],
|
||||
pdata[p]['seatNo'],
|
||||
pdata[p]['sitout'],
|
||||
pdata[p]['card1'],
|
||||
pdata[p]['card2'],
|
||||
pdata[p]['card3'],
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
#Copyright 2008 Carl Gherardi
|
||||
#This program is free software: you can redistribute it and/or modify
|
||||
|
@ -139,6 +140,7 @@ class DerivedStats():
|
|||
for player in hand.players:
|
||||
self.handsplayers[player[1]]['seatNo'] = player[0]
|
||||
self.handsplayers[player[1]]['startCash'] = int(100 * Decimal(player[2]))
|
||||
self.handsplayers[player[1]]['sitout'] = False #TODO: implement actual sitout detection
|
||||
|
||||
# XXX: enumerate(list, start=x) is python 2.6 syntax; 'start'
|
||||
#for i, street in enumerate(hand.actionStreets[2:], start=1):
|
||||
|
|
|
@ -494,6 +494,7 @@ class Sql:
|
|||
startCash INT NOT NULL,
|
||||
position CHAR(1),
|
||||
seatNo SMALLINT NOT NULL,
|
||||
sitout BOOLEAN NOT NULL,
|
||||
|
||||
card1 smallint NOT NULL, /* 0=none, 1-13=2-Ah 14-26=2-Ad 27-39=2-Ac 40-52=2-As */
|
||||
card2 smallint NOT NULL,
|
||||
|
@ -610,6 +611,7 @@ class Sql:
|
|||
startCash INT NOT NULL,
|
||||
position CHAR(1),
|
||||
seatNo SMALLINT NOT NULL,
|
||||
sitout BOOLEAN NOT NULL,
|
||||
|
||||
card1 smallint NOT NULL, /* 0=none, 1-13=2-Ah 14-26=2-Ad 27-39=2-Ac 40-52=2-As */
|
||||
card2 smallint NOT NULL,
|
||||
|
@ -725,6 +727,7 @@ class Sql:
|
|||
startCash INT NOT NULL,
|
||||
position TEXT,
|
||||
seatNo INT NOT NULL,
|
||||
sitout BOOLEAN NOT NULL,
|
||||
|
||||
card1 INT NOT NULL, /* 0=none, 1-13=2-Ah 14-26=2-Ad 27-39=2-Ac 40-52=2-As */
|
||||
card2 INT NOT NULL,
|
||||
|
@ -3748,6 +3751,7 @@ class Sql:
|
|||
playerId,
|
||||
startCash,
|
||||
seatNo,
|
||||
sitout,
|
||||
card1,
|
||||
card2,
|
||||
card3,
|
||||
|
@ -3847,7 +3851,8 @@ class Sql:
|
|||
%s, %s, %s, %s, %s,
|
||||
%s, %s, %s, %s, %s,
|
||||
%s, %s, %s, %s, %s,
|
||||
%s, %s, %s, %s, %s
|
||||
%s, %s, %s, %s, %s,
|
||||
%s
|
||||
)"""
|
||||
|
||||
if db_server == 'mysql':
|
||||
|
|
Loading…
Reference in New Issue
Block a user