#include <stdio.h>
#include <stdlib.h>
int main( int argc, char *argv[] ){
int width = 640, height = 480;
const char* file_path_of_creature = "creature.png";
if( ! creature ){
fprintf(
stderr, "It was impossible to load the file %s.\n",
file_path_of_creature
);
exit(1);
}
const char* file_path_of_sound = "walk.ogg";
if( ! sound ){
fprintf(
stderr, "It was impossible to load the file %s.\n",
file_path_of_sound
);
exit(1);
}
int nb_frames = 6;
int nb_layers = 1;
int nb_channels = 1;
int w = 79, h = 79;
nb_frames, nb_layers, nb_channels
);
int layer = 0;
images+0, &sound, 4, animation
);
images+1, NULL, 4, animation
);
images+2, &sound, 4, animation
);
images+3, NULL, 4, animation
);
int avance = 0;
int pas = 4;
while(
&touche, NULL, NULL,
NULL, NULL,
NULL, NULL, NULL,
NULL
touche != MLV_KEYBOARD_ESCAPE
){
);
avance += pas;
if( avance > width-w ){
pas = -pas;
}
if( avance < 0 ){
pas = -pas;
}
int position_y = 20;
}
return 0;
}