diff options
| author | Schark <jordan@schark.online> | 2026-09-29 21:02:22 -0400 |
|---|---|---|
| committer | Schark <jordan@schark.online> | 2026-09-29 21:02:22 -0400 |
| commit | 21404c26d3907cefa524878fb031e7a2022fb3d7 (patch) | |
| tree | 38b2bb26d6d0c05447213edca4911ccc3887f474 /platformer/src/config.h | |
| parent | 5f04f3ae87fb307e055d39e81f7c0c841e8a9af8 (diff) | |
| download | gamedev-21404c26d3907cefa524878fb031e7a2022fb3d7.tar.gz gamedev-21404c26d3907cefa524878fb031e7a2022fb3d7.zip | |
Game world test with updated movement
Diffstat (limited to '')
| -rw-r--r-- | platformer/src/config.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/platformer/src/config.h b/platformer/src/config.h index 23d85ec..35feb4c 100644 --- a/platformer/src/config.h +++ b/platformer/src/config.h @@ -79,6 +79,15 @@ * PLAYER_RETREAT_JUMP_SPEED 4.0f m/s launched toward the stick, and the top * speed until that jump lands * + * Player: wall hang + * PLAYER_WALL_HANG_ANGLE_DEG 45.0f degrees; how far off head-on the player may + * hit a hangable wall and still hang + * PLAYER_WALL_HANG_DURATION 0.5f s the hang lasts before the player lets go + * PLAYER_WALL_SLIDE_ACCEL 3.0f m/s^2 how slowly the hang slides downward + * PLAYER_WALL_SLIDE_MAX_SPEED 2.0f m/s fastest slide down the wall + * PLAYER_WALL_JUMP_EARLY_TIME 0.1f s into the hang that a wall jump is still + * the high, second-jump-like one + * * Physics * GRAVITY 40.0f m/s^2 (stronger than real 9.8 on purpose: * platformers feel floaty with real gravity) @@ -128,6 +137,9 @@ * GRID_MAJOR_EVERY 10 every Nth line drawn brighter * WORLD_SEED 20260924u seed for the platform layout; change it * for a different (but repeatable) level + * CLIFF_COURSE_SEED 20260930u seed for the cliff course's generated + * platforms (see level.c); change it for + * a different climb * WORLD_PLATFORM_COUNT 40 how many platforms to scatter * WORLD_PLATFORM_AREA 25.0f m; platforms land within this distance of * spawn in x and z (smaller = denser) @@ -191,6 +203,13 @@ #define PLAYER_RETREAT_JUMP_VELOCITY 19.66f /* m/s upward for the jump out of a skid; tuned to 2x the first jump's height (4.67 m at 60 Hz) */ #define PLAYER_RETREAT_JUMP_SPEED 4.0f /* m/s launched toward the stick, and the top speed until landing; higher = travels farther */ +/* ---- Player: wall hang -------------------------------------------------- */ +#define PLAYER_WALL_HANG_ANGLE_DEG 45.0f /* degrees off head-on that still grabs a hangable wall; higher = grabs from shallower angles */ +#define PLAYER_WALL_HANG_DURATION 0.5f /* s clinging before letting go and falling normally; higher = longer linger */ +#define PLAYER_WALL_SLIDE_ACCEL 3.0f /* m/s^2 the cling slides down the wall; lower = stickier */ +#define PLAYER_WALL_SLIDE_MAX_SPEED 2.0f /* m/s fastest slide down the wall while clinging */ +#define PLAYER_WALL_JUMP_EARLY_TIME 0.1f /* s into the hang that A still gives the high (second-jump-like) wall jump; later = normal-jump-like */ + /* ---- Physics ----------------------------------------------------------- */ #define GRAVITY 40.0f /* m/s^2; stronger than real 9.8 on purpose, real gravity feels floaty */ #define TERMINAL_VELOCITY 50.0f /* m/s max fall speed; lower = long falls feel more controlled */ @@ -229,6 +248,7 @@ #define GRID_SPACING 1.0f /* m between grid lines; the grid is how you read speed */ #define GRID_MAJOR_EVERY 10 /* every Nth line drawn brighter, for reading distances */ #define WORLD_SEED 20260924u /* platform layout seed; change for a different (repeatable) level */ +#define CLIFF_COURSE_SEED 20260930u /* cliff course layout seed (level.c); change for a different (repeatable) climb */ #define WORLD_PLATFORM_COUNT 40 /* platforms scattered around spawn; more = busier level */ #define WORLD_PLATFORM_AREA 25.0f /* m from spawn (x and z) platforms can land; smaller = denser */ |
