summaryrefslogtreecommitdiff
path: root/kon/konplatformer.h
diff options
context:
space:
mode:
authorKonAki <konaki@anokonaki.org>2026-10-13 10:28:17 +0800
committerKonAki <konaki@anokonaki.org>2026-10-13 10:28:17 +0800
commitd3432fcc288a53dff9eb219c8857ca48c5981323 (patch)
treefba5cc730c91d2c674efe6d71dd20e9d6bf7d0d8 /kon/konplatformer.h
parenta2dc5ca4c659e2d0a9527cd0910bc76b65e6d09f (diff)
headers: extern C guards and C++ safe vector and rect constructors
Diffstat (limited to 'kon/konplatformer.h')
-rw-r--r--kon/konplatformer.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/kon/konplatformer.h b/kon/konplatformer.h
index 710f0e0..50e6006 100644
--- a/kon/konplatformer.h
+++ b/kon/konplatformer.h
@@ -29,6 +29,10 @@
#include "koncollide.h"
#include "kontile.h"
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/*** platformer ***/
/* a box that runs and jumps through a tilemap. the game sets moveX and jumpHeld every frame, calls kon_platformerUpdate and reads
@@ -64,4 +68,8 @@ int kon_platformerStep(kon_platformer_t *p, const kon_tilemap_t *map, const uint
/* takes the frame time and runs steps of 1/120 of a second, so the jump feels the same at any frame rate */
void kon_platformerUpdate(kon_platformer_t *p, const kon_tilemap_t *map, const uint8_t *solid, int solidCount, double dt);
+
+#ifdef __cplusplus
+}
+#endif
#endif