generated from mwc/project_game
updated card mapping
This commit is contained in:
Binary file not shown.
2
card.py
2
card.py
@@ -10,7 +10,7 @@ class Card:
|
||||
return str(self.face)
|
||||
|
||||
def deal(self):
|
||||
self.face = randint(1, 11)
|
||||
self.face = randint(1, 13)
|
||||
#I think here we should return 1-13 to include ace and face cards.
|
||||
#This will make checking if 4 of a kind have been dealt easier.
|
||||
#THEN when it comes to scoring we can use the value to calculate face cards as 10 points.
|
||||
|
||||
@@ -14,9 +14,13 @@ def deal_first():
|
||||
dealer_show = Card()
|
||||
if dealer_show == 1:
|
||||
print("dealer shown card:"+ "Ace")
|
||||
if dealer_show == 10:
|
||||
if dealer_show == 11:
|
||||
print("dealer shown card:"+ "Jack")
|
||||
#continue code here to show the correct face based on what was drawn
|
||||
if dealer_show == 12:
|
||||
print("dealer shown code:"+ "Queen")
|
||||
if dealer_show == 13:
|
||||
print("dealer shown card:"+ "King")
|
||||
|
||||
print("dealer shown card:"+ str(dealer_show))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user