aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortslil clingman <>2021-09-12 12:57:54 -0400
committertslil clingman <>2021-09-12 12:57:54 -0400
commitbb051192d7d5de2504c29508d1d56f21de1e0368 (patch)
tree14aa6d1efc36a44a47f4b802db237de22b40c2a0
parent027b973d7550ac2e72e5de1e2155e26b35f16353 (diff)
Rendering bug
-rw-r--r--src/raycast.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/raycast.zig b/src/raycast.zig
index 2b55f49..77a9ef0 100644
--- a/src/raycast.zig
+++ b/src/raycast.zig
@@ -77,7 +77,7 @@ pub fn Player(PlaneWidth: f32, PlaneHeight: f32) type {
vel_y: f32 = 0,
acc_x: f32 = 0,
acc_y: f32 = 0,
- height: f32 = 1, // TODO
+ height: f32 = 2.0 * (1.8 / 2.5), // TODO
z_buffer: std.BoundedArray(f32, PlanePixels),
// standing still at the given location, looking in direction ang
@@ -380,7 +380,7 @@ pub fn Player(PlaneWidth: f32, PlaneHeight: f32) type {
self.z_buffer.set(index, row_dist);
}
}
- highest_point = top;
+ highest_point = next_top;
}
}
}