void run_display(void);
void level_announcement(void);
void display_quit_query(void);
void clear_quit_query(void);

#define GB_SHIP_TYPES 8

#define NO_TILE_RLES 40


enum
{
BMP_WHATEVER,

ENEMY1_BMPS
};

enum
{
RLE_ENEMY1_STINGER,
RLE_ENEMY1_DRIFTER,
RLE_ENEMY1_WANDERER,
RLE_ENEMY1_SUN,
RLE_ENEMY1_SUN_WHITE,
RLE_ENEMY1_JELLY1,
RLE_ENEMY1_JELLY2,
RLE_ENEMY1_JELLY3,
RLE_ENEMY1_JELLY4,
RLE_ENEMY1_JELLY5,
RLE_ENEMY1_JELLY6,
RLE_ENEMY1_MINETHROWER,
RLE_ENEMY1_MINETHROWER2,
RLE_ENEMY1_CURVER,
RLE_ENEMY1_STINGER2,
RLE_ENEMY1_BLASTER,
RLE_ENEMY1_STINGER3,
RLE_ENEMY1_FLAKKER,
RLE_ENEMY1_SUPERJELLY,
RLE_ENEMY1_HIVE,
RLE_ENEMY1_STINGER4,
RLE_ENEMY1_FLAKKER2,
RLE_ENEMY1_BOLTER,
RLE_ENEMY1_BOLTER2,
RLE_ENEMY1_TORPER1_1,
RLE_ENEMY1_TORPER1_2,
RLE_ENEMY1_TORPER1_3,
RLE_ENEMY1_TORPER1_4,
RLE_ENEMY1_HURLER,
RLE_ENEMY1_HURLER2,
ENEMY1_RLES
};

enum
{
BMP_ENEMY_PULSER1_V,
BMP_ENEMY_PULSER1_H,
BMP_ENEMY_PULSER2_V,
BMP_ENEMY_PULSER2_H,
ENEMY_BMPS
};

enum
{
RLE_ENEMY2_CRAWLER2_D,
RLE_ENEMY2_CRAWLER2_L,
RLE_ENEMY2_CRAWLER2_R,
RLE_ENEMY2_CRAWLER3_D,
RLE_ENEMY2_CRAWLER3_L,
RLE_ENEMY2_CRAWLER3_R,
RLE_ENEMY2_CRAWLER4_D,
RLE_ENEMY2_CRAWLER4_L,
RLE_ENEMY2_CRAWLER4_R,
ENEMY2_RLES
};

enum
{
RLE_ENEMY3_FIREBASE,
RLE_ENEMY3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ELD_UR7,
BMP_SHIELD_UR8,
BMP_SHIELD_DR1,
BMP_SHIELD_DR2,
BMP_SHIELD_DR3,
BMP_SHIELD_DR4,
BMP_SHIELD_DR5,
BMP_SHIELD_DR6,
BMP_SHIELD_DR7,
BMP_SHIELD_DL2,
BMP_SHIELD_DL3,
BMP_SHIELD_DL4,
BMP_SHIELD_DL5,
BMP_SHIELD_DL6,
BMP_SHIELD_DL7,
BMP_SHIELD_DL8,
SHIELD_BMPS
};

enum
{
BMP_SMALL2_MISSILE_1,
BMP_SMALL2_MISSILE_2,
BMP_SMALL2_MISSILE_3,
BMP_SMALL2_MISSILE_4,
BMP_SMALL2_MISSILE_5,
BMP_SMALL2_MISSILE_6,
BMP_SMALL2_MISSILE_7,
BMP_SMALL2_BOMB,
BMP_SMALL2_SIDE_BOMB,

SMALL2_BMPS
};

enum
{
RLE_LSHIP_BLUE,
RLE_LSHIP_GREEN,
RLE_LSHIP_YELLOW,
RLE_LSHIP_RED,
RLE_LSHIP_LINES
};


