2008-09-17 12:34:39 +10:00
|
|
|
#ifndef __GLOBALS_H
|
|
|
|
#define __GLOBALS_H
|
|
|
|
|
|
|
|
/* global variables */
|
|
|
|
SDL_Surface *temps; // temporary surface
|
|
|
|
SDL_Surface *screen; // the actual video screen
|
|
|
|
sprite_t *sprite; // head of sprite linked list
|
|
|
|
sprite_t *lastsprite; // tail of sprite linked list
|
|
|
|
sprite_t *player; // pointer to the player's sprite
|
|
|
|
|
2008-09-26 19:51:17 +10:00
|
|
|
Mix_Music *music;
|
|
|
|
Mix_Chunk *sfx[MAXFX];
|
|
|
|
|
2008-09-17 12:34:39 +10:00
|
|
|
level_t *curlevel; // the current level's data
|
|
|
|
|
|
|
|
tiletype_t fakeblock; // used for returning tiletypes from a function
|
|
|
|
|
|
|
|
int vidargs; // arguments for SetVideo call
|
|
|
|
|
|
|
|
TTF_Font *font[MAXLETTERHEIGHT];
|
|
|
|
|
|
|
|
/* timers */
|
|
|
|
int gtime; // game time - time elapsed on current level
|
|
|
|
int timer; // generic 1-100 timer for repeated events
|
|
|
|
int toggletimer; // used for toggling between fullscreen mode
|
|
|
|
|
|
|
|
/* colours */
|
|
|
|
SDL_Color red;
|
|
|
|
SDL_Color black;
|
|
|
|
SDL_Color white;
|
|
|
|
SDL_Color green;
|
|
|
|
SDL_Color yellow;
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|