space-shooter/include/objects.h

31 lines
604 B
C

#ifndef OBJECTS_H
#define OBJECTS_H
#include "utils.h"
/* speed, game_obj, status definitions */
struct speed {
int slowness;
int count;
};
struct game_obj {
char symbol;
int x, y;
int active;
struct speed y_speed;
};
struct status {
int lives;
int score;
int top_score;
int remaining_bullets;
};
/* constructors / initializers */
void init_player(struct game_obj *player, int win_width, int win_height);
void init_bullets(struct game_obj bullets[]);
void init_enemies(struct game_obj enemies[]);
#endif /* OBJECTS_H */