#ifndef __GLOBALS_H #define __GLOBALS_H /* global variables */ int musicplaying; levelentry_t levelentry[MAXLEVELS]; // level filenames etc int numlevels; int curlevelnum; int maxlevid; int want1up,want2up; int swapplayers; int globpowerup; int gamemode; // easy or hard? int showhelp; // show help text? spriteinfo_t spriteinfo[MAXPTYPES]; char progname[MIDBUFLEN]; char *datadir; int gotcard; // got a card yet this level? int curcard; int deck[DECKSIZE]; int forcegoodcard; int nextforcegoodcard; // pointer to function void (*drawpixel)(SDL_Surface *s, int x, int y, SDL_Color c); SDL_Surface *levelbg; // level background image SDL_Surface *temps; // temporary surface SDL_Surface *screen; // the actual video screen SDL_Surface *head,*head5; // imgs in corner showing number of lives SDL_Surface *grave; SDL_Surface *head2,*head52; // imgs in corner showing number of lives SDL_Surface *icecube; // overlaid on frozen monsters SDL_Surface *greenbox; // for fly spray effect SDL_Surface *redbox; // for gunner SDL_Surface *healthbar[HEALTHFRAMES]; // for boss health sprite_t *sprite; // head of sprite linked list sprite_t *lastsprite; // tail of sprite linked list sprite_t *player, *player2; // pointer to the player's sprite sprite_t *boss; // point to current boss on level (normally NULL) Mix_Music *music, *fastmusic, *normalmusic,*bossmusic,*hiscoremusic; Mix_Chunk *sfx[MAXFX]; text_t *text, *lasttext; level_t *curlevel; // the current level's data int levelcomplete; // has the levle been finished? int nexthurryup; // next hurryuptime for the level int cheat; tiletype_t fakeblock; // used for returning tiletypes from a function int oldexitdir; // exit direction of previous level int vidargs; // arguments for SetVideo call TTF_Font *font[MAXLETTERHEIGHT]; TTF_Font *cardfont; /* 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 char *deathtext[] = { "Ouch!", "Ow!", "Argh!", "Noooo!" }; char *bifftext[] = { "Biff!", "Pow!", "Wham!", "Splat!" }; /* colours */ SDL_Color red; SDL_Color black; SDL_Color blue; SDL_Color white; SDL_Color green; SDL_Color purple; SDL_Color yellow; #endif