diff --git a/find_winning_deck.js b/find_winning_deck.js index 25465c5..71692ad 100644 --- a/find_winning_deck.js +++ b/find_winning_deck.js @@ -136,7 +136,11 @@ export async function do_riddle(riddle, handler) { } else { let combo_idx = 0; const tried_combos = {}; - for (let combo of k_combinations(my_cards, 8)) { + let slot = 8; + if (riddle.players[my_idx].round_number) { + slot = Math.min(8, riddle.players[my_idx].round_number + 2); + } + for (let combo of k_combinations(my_cards, slot)) { combo_idx += 1; // sort the combo combo.sort(); diff --git a/gamestate_full_ui.js b/gamestate_full_ui.js index 238e7c9..9f8b69a 100644 --- a/gamestate_full_ui.js +++ b/gamestate_full_ui.js @@ -710,23 +710,25 @@ export class Player { this.cards = this.cards.slice(0, slot); } reset_can_play() { - { - const cards = this.cards; - for (let i=0; i 0) { const swordplay_talent_cards = this.swordplay_talent_cards; let seen_yeying = false; @@ -2817,6 +2819,7 @@ export class GameState { this.process_this_card_chases(); } } + me.xuanming_recurring_hp = me.hp; if (this.check_for_death()) { return; } diff --git a/names.json b/names.json index 826fb07..f3593a0 100644 --- a/names.json +++ b/names.json @@ -188,7 +188,7 @@ { "id": 114041, "name": "CentiBird Spirit Sword Rhythm", - "namecn": "白鸟灵剑诀" + "namecn": "百鸟灵剑诀" }, { "id": 114051, diff --git a/web_worker.js b/web_worker.js index 7cf68ad..1f9d556 100644 --- a/web_worker.js +++ b/web_worker.js @@ -140,7 +140,7 @@ self.onmessage = async (event) => { const myHP = game.players[my_idx].hp; const enemyHP = game.players[enemy_idx].hp; const turns = game.turns_taken; - const winning_margin = (myHP - enemyHP) / turns; + const winning_margin = (myHP * 2 - enemyHP - Math.min(turns, 8) * 2); const p_combo = combo.slice(); if (winning_margin > best_winning_margin) { winning_decks.length = 0;