mirror of
https://git.planet-casio.com/Slyvtt/Collab_RPG.git
synced 2024-12-28 04:23:42 +01:00
Optimisation du rendu
This commit is contained in:
parent
5eb1d18ea7
commit
1daa58723c
2 changed files with 5 additions and 6 deletions
|
@ -7,6 +7,7 @@
|
|||
#include <gint/cpu.h>
|
||||
#include <gint/display.h>
|
||||
#include <gint/keyboard.h>
|
||||
#include <libprof.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
|
@ -78,8 +79,6 @@ void game_render_indicator(Game *game) {
|
|||
}
|
||||
|
||||
void game_draw(Game *game) {
|
||||
/* Draw everything. */
|
||||
dclear(C_WHITE);
|
||||
map_render_by_layer(game, BACKGROUND);
|
||||
npc_draw(game);
|
||||
player_draw(game);
|
||||
|
@ -89,6 +88,7 @@ void game_draw(Game *game) {
|
|||
dprint(8, 16, C_BLACK, "Mana: %d", game->mana);
|
||||
}
|
||||
|
||||
|
||||
/* Key management */
|
||||
|
||||
void game_get_inputs(Game *game) {
|
||||
|
|
|
@ -120,12 +120,11 @@ int main(void) {
|
|||
#endif
|
||||
|
||||
do {
|
||||
/* clear screen */
|
||||
dclear(C_WHITE);
|
||||
|
||||
/* render the map */
|
||||
/*clears & renders everything */
|
||||
game_draw(&game);
|
||||
|
||||
dprint(0,30,0,"draw time : %d", game.frame_duration);
|
||||
|
||||
#if DEBUGMODE && GINT_RENDER_RGB
|
||||
if(game.debug_map) {
|
||||
dfont(NULL);
|
||||
|
|
Loading…
Reference in a new issue