diff options
Diffstat (limited to 'core/Core.zig')
| -rw-r--r-- | core/Core.zig | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/core/Core.zig b/core/Core.zig index a18e891c..da1dc4b8 100644 --- a/core/Core.zig +++ b/core/Core.zig @@ -2075,7 +2075,7 @@ pub fn nextWake(p: *const Pardes) ?u64 { }; // Del's question goes up at the end of its delay: a frame then, and // none after (stepped time has reached it). - for (p.panes) |slot| if (slot) |pane| if (pane.prompt == .del_side and pane.question_due_ns > p.clock.stepped_ns) { + for (p.panes) |slot| if (slot) |pane| if (pane.prompt == .del_side and pane.question_due_ns > p.clock.stepped_ns and pane.question_due_ns != Pane.question_asked) { const wait = @max(1, (pane.question_due_ns - p.clock.stepped_ns + frame_ns - 1) / frame_ns); frames = if (frames) |soonest| @min(soonest, wait) else wait; }; @@ -2116,6 +2116,10 @@ fn advanceInner(p: *Pardes, now_ns: u64) void { p.clock.started = true; p.clock.now_ns = now_ns; if (!started) p.clock.stepped_ns = now_ns; + // Del's question asked since the last advance: its delay from now. + for (p.panes) |slot| if (slot) |pane| if (pane.question_due_ns == Pane.question_asked) { + pane.question_due_ns = now_ns + config.del_question_delay_ns; + }; const frame = frame_ns; var moving: u32 = 0; // The session's ticks are the recording session's: a picture still |
