From ad6eb3ebc9294520c87edd43bcab6e8e2422e677 Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Sat, 6 Jan 2018 08:39:06 -0600 Subject: [PATCH 1/7] Add files via upload --- game.py | 4 ++-- player/bots/pure_big_money.py | 4 ++-- player/player.py | 11 +++++++---- table/table.py | 2 ++ 4 files changed, 13 insertions(+), 8 deletions(-) diff --git a/game.py b/game.py index b2848e8..8794d6c 100644 --- a/game.py +++ b/game.py @@ -107,8 +107,8 @@ def get_card_info(): def get_starting_deck(): - return [["Copper", 7], ["Estate", 3]] - # return [["Market", 2], ["Merchant", 2], ["Smithy", 2], ["Village", 2], ["Moat", 2]] + # return [["Copper", 7], ["Estate", 3]] + return [["Market", 2], ["Merchant", 2], ["Smithy", 2], ["Village", 2], ["Moat", 2]] # return [["Militia", 4], ["Cellar", 3], ["Moat", 3]] # return [["Silver", 7], ["Merchant", 3]] # return [["Copper", 4], ["Mine", 2], ["Remodel", 2], ["Workshop", 2]] diff --git a/player/bots/pure_big_money.py b/player/bots/pure_big_money.py index 182cc02..e04b83e 100644 --- a/player/bots/pure_big_money.py +++ b/player/bots/pure_big_money.py @@ -1,6 +1,6 @@ from player.player import Player from card.card import Card - +#name943meats23jet class Pure_Big_Money(Player): def take_action(self): @@ -34,7 +34,7 @@ class Pure_Big_Money(Player): return choice #This will pick either the first or the first least effective purchasing card as this bot doesn't care about that - def militia_input(self, message): + def militia_input(self, message, target_type): choice = self.__get_first_non_Treasure() min_coin = self.get_hand().get_supply()[choice].get_purchase_power() diff --git a/player/player.py b/player/player.py index 116e71a..7328b9d 100644 --- a/player/player.py +++ b/player/player.py @@ -8,7 +8,7 @@ from random import randint class Player: def __init__(self, table): - self.__std_chances = 2 + self.__std_chances = 3 self.__deck = Deck() self.__discard = Discard() self.__hand = Hand() @@ -136,11 +136,13 @@ class Player: print("You have elected to forfeit any remaining plays.") self.__buys = 0 elif pile_index >= self.__table.get_pile_count(): - print("Acceptable inputs range from 0 to " + str(self.__table.get_pile_count() - 1) + ". Try again.") + print("Acceptable inputs range from 0 to " + str(self.__table.get_pile_count() - 1) + ".") chances -= 1 + print("You have " + str(chances) + " chances left to input correctly.") elif self.__table.get_pile(pile_index).get_card_group().get_cost() > self.__purchase_power: - print("You do not have enough coin. Try again.") + print("You do not have enough coin.") chances -= 1 + print("You have " + str(chances) + " chances left to input correctly.") else: self.__buys -= 1 self.__purchase_power -= self.__table.get_pile(pile_index).get_card_group().get_cost() @@ -149,6 +151,7 @@ class Player: str(self.__purchase_power) + " coin(s) and " + str(self.__buys) + " buy(s) following purchase.") self.__table.get_pile(pile_index).transfer_top_card(self.__discard) self.claim_top_card(self.__discard) + chances = self.get_std_chances() def take_turn(self): self.__turn_setup() @@ -243,7 +246,7 @@ class Player: print("Coin: " + str(self.__purchase_power)) self.print_hand() self.__print_discard() - # self.__print_deck() + print("") def __turn_setup(self): self.__actions.int = 1 diff --git a/table/table.py b/table/table.py index a26f13b..4a78636 100644 --- a/table/table.py +++ b/table/table.py @@ -81,5 +81,7 @@ class Table: print(str(index) + ": " + s.identify()) index += 1 + print("") + def __str__(self): return "A table with " + str(len(self.__pile)) + " card piles and " + str(len(self.__player)) + " players." From 3c604ef0e5fbde114d94b743f44e55aa12cb145a Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Sat, 6 Jan 2018 11:18:50 -0600 Subject: [PATCH 2/7] Delete laf.xml --- _windows/laf.xml | 5 ----- 1 file changed, 5 deletions(-) delete mode 100644 _windows/laf.xml diff --git a/_windows/laf.xml b/_windows/laf.xml deleted file mode 100644 index c1f98d9..0000000 --- a/_windows/laf.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file From ff89db11d1622d2ea027c04a875addd1d5e52646 Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Sat, 6 Jan 2018 11:36:04 -0600 Subject: [PATCH 3/7] Delete colors.scheme.xml --- colors.scheme.xml | 5 ----- 1 file changed, 5 deletions(-) delete mode 100644 colors.scheme.xml diff --git a/colors.scheme.xml b/colors.scheme.xml deleted file mode 100644 index 39308cd..0000000 --- a/colors.scheme.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file From 0aef758b500b68525f41481228d1cecf3294d0b3 Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Sat, 6 Jan 2018 11:36:13 -0600 Subject: [PATCH 4/7] Delete debugger.xml --- debugger.xml | 13 ------------- 1 file changed, 13 deletions(-) delete mode 100644 debugger.xml diff --git a/debugger.xml b/debugger.xml deleted file mode 100644 index 544ab15..0000000 --- a/debugger.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file From d37c0c931ae864fe55b3f2e3991608811b44ad89 Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Sat, 6 Jan 2018 11:36:20 -0600 Subject: [PATCH 5/7] Delete editor.xml --- editor.xml | 6 ------ 1 file changed, 6 deletions(-) delete mode 100644 editor.xml diff --git a/editor.xml b/editor.xml deleted file mode 100644 index 19bd26a..0000000 --- a/editor.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - \ No newline at end of file From 9e9b4816bd6f36b2fd49edc9e14175cc377f73de Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Sat, 6 Jan 2018 11:36:27 -0600 Subject: [PATCH 6/7] Delete filetypes.xml --- filetypes.xml | 5 ----- 1 file changed, 5 deletions(-) delete mode 100644 filetypes.xml diff --git a/filetypes.xml b/filetypes.xml deleted file mode 100644 index 137cd9e..0000000 --- a/filetypes.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file From 1d13a4d6d772daf7215993ebb9bde8ddfa98024a Mon Sep 17 00:00:00 2001 From: Brad Stein Date: Sat, 6 Jan 2018 11:36:39 -0600 Subject: [PATCH 7/7] Delete usageView.xml --- usageView.xml | 8 -------- 1 file changed, 8 deletions(-) delete mode 100644 usageView.xml diff --git a/usageView.xml b/usageView.xml deleted file mode 100644 index 1e05532..0000000 --- a/usageView.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - \ No newline at end of file