add john pain

This commit is contained in:
Alberto Xamin 2023-03-05 18:30:05 +00:00
parent 8f645cf82a
commit 499763ffca
No known key found for this signature in database
GPG Key ID: 5ABFCD8A22EA6F5D
2 changed files with 12 additions and 2 deletions

View File

@ -4,6 +4,7 @@ import bang.cards as cs
import bang.expansions.fistful_of_cards.card_events as ce
import bang.expansions.high_noon.card_events as ceh
import bang.expansions.wild_west_show.card_events as cew
import bang.expansions.wild_west_show.characters as chw
import bang.expansions.gold_rush.shop_cards as grc
from globals import G
@ -83,6 +84,15 @@ class Deck:
def pick_and_scrap(self) -> cs.Card:
card = self.cards.pop(0)
jpain = None
for p in self.game.players:
if isinstance(p, chw.JohnPain) and len(p.hand) < 6:
jpain = p
break
if jpain:
jpain.hand.append(card)
jpain.notify_self()
else:
self.scrap_pile.append(card)
if len(self.cards) == 0:
self.reshuffle()

View File

@ -82,7 +82,7 @@ def all_characters() -> List[Character]:
FlintWestwood(),
# GaryLooter(),
# GreygoryDeckard(),
# JohnPain(),
JohnPain(),
# LeeVanKliff(),
# TerenKill(),
# YoulGrinner(),