游戏可以运行
This commit is contained in:
@@ -125,6 +125,12 @@ class Game:
|
||||
self.ui.deck_builder_faction = self.player_faction
|
||||
self.state = "deck_build"
|
||||
return
|
||||
if "random" in self.ui.menu_buttons and self.ui.menu_buttons["random"].collidepoint(pos):
|
||||
from card_game.config import FACTIONS
|
||||
others = [f for f in FACTIONS.keys() if f != self.player_faction]
|
||||
self.ai_faction = random.choice(others)
|
||||
self._start_game()
|
||||
return
|
||||
fid = self.ui.get_faction_at(pos)
|
||||
if fid and fid != self.player_faction:
|
||||
self.ai_faction = fid
|
||||
|
||||
Reference in New Issue
Block a user