diff options
author | Tor Andersson <tor@ccxvii.net> | 2025-01-06 22:05:09 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2025-01-08 10:46:27 +0100 |
commit | aad5c0dfcec0e4eeefacb4bccce30e514d98b98c (patch) | |
tree | 63e9c70dc9262cf8cb14aab685a35ba3c88fb379 | |
parent | a5de4ca91a621eae2604d349d1852967a25aefee (diff) | |
download | 1989-dawn-of-freedom-aad5c0dfcec0e4eeefacb4bccce30e514d98b98c.tar.gz |
use mathematical minus in log
-rw-r--r-- | play.js | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -987,6 +987,10 @@ function sub_die(match) { return die[match] || match } +function sub_minus(match) { + return "\u2012" + match.substring(1) +} + function sub_icon(match) { return ICONS[match] || match } @@ -1051,6 +1055,7 @@ function on_log(text, ix) { text = text.replace(/V(\d+)/g, sub_power_card_value) text = text.replace(/%(\d+)/g, sub_space_name) text = text.replace(/D[1-6]/g, sub_die) + text = text.replace(/-\d/g, sub_minus) text = text.replace(/£[CDU][CU]\b/g, sub_icon) text = text.replace(/\.cT(\d+)/g, sub_icon) text = text.replace(/\.dT(\d+)/g, sub_icon) |