Adds window icon
- Fixes bug where you could move when falling.
This commit is contained in:
parent
6af8d9dd8f
commit
9a610d5f88
Binary file not shown.
After Width: | Height: | Size: 640 B |
|
@ -51,6 +51,7 @@
|
||||||
#include "input.h"
|
#include "input.h"
|
||||||
#include "screen.h"
|
#include "screen.h"
|
||||||
#include "hiscore.h"
|
#include "hiscore.h"
|
||||||
|
#include "io_util.h"
|
||||||
|
|
||||||
typedef enum Turn_t {
|
typedef enum Turn_t {
|
||||||
PLAYER,
|
PLAYER,
|
||||||
|
@ -143,6 +144,9 @@ bool initSDL(void)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Set the window icon
|
||||||
|
SDL_SetWindowIcon(gWindow, IMG_Load_RW(io_load_rwops("Extras/icon.png"), true));
|
||||||
|
|
||||||
gRenderer = SDL_CreateRenderer(gWindow, -1,
|
gRenderer = SDL_CreateRenderer(gWindow, -1,
|
||||||
SDL_RENDERER_ACCELERATED | SDL_RENDERER_TARGETTEXTURE);
|
SDL_RENDERER_ACCELERATED | SDL_RENDERER_TARGETTEXTURE);
|
||||||
if (gRenderer == NULL)
|
if (gRenderer == NULL)
|
||||||
|
|
|
@ -576,7 +576,7 @@ void player_update(UpdateData *data)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
check_skill_activation(data);
|
check_skill_activation(data);
|
||||||
if (!check_skill_trigger(data))
|
if (player->state != FALLING && !check_skill_trigger(data))
|
||||||
handle_next_move(data);
|
handle_next_move(data);
|
||||||
|
|
||||||
if (player->state == FALLING && player->stats.hp > 0) {
|
if (player->state == FALLING && player->stats.hp > 0) {
|
||||||
|
|
|
@ -434,7 +434,7 @@ skill_create(enum SkillType t)
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG_SKILLS
|
||||||
skill->levelcap = 1;
|
skill->levelcap = 1;
|
||||||
#endif
|
#endif
|
||||||
return skill;
|
return skill;
|
||||||
|
|
Loading…
Reference in New Issue