summaryrefslogtreecommitdiff
path: root/rules.js
diff options
context:
space:
mode:
Diffstat (limited to 'rules.js')
-rw-r--r--rules.js57
1 files changed, 39 insertions, 18 deletions
diff --git a/rules.js b/rules.js
index d7e89c6..b06f4be 100644
--- a/rules.js
+++ b/rules.js
@@ -369,7 +369,8 @@ function game_view(state, current) {
}
else if (current !== game.active &&
!game.active.includes(current)) {
- let inactive = states[game.state].inactive || game.state;
+ let src = get_active_node_args()?.src;
+ let inactive = src ? get_source_inactive(src) : states[game.state].inactive || game.state;
view.prompt = Array.isArray(game.active)
? `Waiting for ${game.active.join(' and ')} to ${inactive}.`
: `Waiting for ${game.active} to ${inactive}.`;
@@ -549,7 +550,7 @@ const track_icon_to_track_id_map = {
d_soviet_support: data_1.SOVIET_SUPPORT,
};
states.activate_icon = {
- inactive: 'activate an icon',
+ inactive: 'activate a Morale Bonus icon',
prompt() {
gen_spend_hero_points();
const c = cards[game.played_card];
@@ -849,7 +850,7 @@ states.change_active_player = {
},
};
states.choose_area_ap = {
- inactive: 'choose area to use Action Points',
+ inactive: 'use action points',
prompt() {
gen_spend_hero_points();
const use_morale_bonus = game.can_use_mb === 1 && game.bonuses[data_1.MORALE_BONUS] === data_1.ON;
@@ -947,7 +948,7 @@ states.choose_area_ap = {
},
};
states.change_bonus = {
- inactive: 'select Bonus',
+ inactive: 'toggle Bonus',
prompt() {
gen_spend_hero_points();
const args = get_active_node_args();
@@ -986,7 +987,7 @@ states.change_bonus = {
},
};
states.play_card = {
- inactive: 'play a card',
+ inactive: 'play another card',
prompt() {
gen_spend_hero_points();
view.prompt = 'Play another card.';
@@ -1024,7 +1025,7 @@ states.play_card = {
},
};
states.choose_card = {
- inactive: 'choose a card',
+ inactive: 'play a card for this turn',
prompt(player) {
gen_spend_hero_points();
view.prompt = 'Play a card for this turn.';
@@ -1071,7 +1072,7 @@ states.choose_card = {
},
};
states.choose_final_bid = {
- inactive: 'choose Final Bid',
+ inactive: 'add a card to the Final Bid',
prompt() {
view.prompt = 'Add a card to the Final Bid.';
const faction = get_active_faction();
@@ -1112,7 +1113,7 @@ function setup_momentum() {
}
}
states.choose_medallion = {
- inactive: 'claim a medallion',
+ inactive: 'claim a Medallion',
prompt() {
gen_spend_hero_points();
view.prompt = 'Claim a Medallion.';
@@ -1164,7 +1165,7 @@ states.choose_medallion = {
},
};
states.confirm_turn = {
- inactive: 'confirm their turn',
+ inactive: 'confirm their move',
prompt() {
view.prompt = 'You will not be able to undo this action.';
gen_action('confirm');
@@ -1174,7 +1175,7 @@ states.confirm_turn = {
},
};
states.confirm_fascist_turn = {
- inactive: 'confirm fascist turn',
+ inactive: 'end the Fascist turn',
prompt() {
view.prompt = "Done.";
gen_action('confirm');
@@ -1184,7 +1185,7 @@ states.confirm_fascist_turn = {
},
};
states.draw_card = {
- inactive: 'draw a card',
+ inactive: 'draw cards',
auto_resolve() {
const { src, v } = get_active_node_args();
if (src !== 'fascist_test') {
@@ -1319,7 +1320,7 @@ states.end_of_year_discard = {
},
};
states.hero_points = {
- inactive: 'gain Hero points',
+ inactive: 'gain or lose Hero points',
auto_resolve() {
const { src, v } = get_active_node_args();
if (src !== 'fascist_test') {
@@ -1390,7 +1391,7 @@ function resolve_player_with_most_hero_points(faction) {
resolve_active_and_proceed();
}
states.select_player_with_most_hero_points = {
- inactive: 'choose a Player',
+ inactive: 'choose who will gain or lose Hero points',
prompt() {
gen_spend_hero_points();
const { v } = get_active_node_args();
@@ -1512,7 +1513,7 @@ function can_move_track_down(track_id) {
return true;
}
states.move_track_up_or_down = {
- inactive: 'move a track',
+ inactive: 'move a Track',
auto_resolve() {
const { track_id, strength } = get_active_node_args();
const can_move_up = can_move_track_up(track_id);
@@ -1608,7 +1609,7 @@ function set_player_turn_prompt({ can_play_card, use_ap, use_momentum, use_moral
view.prompt = "Player Turn: Done.";
}
states.player_turn = {
- inactive: 'play their turn',
+ inactive: 'use their played card',
prompt() {
gen_spend_hero_points();
const faction_id = get_active_faction();
@@ -1931,7 +1932,7 @@ states.spend_hero_points = {
},
};
states.swap_card_tableau_hand = {
- inactive: 'swap cards',
+ inactive: 'swap cards in their tableau and hand',
prompt() {
gen_spend_hero_points();
view.prompt = 'Swap a card in your tableau with a card in your hand.';
@@ -2045,7 +2046,7 @@ function trash_card(faction) {
resolve_active_and_proceed();
}
states.use_organization_medallion = {
- inactive: 'use Organization Medallion',
+ inactive: 'choose to use Organization Medallion',
prompt() {
gen_spend_hero_points();
view.prompt = 'Use Organization Medallion?';
@@ -2076,7 +2077,7 @@ states.use_organization_medallion = {
},
};
states.use_strategy_medallion = {
- inactive: 'use Strategy Medallion',
+ inactive: 'choose to use Strategy Medallion',
prompt() {
gen_spend_hero_points();
view.prompt = 'Use Strategy Medallion?';
@@ -3000,6 +3001,26 @@ function get_source_name(source) {
}
return source;
}
+function get_source_inactive(source) {
+ switch (source) {
+ case 'player_event':
+ return 'execute ' + cards[game.played_card].title;
+ case 'fascist_event':
+ return 'execute ' + cards[game.current_events[game.current_events.length - 1]].title;
+ case 'fascist_test':
+ return 'resolve Test';
+ case 'tr0': return 'trigger ' + tracks[0].name + ' icon';
+ case 'tr1': return 'trigger ' + tracks[1].name + ' icon';
+ case 'tr2': return 'trigger ' + tracks[2].name + ' icon';
+ case 'tr3': return 'trigger ' + tracks[3].name + ' icon';
+ case 'tr4': return 'trigger ' + tracks[4].name + ' icon';
+ case 'track_icon':
+ throw "UNUSED";
+ case data_1.MOMENTUM:
+ return 'use Momentum';
+ }
+ return source;
+}
function get_factions_with_most_hero_poins() {
let most_hero_points = null;
let faction_ids = [];