Commit 6deafb6c9dd769b9e6e392e296b3fce7dae2b72b
1 parent
baf9b81f
.
Showing
1 changed file
with
0 additions
and
96 deletions
Show diff stats
test.c deleted
... | ... | @@ -1,96 +0,0 @@ |
1 | -#include <stdio.h> | |
2 | -#include <SDL/SDL.h> | |
3 | -#include <SDL/SDL_ttf.h> | |
4 | -#include "libgraph.h" | |
5 | -#include "test.h" | |
6 | -#include <stdbool.h> | |
7 | -#include <stdlib.h> | |
8 | - | |
9 | -#define MAX_LUTINS 16 | |
10 | -#define BITS_PAR_PIXEL 32 | |
11 | -#define TAILLE_POLICE 20 | |
12 | - | |
13 | - | |
14 | - | |
15 | -liste_entite * ajout_en_tete(liste_entite premiere_entite,struct entite * une_entite ) | |
16 | -{ | |
17 | - liste_entite * nouvelleentite = (liste_entite * )malloc(sizeof(liste_entite)); | |
18 | - | |
19 | - if(nouvelleentite == NULL) | |
20 | - { | |
21 | - return NULL; | |
22 | - } | |
23 | - | |
24 | - nouvelleentite->premiere_entite = une_entite; | |
25 | - return nouvelleentite; | |
26 | -} | |
27 | - | |
28 | - | |
29 | -liste_entite * ajout_apres(liste_entite * entite, struct entite une_entite) | |
30 | -{ | |
31 | -// a terminer | |
32 | - | |
33 | - | |
34 | - | |
35 | - | |
36 | - return NULL; | |
37 | -} | |
38 | - | |
39 | - | |
40 | - | |
41 | -/*liste_entite * supression_entete(liste_entite * une_entite) | |
42 | - | |
43 | -{ if(une_entite == NULL) return NULL; | |
44 | - liste_entite * current_entite = une_entite->premiere_entite; | |
45 | - free(une_entite); | |
46 | - return current_entite; | |
47 | -}*/ | |
48 | - | |
49 | - | |
50 | - | |
51 | - | |
52 | - | |
53 | - | |
54 | - | |
55 | - | |
56 | -/*void initiliserlejeu(void) | |
57 | -{ creerSurface(800,600,"space invaders"); | |
58 | - | |
59 | - | |
60 | - | |
61 | - | |
62 | - | |
63 | -}*/ | |
64 | - | |
65 | -int main() | |
66 | - | |
67 | -{ | |
68 | - | |
69 | - if (creerSurface(800, 600, "Space Invaders")) { | |
70 | - int monsterSprite = chargerLutin("invader_monstre1_1.bmp", COULEUR_ROUGE); | |
71 | - if (monsterSprite != -1) { | |
72 | - afficherLutin(monsterSprite, 100, 100); | |
73 | - majSurface(); | |
74 | - } | |
75 | - | |
76 | - attendreEvenement(); | |
77 | - | |
78 | - | |
79 | - rectanglePlein(0, 0, 800, 600, COULEUR_NOIR); | |
80 | - majSurface(); | |
81 | - | |
82 | - | |
83 | - int anotherSprite = chargerLutin("invader_monstre1_1.bmp", COULEUR_BLEU); | |
84 | - if (anotherSprite != -1) { | |
85 | - afficherLutin(anotherSprite, 200, 100); | |
86 | - majSurface(); | |
87 | - } | |
88 | - | |
89 | - attendreEvenement(); | |
90 | - | |
91 | - | |
92 | -} | |
93 | -fermerSurface(); | |
94 | -} | |
95 | - | |
96 | - |