A faster refill for subscribers should not hand out a free heart or erase waiting
When a player gets a quicker refill, the half-finished wait for the next heart has to be carried over sensibly. Done carelessly, they either get a heart out of nowhere or lose the time they already waited. Here is the bookkeeping that avoids both.
Why this works
Time waited is a share of a whole, not a point on a clock. Storing how far along the wait is, instead of when it ends, means the share earned stays the same when the length of the wait changes, so no one gains or loses anything.
When not to use it
Skip it when the speed never changes during a wait, or when a fresh start at the new speed is acceptable, such as a plan that only takes effect after the next heart. Then keep the simpler end time.
In the full entry
- What to build, step by step
- Starting values and the reason for each
- 3 common mistakes and the fix
- 19 lines of example code with 3 checks that pass
- How your AI shows you that it works
Say this to your AI
Use the Spielerando entry "A faster refill for subscribers should not hand out a free heart or erase waiting" (read_entry puzzle-speed-change-keeps-partial-heart) 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