From 123e4f3941b9ed9bfff6613939c7988a3d4d3658 Mon Sep 17 00:00:00 2001 From: Mischa Untaga <99098079+MischaU8@users.noreply.github.com> Date: Thu, 30 Nov 2023 16:23:11 +0100 Subject: show how many cubes to add/remove --- rules.js | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'rules.js') diff --git a/rules.js b/rules.js index 09befdf..f4e91e6 100644 --- a/rules.js +++ b/rules.js @@ -2442,7 +2442,11 @@ states.vm_add_cubes = { // if (has_opponent_cubes) // event_prompt("Choose a cube color to add or remove an Opponent's cube.") } else { - event_prompt(`Add a ${COLOR_NAMES[game.vm.cube_color]} cube.`) + + event_prompt(`Add ${pluralize(game.vm.count, COLOR_NAMES[game.vm.cube_color] + ' cube')}`) + if (game.vm.limit) + view.prompt += `, no more than ${game.vm.limit} per state` + view.prompt += '.' // if (has_opponent_cubes) // event_prompt(`Add a ${COLOR_NAMES[game.vm.cube_color]} cube or remove an Opponent's cube.`) } @@ -2546,7 +2550,14 @@ function goto_vm_remove_cubes() { states.vm_remove_cubes = { inactive: "remove a cube.", prompt() { - event_prompt(`Remove a ${COLOR_NAMES[game.vm.cubes]} cube.`) + if (game.vm.all) { + event_prompt(`Remove all ${COLOR_NAMES[game.vm.cubes]} cube.`) + } else { + event_prompt(`Remove ${game.vm.count} ${COLOR_NAMES[game.vm.cubes]} cube`) + if (game.vm.limit) + view.prompt += `, no more than ${game.vm.limit} per state` + view.prompt += '.' + } for (let s of game.vm.us_states) { if ((game.vm.cubes === PURPLE || game.vm.cubes === PURPLE_OR_YELLOW) && purple_cubes(s)) -- cgit v1.2.3