enum
{
STYLE_NONE,
STYLE_HURRY,
STYLE_ONLINE,
STYLE_UPGRADE1,
STYLE_UPGRADE2,
STYLE_UPGRADE3,
STYLE_UPGRADE4,
STYLE_UPGRADE5,
STYLE_NEWLEVEL
};


enum
{
PRETILE_BG_CHECK,
PRETILE_OUTER1_D,
PRETILE_OUTER1_DR,
PRETILE_OUTER1_OUT, // 10
PRETILE_EYE1_CLOSED,
PRETILE_EYE1_OPEN,
PRETILE_BG_DIAMOND,
PRETILE_BG_MESH1,
PRETILE_BG_MESH2,
PRETILE_BG_FLOWERS,
PRETILE_BG_SQUARES,
PRETILE_OUTER2_D,
PRETILE_OUTER2_DR,
PRETILE_OUTER2_OUT,
PRETILE_BG_DIAMOND2,
PRETILE_BG_CROSS,
PRETILE_BG_SQUARES2, // 30
PRETILE_BG_CIRCLES,
PRETILE_BG_GRID,
PRETILE_BG_THING,
PRETILE_BG_PATTERN,
PRETILE_EYE2_CLOSED,
PRETILE_EYE2_OPEN,
PRETILE_EYE3_CLOSED,
PRETILE_EYE3_OPEN,
PRETILE_EYE4_CLOSED,
PRETILE_EYE4_OPEN,
PRETILE_OUTER3_D,
PRETILE_OUTER3_DR,
PRETILE_OUTER3_OUT,
PRETILE_OUTER4_D,
PRETILE_OUTER4_DR,
PRETILE_OUTER4_OUT,
PRETILE_OUTER5_D,
PRETILE_OUTER5_DR,
PRETILE_OUTER5_OUT,
PRETILE_OUTER6_D,
PRETILE_OUTER6_DR,
PRETILE_OUTER6_OUT,
PRETILE_OUTER7_D,
PRETILE_OUTER7_DR,
PRETILE_OUTER7_OUT,
NO_PRETILE_BMPS
// need to compile display_in to put new ones in
};

enum
{
PRETILE_M_UD,
PRETILE_M_LR,
PRETILE_M_UR,
PRETILE_M_ULR,
PRETILE_M_UDLR,
PRETILE_M_U,
PRETILE_M_NODE,
PRETILE_M_EYE_UDLR,
NO_PRETILE_M_BMPS
// plus specials...
};

enum
{
MAZE_STRAIGHT,
MAZE_ZIGZAG,
MAZE_CIRCLES,
MAZE_ZIP,
MAZE_RINGS,
MAZE_TRIANGLES,
MAZE_PIPES,
MAZE_BOXES,
MAZE_WIRES,
MAZE_SQUARES,
MAZE_TUBES,
MAZE_STUDDED,
MAZE_DIAMONDS,
NO_MAZES
};

//void init_messages(void);
void send_message(int play, const char *msg, int style);


struct effects_struct
{
 int type;
 int x;
 int y;
 int x1;
 int x2;
 int y1;
 int y2;
 int things [5];
};

#define MAX_EFFECTS 15

enum
{
EFFECT_NONE,
EFFECT_REDBEAM,
EFFECT_BLUEBEAM,
EFFECT_RED_ARC,
EFFECT_ZAP_AIM,
EFFECT_WAVE1,
EFFECT_WAVE2
};

#ifndef COMPILING_DISPLAYC
extern int graphics_mode;
extern int scr_x;
extern int scr_y;
extern int sp_window_width;
extern int tp_window_width;
extern int grid_offset_x_1p;
extern int grid_offset_x_2p;
extern int grid_offset_y;
extern int special_600_y;
extern int text_offset_x_1p;
extern int text_offset_x_2p;
extern int text_offset_y;
extern int text_offset_x;
extern struct effects_struct effect [MAX_EFFECTS];
extern int grid_finetune_x_1p;
extern int grid_finetune_x_2p;
extern int grid_finetune_y;
extern int visible_grids_y;
#endif

enum
{
GMODE_640_480,
GMODE_800_600,
GMODE_1024_768
};

