diff options
-rw-r--r-- | play.js | 2 | ||||
-rw-r--r-- | rules.js | 8 |
2 files changed, 6 insertions, 4 deletions
@@ -1347,6 +1347,7 @@ function colorize(text) { text = text.replaceAll("\u2663", colorize_C) text = text.replaceAll("\u2665", colorize_H) text = text.replaceAll("\u2666", colorize_D) + text = text.replace(/-( ?[\d(])/g, "\u2212$1") return text } @@ -1709,6 +1710,7 @@ function on_log(text) { text = text.replace(/S(\d+)/g, sub_space) text = text.replace(/P(\d+)/g, sub_piece) text = text.replace(/C(\d+)/g, sub_political) + text = text.replace(/-( ?[\d(])/g, "\u2212$1") if (text.startsWith("@")) { p.className = "move_tip" @@ -1846,7 +1846,7 @@ function draw_tactical_cards() { } if (mod < 0) - log(`${power_name[game.power]} ${base} TC (\u2212${-mod} political).`) + log(`${power_name[game.power]} ${base} TC (-${-mod} political).`) else if (mod > 0) log(`${power_name[game.power]} ${base} TC (+${mod} political).`) else @@ -2244,10 +2244,10 @@ states.supply_suffer = { let s = game.pos[p] set_delete(game.supply.suffer, p) if (is_out_of_supply(p)) { - log(`>P${p} at S${s} (\u{2212}2)`) + log(`>P${p} at S${s} (-2)`) game.troops[p] -= 2 } else { - log(`>P${p} at S${s} (\u{2212}1)`) + log(`>P${p} at S${s} (-1)`) set_out_of_supply(p) game.troops[p] -= 1 } @@ -3802,7 +3802,7 @@ function signed_number(v) { if (v > 0) return "+" + v if (v < 0) - return "\u2212" + (-v) + return "-" + (-v) return "0" } |