From a6ea23b14c512e57b6d28150b5766147cd354319 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Wed, 2 Nov 2022 16:30:54 +0100 Subject: Mark blocks as moved after first step to mask tracking movement speeds. --- play.js | 2 +- rules.js | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/play.js b/play.js index ae68ea2..a707225 100644 --- a/play.js +++ b/play.js @@ -586,7 +586,7 @@ function update_map() { let info = BLOCKS[b] let element = ui.blocks[b] let town = view.location[b] - let moved = set_has(view.moved, b) ? " moved" : "" + let moved = (set_has(view.moved, b) && b !== view.who) ? " moved" : "" if (town === DEAD) { moved = " moved" } diff --git a/rules.js b/rules.js index cf46b40..89fb28c 100644 --- a/rules.js +++ b/rules.js @@ -1732,6 +1732,7 @@ states.move_phase_to = { view.prompt += " by road." }, town: function (to) { + set_add(game.moved, game.who) let from = game.location[game.who] if (to === SEA) { log_move_start(from) @@ -1827,6 +1828,7 @@ states.group_move_to = { } }, town: function (to) { + set_add(game.moved, game.who) let from = game.location[game.who] if (to === from) { end_move() @@ -1849,8 +1851,6 @@ states.group_move_to = { } function end_move() { - if (game.distance > 0) - set_add(game.moved, game.who) log_move_end() game.who = NOBODY game.distance = 0 @@ -2037,6 +2037,7 @@ states.muster_move_1 = { }, town: function (to) { let from = game.location[game.who] + set_add(game.moved, game.who) log_move_start(from) log_move_continue(to) move_block(game.who, from, to) @@ -2116,7 +2117,6 @@ states.muster_move_3 = { function end_muster_move() { log_move_end() - set_add(game.moved, game.who) game.who = NOBODY game.state = 'muster_who' } -- cgit v1.2.3