Refactor literally everything

This commit is contained in:
2025-11-26 01:19:20 +01:00
parent d6a4b8c1fe
commit 9f2d1e4608
22 changed files with 2070 additions and 1034 deletions

23
src/voxel.zig Normal file
View File

@@ -0,0 +1,23 @@
pub const Orientation = enum(u4) {
negative_x,
positive_x,
negative_y,
positive_y,
negative_z,
positive_z,
};
// ┌────────────────── x
// │ ┌────────────── y
// │ │ ┌───────── z
// │ │ │ ┌───── orientation
// │ │ │ │ ┌ material
// ┌┴─┐┌┴─┐ ┌┴─┐┌┴─┐ ┌┴──────────────┐
// 10987654 32109876 54321098 76543210
pub const Wall = packed struct(u32) {
material: u16,
orientation: Orientation,
z: u4,
y: u4,
x: u4,
};