forked from kdx/jtmm2-old
65ceff3971
- [input] Completely rewrote most of the code - [input/camera] Renamed `*_draw` functions used in debug section to `*_draw_debug` - [main/input] Now use `_Bool` instead of `int` when appropriate - [input] Added function `input_is_up` - [player] Added function `player_draw_debug` - [vec] Use `int` instead of `float`, new macro `VEC_PRECISION` - [main/camera/player/vec] Updated vector related code to work with the new system
20 lines
424 B
C
20 lines
424 B
C
#ifndef _DEF_PLAYER
|
|
#define _DEF_PLAYER
|
|
|
|
#include "vec.h"
|
|
#include "camera.h"
|
|
#include "input.h"
|
|
|
|
typedef struct Player
|
|
{
|
|
Vec pos;
|
|
Vec hbox; /* the bottom right corner of the player's hitbox */
|
|
Vec origin; /* the origin of the player (offset) */
|
|
} Player;
|
|
|
|
void player_step(Player *player, Input *input);
|
|
void player_draw(Player *player, Camera *camera);
|
|
void player_draw_debug(Player *player);
|
|
|
|
#endif /* _DEF_PLAYER */
|