A RPG I'm messing with made in Raylib.
at main 20 lines 485 B view raw
1#include "../../include/player_state/fall.h" 2 3#include "../../include/player.h" 4#include "../../include/raylib.h" 5 6static void player_state_fall_update(PlayerState *state, Player *player) 7{ 8 // if (IsKeyPressed(KEY_RIGHT)) 9 // { 10 // state->update = player_state_transition_to_walk_right; 11 // } 12} 13 14void player_state_transition_to_fall(PlayerState *state, Player *player) 15{ 16 state->name = "Fall"; 17 state->update = player_state_fall_update; 18 19 player->speed = 0; 20}