More for Flop_Mucked with 0-52 encoding.
This commit is contained in:
parent
e00887b865
commit
a307081574
|
@ -170,12 +170,8 @@ class Database:
|
|||
cards = {}
|
||||
c = self.connection.cursor()
|
||||
c.execute(self.sql.query['get_common_cards'], [hand])
|
||||
colnames = [desc[0] for desc in c.description]
|
||||
for row in c.fetchall():
|
||||
s_dict = {}
|
||||
for name, val in zip(colnames, row):
|
||||
s_dict[name] = val
|
||||
cards['common'] = (self.convert_cards(s_dict))
|
||||
# row = c.fetchone()
|
||||
cards['common'] = c.fetchone()
|
||||
return cards
|
||||
|
||||
def convert_cards(self, d):
|
||||
|
|
|
@ -541,19 +541,14 @@ class Sql:
|
|||
"""
|
||||
|
||||
self.query['get_common_cards'] = """
|
||||
select
|
||||
card1Value AS card1value,
|
||||
card1Suit AS card1suit,
|
||||
card2Value AS card2value,
|
||||
card2Suit AS card2suit,
|
||||
card3Value AS card3value,
|
||||
card3Suit AS card3suit,
|
||||
card4Value AS card4value,
|
||||
card4Suit AS card4suit,
|
||||
card5Value AS card5value,
|
||||
card5Suit AS card5suit
|
||||
from BoardCards
|
||||
where handId = %s
|
||||
select
|
||||
boardcard1,
|
||||
boardcard2,
|
||||
boardcard3,
|
||||
boardcard4,
|
||||
boardcard5
|
||||
from Hands
|
||||
where Id = %s
|
||||
"""
|
||||
|
||||
self.query['get_action_from_hand'] = """
|
||||
|
|
Loading…
Reference in New Issue
Block a user