World Time Generator 3.0
World Time Generator (WTG) is a scripting system for AI Dungeon that automatically tracks the passage of time throughout your adventure. As the story unfolds, WTG keeps a running clock and calendar and displays the current date and time in your storycards as well as generating a placeholder story card for anyone or anything new you might discover. WTG is designed to be installed once by a scenario author and then be mostly invisible to players. You set a starting date, play your adventure, and WTG handles the rest. A handful of commands let you jump forward in time, skip ahead to morning after sleeping, or jump to a specific date or time when the story calls for it. Features: Automatic time tracking — Time advances roughly 1 minute per ~300 characters of story text (configurable) Persistent date and time display — A "Current Date and Time" storycard is kept up to date every turn Day of week — WTG calculates the correct day of the week for any date Time phases — The time of day is labeled (Predawn, Dawn, Morning, Late Morning, Midday, Afternoon, Evening, Night, After Midnight); fully customizable via a "WTG Time Phases" storycard Full era support — AD/CE and BC/BCE calendars with correct arithmetic across era boundaries Adventure rewind and retry — WTG detects when you erase, retry, or rewind your story and adjusts time forward or backward accordingly; time doesn't creep forward on repeated retry, time returns to your previous state if your rewind or undo Automatic entity placeholder cards — When enabled, the AI marks new characters, creatures, locations, or any other notable entity and WTG catches these and creates a placeholder story card for each one. You can then use AI Dungeon's built-in card generation to flesh each card out whenever you want. AI-driven time commands — When enabled, the AI can advance time naturally as part of the narrative Localization — Display labels (date format, phase names, etc.) can be translated via a "WTG: Localization" storycard Cached/Optimized Context support — WTG can be configured to place the current time/day and its dynamic time instructions either invisibly in Author's Note (incompatible with Cached/Optimized Context models), visibly in the Author's Note (compatible) or invisibly after the player action (compatible) allowing flexible support for all models. Highly Configurable — designed to work out of the box but also to be tuneable to match your play style or game genre Commands: [setStartTime mm/dd/year time AD] - Set starting date/era/time (omit time or era to keep existing; preserves elapsed time) [restartWTG] - Reset elapsed time back to zero (use after setStartTime if you want a clean restart) [advance N minutes|hours|days|months|years] - Advance time [adv N mi|h|d|mo|y] - Advance time [goTo date|time|both] - Advance to a specific date/time [goBack date|time|both] - Rewind to a specific date/time (must still be after the initial start time) [sleep] - Sleep to next morning [sleepUntil date|time|both] - Sleep until a specific date/time [reset] - Reset to most recent mention in history Examples: `[adv 3 days]` - Moves the date forward 3 days. `[goto Tuesday]` - Moves the date forward to the next Tuesday. `[goto afternoon]` - Moves the clock to the next Time Phase named "afternoon" (afternoon is one of the default phases, but these can be configured in game). Full instructions can be found: https://github.com/helpfulduckie/World-Time-Generator-3.0/tree/main
