Created
April 4, 2017 16:34
-
-
Save joemarchese/b53fc29a48b15e9f782995cd0d99815b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| __author__ = 'joe.marchese' | |
| import random | |
| def gen_hand_size(input_size, mulligan): | |
| if mulligan == True: | |
| input_size -= 1 | |
| return input_size | |
| def draw_hand(deck, hand_size): | |
| hand = random.sample(deck, hand_size) | |
| print_hand(hand) | |
| def print_hand(hand): | |
| print "\n" | |
| for card in hand: | |
| print card | |
| def mulligan(): | |
| mulligan_yn = None | |
| while mulligan_yn != "y" or mulligan_yn != "n": | |
| print "\n Would you like to mulligan?" | |
| mulligan_yn = raw_input("Type 'y' or 'n': ") | |
| if mulligan_yn.lower() == "n": | |
| quit() | |
| elif mulligan_yn.lower() == "y": | |
| return True | |
| else: | |
| pass | |
| Adam_deck = [ | |
| 'Anafenza, Kin-Tree Spirit', 'Anafenza, Kin-Tree Spirit', 'Anafenza, Kin-Tree Spirit', | |
| 'Anafenza, Kin-Tree Spirit', 'Batterskull', 'Brimaz, King of Oreskos', | |
| 'Cartel Aristocrat', 'Dismember', 'Fetid Heath', 'Godless Shrine', | |
| 'Godless Shrine', 'Godless Shrine', 'Godless Shrine', 'Inquisition of Kozilek', | |
| 'Inquisition of Kozilek', 'Inquisition of Kozilek','Inquisition of Kozilek', | |
| 'Kitchen Finks', 'Kitchen Finks', 'Kitchen Finks', 'Kitchen Finks', | |
| 'Liliana of the Veil', 'Liliana of the Veil', 'Liliana of the Veil', 'Liliana of the Veil', | |
| 'Lingering Souls', 'Lingering Souls', 'Lingering Souls', 'Marsh Flats', | |
| 'Marsh Flats', 'Marsh Flats', 'Marsh Flats', 'Mikaeus, the Lunarch', 'Path to Exile', | |
| 'Path to Exile', 'Path to Exile', 'Plains', 'Plains', 'Plains', 'Plains', 'Ranger of Eos', | |
| 'Restoration Angel', 'Swamp', 'Swamp', 'Tectonic Edge', 'Tectonic Edge', 'Thoughtseize', | |
| 'Thoughtseize', 'Tidehollow Sculler', 'Tidehollow Sculler', 'Tidehollow Sculler', | |
| 'Tidehollow Sculler', 'Urborg, Tomb of Yawgmoth', 'Vault of the Archangel', | |
| 'Viscera Seer', 'Windswept Heath', 'Windswept Heath', 'Windswept Heath', | |
| 'Windswept Heath', 'Zealous Persecution' | |
| ] | |
| my_hand_size = 7 | |
| while my_hand_size > 0: | |
| draw_hand(Adam_deck, my_hand_size) | |
| my_hand_size = gen_hand_size(my_hand_size, mulligan()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment