From 10d96d5eb8a0564025f8eb683f926cae7d3cd5f0 Mon Sep 17 00:00:00 2001 From: teisuru <31881306+teisuru@users.noreply.github.com> Date: Sat, 3 Jun 2023 22:50:14 +0200 Subject: Plantagenet seasons and Plan --- play.js | 29 +++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) (limited to 'play.js') diff --git a/play.js b/play.js index d63fb6e..7250f78 100644 --- a/play.js +++ b/play.js @@ -209,6 +209,28 @@ const NOWHERE = -1 const CALENDAR = 100 +const SUMMER = 0 +const SPRING = 1 +const WINTER = 2 + +const SEASONS = [ + WINTER, + SPRING, + SUMMER, + SPRING, + WINTER, + WINTER, + SPRING, + SUMMER, + SPRING, + WINTER, + WINTER, + SPRING, + SUMMER, + SPRING, + WINTER, + null +] // === ACTIONS === function is_action(action, arg) { @@ -294,10 +316,9 @@ function current_season() { function max_plan_length() { switch (current_season()) { - case SUMMER: return 6 - case EARLY_WINTER: return 4 - case LATE_WINTER: return 4 - case RASPUTITSA: return 5 + case SUMMER: return 7 + case WINTER: return 4 + case SPRING: return 6 } } -- cgit v1.2.3