Summary
The u8 inv_set_busy_tick phase range 1..255 is incommensurate with the
27-tick / 54-raw comet period in text_wave.zig (SPEED=2, STEPS=3 on N=18).
At the 255→1 wrap (~every 25.6 s at 10 Hz), the localized comet head
jumps ~7 glyphs in a single 100 ms frame — from scalar index 8 back to ~0.7.
The old full-ring cyclicDistance gradient (before #671) hid the same skip
as a phase hitch. The localized sprite makes it visible. The test added in
PR #671 pins the exact values (text_wave.test.zig).
Not a blocker for #671 — just a known artifact of the u8 phase width.
Possible approaches
- Wider phase — use a u16 or u32 tick counter so the comet has more
steps before wrapping (e.g. wrap at a multiple of N*STEPS).
- Wrap remap — when the host wraps 255→1, remap the incoming phase
to stay continuous (e.g. phase = wrapCount * 255 + tick).
- Accept the hitch — it is one frame every 25.6 s and may not bother
operators on tool-using turns that rarely exceed that duration.
Ref
Summary
The u8
inv_set_busy_tickphase range 1..255 is incommensurate with the27-tick / 54-raw comet period in
text_wave.zig(SPEED=2,STEPS=3on N=18).At the 255→1 wrap (~every 25.6 s at 10 Hz), the localized comet head
jumps ~7 glyphs in a single 100 ms frame — from scalar index 8 back to ~0.7.
The old full-ring
cyclicDistancegradient (before #671) hid the same skipas a phase hitch. The localized sprite makes it visible. The test added in
PR #671 pins the exact values (
text_wave.test.zig).Not a blocker for #671 — just a known artifact of the u8 phase width.
Possible approaches
steps before wrapping (e.g. wrap at a multiple of
N*STEPS).to stay continuous (e.g.
phase = wrapCount * 255 + tick).operators on tool-using turns that rarely exceed that duration.
Ref
native/harness/src/text_wave.zigheadPositionnative/harness/src/bridge.ziginv_set_busy_tick