A queued, timed pop-up notification - an achievement unlock, a level-up banner, a "quest
complete" toast. The same pop-in/hold/fade-out shape FloatingText already generalizes
for a damage number, but queued rather than fire-and-forget: only one toast is ever shown
at a time, and a second one landing mid-animation waits its turn instead of overlapping.
show takes a Container the caller builds and owns (an icon, a label, a whole banner
layout) - this owns only the timing, never the content's own shape. Driven directly by
update(dt) with a plain phase/elapsed timer, the same shape FloatingText already uses,
rather than chained tweens: a single frame boundary between phases keeps the whole
sequence exactly reproducible one update call at a time, which a test can drive without
waiting on any promise microtask to settle.
A queued, timed pop-up notification - an achievement unlock, a level-up banner, a "quest complete" toast. The same pop-in/hold/fade-out shape
FloatingTextalready generalizes for a damage number, but queued rather than fire-and-forget: only one toast is ever shown at a time, and a second one landing mid-animation waits its turn instead of overlapping.showtakes aContainerthe caller builds and owns (an icon, a label, a whole banner layout) - this owns only the timing, never the content's own shape. Driven directly byupdate(dt)with a plain phase/elapsed timer, the same shapeFloatingTextalready uses, rather than chained tweens: a single frame boundary between phases keeps the whole sequence exactly reproducible oneupdatecall at a time, which a test can drive without waiting on any promise microtask to settle.Example