This commit is contained in:
Alberto Xamin 2020-12-23 14:41:13 +01:00
parent 0ac0a66c06
commit 95b6f016d2
No known key found for this signature in database
GPG Key ID: 4F026F48309500A2
2 changed files with 16 additions and 5 deletions

View File

@ -19,6 +19,12 @@ class Sbornia(CardEvent):
self.desc = "I personaggi perdono la loro abilità speciale" self.desc = "I personaggi perdono la loro abilità speciale"
self.desc_eng = "" self.desc_eng = ""
class Sete(CardEvent):
def __init__(self):
super().__init__("Sete", "🥵")
self.desc = "I giocatori pescano solo 1 carta"
self.desc_eng = ""
class MezzogiornoDiFuoco(CardEvent): class MezzogiornoDiFuoco(CardEvent):
def __init__(self): def __init__(self):
super().__init__("Mezzogiorno di Fuoco", "🔥") super().__init__("Mezzogiorno di Fuoco", "🔥")
@ -37,7 +43,7 @@ def get_all_events():
# IlTreno(), # IlTreno(),
Sbornia(), Sbornia(),
# Seromone(), # Seromone(),
# Sete(), Sete(),
# Sparatoria(), # Sparatoria(),
] ]
random.shuffle(cards) random.shuffle(cards)

View File

@ -382,7 +382,8 @@ class Player:
self.pending_action = PendingAction.PLAY self.pending_action = PendingAction.PLAY
if pile == 'scrap' and self.character.check(self.game, chars.PedroRamirez): if pile == 'scrap' and self.character.check(self.game, chars.PedroRamirez):
self.hand.append(self.game.deck.draw_from_scrap_pile()) self.hand.append(self.game.deck.draw_from_scrap_pile())
self.hand.append(self.game.deck.draw()) if not self.game.check_event(ceh.Sete):
self.hand.append(self.game.deck.draw())
self.sio.emit('chat_message', room=self.game.name, self.sio.emit('chat_message', room=self.game.name,
data=f'_draw_from_scrap|{self.name}') data=f'_draw_from_scrap|{self.name}')
elif type(pile) == str and pile != self.name and pile in self.game.players_map and self.character.check(self.game, chars.JesseJones) and len(self.game.get_player_named(pile).hand) > 0: elif type(pile) == str and pile != self.name and pile in self.game.players_map and self.character.check(self.game, chars.JesseJones) and len(self.game.get_player_named(pile).hand) > 0:
@ -391,11 +392,13 @@ class Player:
self.game.get_player_named(pile).notify_self() self.game.get_player_named(pile).notify_self()
self.sio.emit('chat_message', room=self.game.name, self.sio.emit('chat_message', room=self.game.name,
data=f'_draw_from_player|{self.name}|{pile}') data=f'_draw_from_player|{self.name}|{pile}')
self.hand.append(self.game.deck.draw()) if not self.game.check_event(ceh.Sete):
self.hand.append(self.game.deck.draw())
elif self.character.check(self.game, chd.BillNoface): elif self.character.check(self.game, chd.BillNoface):
self.hand.append(self.game.deck.draw()) self.hand.append(self.game.deck.draw())
for i in range(self.max_lives-self.lives): if not self.game.check_event(ceh.Sete):
self.hand.append(self.game.deck.draw()) for i in range(self.max_lives-self.lives):
self.hand.append(self.game.deck.draw())
else: else:
for i in range(2): for i in range(2):
card: cs.Card = self.game.deck.draw() card: cs.Card = self.game.deck.draw()
@ -406,6 +409,8 @@ class Player:
p.notify_card(self, card, 'blackjack_special' if self.character.check(self.game, chars.BlackJack) else 'foc.leggedelwest') p.notify_card(self, card, 'blackjack_special' if self.character.check(self.game, chars.BlackJack) else 'foc.leggedelwest')
if card.check_suit(self.game, [cs.Suit.HEARTS, cs.Suit.DIAMONDS]) and self.character.check(self.game, chars.BlackJack): if card.check_suit(self.game, [cs.Suit.HEARTS, cs.Suit.DIAMONDS]) and self.character.check(self.game, chars.BlackJack):
self.hand.append(self.game.deck.draw()) self.hand.append(self.game.deck.draw())
if self.game.check_event(ceh.Sete):
return self.notify_self()
if self.character.check(self.game, chd.PixiePete): if self.character.check(self.game, chd.PixiePete):
self.hand.append(self.game.deck.draw()) self.hand.append(self.game.deck.draw())
self.notify_self() self.notify_self()