def arson_attack_target(game_control, user): def check_has_card(target): count_cards = game_control.player_cards_count_at(target, 'onhand') if user == target: return 1 < count_cards return 0 < count_cards all_players = game_control.players_from_current() targets = filter(check_has_card, all_players) return hints.fix_target_action(hints.target_filter('arson attack', user, targets))
def duel_target(game_control, user): targets = game_control.succeeding_players() return fix_target_action(target_filter('duel', user, targets))
def steal_target(gc, user): players = filter(lambda p: gc.player_has_cards(p), gc.succeeding_players()) players = range_filter(gc, user, 'steal', players) return fix_target_action(target_filter('steal', user, players))
def sabotage_targets_h(gc, user): return fix_target_action(sabotage_targets(gc, user))
def slash_targets_h(gc, user): return fix_target_action(slash_targets(gc, user))