rnd-20050103-1-src
[rocksndiamonds.git] / src / game_em / global.h
1 #ifndef GLOBAL_H
2 #define GLOBAL_H
3
4 #include "main_em.h"
5
6 #define EM_GFX_DIR      "graphics.EM"
7 #define EM_SND_DIR      "sounds.EM"
8 #define EM_LVL_DIR      "levels.EM"
9
10 /* arbitrary maximum length of filenames (cos i am lazy) */
11 #define MAXNAME 1024
12
13 extern int debug;
14 extern char *progname;
15 extern char *arg_basedir;
16
17 extern unsigned int frame;
18
19 extern short ulaw_to_linear[256];
20 extern unsigned char linear_to_ulaw[65536];
21
22 /* all global function prototypes */
23
24 int open_all(void);
25 void close_all(void);
26
27 void readjoy(byte);
28 void input_eventloop(void);
29
30 void blitscreen(void);
31 void game_initscreen(void);
32 void game_animscreen(void);
33
34 void DrawGameDoorValues_EM();
35
36 void play_sound(int, int, int);
37 void sound_play(void);
38
39 int cave_convert(char *);
40 boolean LoadNativeLevel_EM(char *);
41
42 void game_init_vars(void);
43 void game_play_init(int, char *);
44 void game_loop(byte);
45
46 void synchro_1(void);
47 void synchro_2(void);
48 void synchro_3(void);
49
50 int  cleanup_em_level(unsigned char *, int);
51 void convert_em_level(unsigned char *, int);
52 void prepare_em_level(void);
53
54 int sound_thread(void);
55 int read_sample(char *, short **, long *);
56
57 void read_cave_list(void);
58 void free_cave_list(void);
59
60 #endif