Write "last night" and "yesterday" in the journal for a day that starts at dawn
The journal says something happened "today" at one in the morning although the player has already slept, or "yesterday" for something a few hours old. Here is how to word elapsed time from the number of ticks so that the night belongs to the day it began in.
Why this works
People feel a day as one stretch of being awake, so the night belongs to the day that came before the sleep. Counting days from the morning, not from the calendar's midnight, makes the words match what the player remembers.
When not to use it
Skip it when the game never lets the player sleep or when time is shown as a clock and a date. Then plain dates or hours are clearer than soft words. Also skip it when many time zones are involved, as for several players.
In the full entry
- What to build, step by step
- Starting values and the reason for each
- 3 common mistakes and the fix
- A diagram of every state
- 19 lines of example code with 4 checks that pass
- How your AI shows you that it works
Say this to your AI
Use the Spielerando entry "Write "last night" and "yesterday" in the journal for a day that starts at dawn" (read_entry journal-time-words-when-the-day-starts-at-dawn) in my game. Build it step by step, and show me how you checked that it works.Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP