summaryrefslogtreecommitdiff
path: root/jouer.c
diff options
context:
space:
mode:
authorOlivier Gayot <duskcoder@gmail.com>2015-01-08 18:52:14 +0100
committerOlivier Gayot <duskcoder@gmail.com>2015-01-08 18:52:14 +0100
commitd75f0dfb7a040ff88c39e01fa639ff74300f11a2 (patch)
tree7ac20d9c89778c353e355731dd74bde59646aca1 /jouer.c
parentc6f994c51f29770be493ac3aaf76f71fccc4269f (diff)
blit the background only once (no need for a weird function)
Signed-off-by: Olivier Gayot <duskcoder@gmail.com>
Diffstat (limited to 'jouer.c')
-rw-r--r--jouer.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/jouer.c b/jouer.c
index 9081357..9cad17c 100644
--- a/jouer.c
+++ b/jouer.c
@@ -246,12 +246,7 @@ int Fjouer (SURFACES *surfaces, POSITIONS *positions, struct team_t *t1, struct
unsigned int gagne,perdu;
- if(surfaces->Pfondjeu!=NULL)
- {
- SDL_FreeSurface(surfaces->Pfondjeu);
- surfaces->Pfondjeu=NULL;
- }
- Fblitterfond(surfaces); // on blit le fond du jeu
+ SDL_BlitSurface(surfaces->background, NULL, surfaces->Pecran, NULL);
/* compute whether the allies or the enemies should begin */
playing_team = (rand() % 2) ? t1 : t2;