summaryrefslogtreecommitdiff
path: root/state_mainstate/include
diff options
context:
space:
mode:
author0undefined <oscar@nelin.dk>2025-03-27 15:11:20 +0000
committer0undefined <oscar@nelin.dk>2025-04-09 09:42:38 +0000
commitccc93530fe9f1578e2bf98071631db3459ba6bb0 (patch)
tree8b9e7ed55dee221c40df971df6371da90bc58c85 /state_mainstate/include
parent0651aeb8f2c5d02a5dc23ac0254721c2a9609161 (diff)
Add some worldgen
Diffstat (limited to 'state_mainstate/include')
-rw-r--r--state_mainstate/include/states/mainstate.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/state_mainstate/include/states/mainstate.h b/state_mainstate/include/states/mainstate.h
index 4421c4b..f29c7b9 100644
--- a/state_mainstate/include/states/mainstate.h
+++ b/state_mainstate/include/states/mainstate.h
@@ -13,11 +13,17 @@
#include <cglm/cglm.h>
+#define WORLD_HEIGHT 32
+#define WORLD_WIDTH 32
+#define WORLD_LENGTH 32
+#define WORLD_SIZE (WORLD_HEIGHT * WORLD_LENGTH * WORLD_WIDTH)
+
typedef struct mainstate_state {
/* Resources */
Shader shaders[10];
RenderBatch terrain;
RenderObject objects[10];
+ u8 world[WORLD_HEIGHT * WORLD_WIDTH * WORLD_LENGTH];
i_ctx input_ctx;
binding_t input_bindings[10];
vec3 cam_dir;