From e2f7ea90ff10d3cd575b58c30a7f5d4433db7e7d Mon Sep 17 00:00:00 2001 From: tslil clingman <> Date: Sun, 17 Oct 2021 21:26:15 -0400 Subject: Additional bug fix Essentially highest_drawn should be monotonic between squares, the only time we should allow ourselves to draw below this is in the special case of drawing a vertical portion over the horizontal portion of a previous layer in the same square. --- src/main.zig | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/main.zig') diff --git a/src/main.zig b/src/main.zig index 2ee6bc6..47f89a7 100644 --- a/src/main.zig +++ b/src/main.zig @@ -53,10 +53,10 @@ pub fn main() !void { while (y < 10) : (y += 1) { // HACK const vert_coords0 = [_][2]f32{ - .{ 0.00, 0.00 }, - .{ 1.00, 0.00 }, - .{ 1.00, 1.00 }, - .{ 0.00, 1.00 }, + .{ 0.10, 0.10 }, + .{ 0.90, 0.10 }, + .{ 0.90, 0.90 }, + .{ 0.10, 0.90 }, }; var verts = try std.BoundedArray([2]f32, level.Layer.MAX_VERTS).fromSlice(vert_coords0[0..]); var layer = level.Layer{ .height = 0.5, .vertices = verts }; -- cgit v1.3.1