summaryrefslogtreecommitdiff
path: root/anim/src/calls.zig
diff options
context:
space:
mode:
Diffstat (limited to 'anim/src/calls.zig')
-rw-r--r--anim/src/calls.zig6
1 files changed, 4 insertions, 2 deletions
diff --git a/anim/src/calls.zig b/anim/src/calls.zig
index 9c3df04..50e83b2 100644
--- a/anim/src/calls.zig
+++ b/anim/src/calls.zig
@@ -134,8 +134,10 @@ pub const Tree = struct {
} else u.faded(amount).label(.mono, size, cell, .center, words, t.primary);
}
if (active) continue;
- // Done: what it returned, on its shoulder; struck as it lands.
- const badge: Rect = .{ .x = c[0] + m.badge_at[0], .y = c[1] - m.badge_at[1], .w = m.badge, .h = m.badge };
+ // Done: what it returned, on its outer shoulder (a left child's
+ // left, off its parent's disc); struck as it lands.
+ const left_child = if (n.parent) |p| n.x < nodes[p].x else false;
+ const badge: Rect = .{ .x = if (left_child) c[0] - m.badge_at[0] - m.badge else c[0] + m.badge_at[0], .y = c[1] - m.badge_at[1], .w = m.badge, .h = m.badge };
const heat: ui.Heat = if (n.call.exit.? > now.stops[1]) now.heat(0, null, since - time.badge_after) else .none;
const ink = u.cellWritten(badge, heat, theme.color.page);
// Framed, as every result is, but while the strike's paper is on it.