summaryrefslogtreecommitdiff
path: root/platformer/src/level.h
diff options
context:
space:
mode:
authorSchark <jordan@schark.online>2026-09-29 22:28:37 -0400
committerSchark <jordan@schark.online>2026-09-29 22:28:37 -0400
commitfdc8c951fc72d9dc4c8faa58a21b2b9de0599698 (patch)
treeedd9934a43429508acb9ec37da71eb172dc788e9 /platformer/src/level.h
parentadb6a882870464490a8026aed1f66b21b0e72477 (diff)
downloadgamedev-fdc8c951fc72d9dc4c8faa58a21b2b9de0599698.tar.gz
gamedev-fdc8c951fc72d9dc4c8faa58a21b2b9de0599698.zip
Implemented no-panning zones
Diffstat (limited to 'platformer/src/level.h')
-rw-r--r--platformer/src/level.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/platformer/src/level.h b/platformer/src/level.h
index ca706a1..b66414e 100644
--- a/platformer/src/level.h
+++ b/platformer/src/level.h
@@ -33,9 +33,13 @@
* box is where the box sits at offset 0.
*
* #define LEVEL_MAX_BOXES 256
+ * #define LEVEL_MAX_ZONES 16
* int level_build(LevelBox *out, int capacity);
* Fills out[] with every box in the level and returns how many.
* The same seeds always build the same level.
+ * int level_build_zones(Zone *out, int capacity);
+ * Fills out[] with the level's zones (non-solid regions such as
+ * locked-pan zones; see world.h) and returns how many.
* Vec3 level_motion_offset(BoxMotion m, float time);
* How far a moving box is from its built position at `time`.
* Vec3 level_spawn_point(void);
@@ -74,8 +78,10 @@ typedef struct LevelBox {
} LevelBox;
#define LEVEL_MAX_BOXES 256
+#define LEVEL_MAX_ZONES 16
int level_build(LevelBox *out, int capacity);
+int level_build_zones(Zone *out, int capacity);
Vec3 level_motion_offset(BoxMotion m, float time);
Vec3 level_spawn_point(void);