Better friction, kinda.

This commit is contained in:
KikooDX 2020-12-24 12:20:12 +01:00
parent a5c414dd4c
commit 8a4bc582a9
3 changed files with 3 additions and 4 deletions

1
.gitignore vendored
View File

@ -6,3 +6,4 @@ JTMM2.g*a
levels/0.jtmm2
src/gen_levels.c
*.sublime-*
JTMM2_preview_*.zip

View File

@ -1,8 +1,6 @@
#ifndef _DEF_PLAYER
#define _DEF_PLAYER
#include <stdbool.h>
#include "vec.h"
typedef struct Player {

View File

@ -10,8 +10,8 @@
/* TODO: Determine FRICTION and ACCELERATION from UPS. */
#define MAX_SPD (64 * PXS)
#define FRICTION 0.9
#define ACCELERATION (MAX_SPD * (1 - FRICTION))
#define FRICTION (0.95)
#define ACCELERATION (int)(MAX_SPD * (1 - FRICTION))
#define GRAVITY PXS
#define JUMP_SPD (-128 * PXS)
#define GRACE_UNITS (int)(UPS / 5)