Le nouveau Super Mario Bros pour la gamme des fx9860g https://www.planet-casio.com/Fr/forums/topic15994-1-[addin]-SuperCasioBros-v0.1.html
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
supercasiobros/include/plateforme.h

50 lines
848 B

#ifndef PLATEFORME_H
#define PLATEFORME_H
#define P_FALLING 0
#define P_MOVING_H 1
#define P_MOVING_V 2
#include <box.h>
typedef struct
{
unsigned type;
int xinit, yinit;
union
{
int xmin;
int ymin;
};
union
{
int xmax;
int ymax;
};
int counter;
box_t b;
} plateform_t;
#define PLATEFORME_HEIGHT 3
// Init macros
#define PLATEFORME_FALLING(x,y,w) {P_FALLING,x,y,.xmin=0,.xmax=0,0, {x,y,w,3, 0,0, 0,0}}
#define PLATEFORME_MOVING_H(x,y,w,v,x0,x1) {P_MOVING_H,x,y,.xmin=x0,.xmax=x1,0, {x,y,w,3, v,0, 0,0}}
#define PLATEFORME_MOVING_V(x,y,w,v,y0,y1) {P_MOVING_V,x,y,.ymin=y0,.ymax=y1,0, {x,y,w,3, 0,v, 0,0}}
void platformsMove();
void platformsDraw();
int platformsCollisionTest(int x, int y);
void platformsInit(plateform_t * table, int s);
/*
extern int plateform_table_size;
extern plateform_t* plateformes;
*/
#endif