In development

Duga

I moved save and replay writes off the game thread. In a full campaign benchmark, frame stalls over 100 ms fell from 109 to zero.

Fixing the pauses between moves

Duga is a puzzle game played from the helm of a survey ferry. Calling a color sends a wave through the matching stones on your chart. The stones you claim determine how far the ferry travels.

Some turns and crossings paused for more than a second. Timing individual operations showed that 108 of the 109 frame intervals over 100 ms were dominated by campaign saves or personal-best replay writes on the game thread. The longest campaign save took about 1.5 seconds.

Duga now queues both kinds of writes on a background worker. A newer ledger snapshot can replace one still waiting to be written, and each file is replaced atomically so readers see a complete version. Ghost review can use a newly earned replay while its write is queued. On normal shutdown, the game waits for the worker to finish.

The same campaign, before and after

MeasurementBeforeAfter
Frame intervals over 100 ms1090
Frame intervals over 50 ms1701
Longest frame interval1.52 sAbout 100 ms
99th-percentile frame interval10.0 ms8.3 ms
Average frame output119 FPS144 FPS
Before the fix, frame intervals above 100 ms recur throughout the campaign. After the fix, nearly all intervals cluster near 7 ms, with one opening interval reaching about 100 ms.
Each point is the time between two consecutive frame presents. Orange marks intervals above 100 ms. Both panels use the same scale.

The automated replay cleared all 61 charts at par and let all 60 crossings play. Both runs used the same moves and scored the same points. I measured intervals between application presents in an instrumented Windows release build at 1920 × 1080 on a Ryzen 9 5900 and RTX 3080, with Vulkan and VSync enabled. Both runs kept telemetry in memory until the voyage ended so logging would stay off the frame path. The fixed run wrote all 61 replay files.

Read the earlier update on Duga’s chart design and release preparation.

How it's made

Built in Kalix Engine.

Sourced assets

None yet.

Dev log

Nothing posted yet.