X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fmain.c;h=bf7e3f5bcba90a439112bc038f705e0bf57495c7;hb=1465ca1ffdf2104d25b9a46ca9bf8a3f175403fd;hp=b980ea24d1585761f9b73dcfb3c31dac8ca06a6a;hpb=4bca9bc5f299a9b287134b06e41b147f506792b4;p=rocksndiamonds.git diff --git a/src/main.c b/src/main.c index b980ea24..bf7e3f5b 100644 --- a/src/main.c +++ b/src/main.c @@ -11,33 +11,51 @@ * main.c * ***********************************************************/ +#include "libgame/libgame.h" + #include "main.h" #include "init.h" #include "game.h" #include "events.h" -#include "sound.h" #include "joystick.h" -#include "misc.h" #if defined(PLATFORM_MSDOS) #include #endif -Display *display; -Visual *visual; -int screen; +#if 0 DrawWindow window = None; -GC gc, clip_gc[NUM_BITMAPS], tile_clip_gc; +DrawBuffer backbuffer; +GC gc; +#endif + +#if 0 +GC clip_gc[NUM_BITMAPS]; +#endif +GC tile_clip_gc; Bitmap pix[NUM_BITMAPS]; -Bitmap pix_masked[NUM_BITMAPS], tile_masked[NUM_TILES]; -Pixmap clipmask[NUM_BITMAPS], tile_clipmask[NUM_TILES]; +#if 0 +Bitmap pix_masked[NUM_BITMAPS]; + +Bitmap tile_masked[NUM_TILES]; + +Pixmap clipmask[NUM_BITMAPS]; +#endif +Pixmap tile_clipmask[NUM_TILES]; -DrawBuffer drawto, drawto_field, backbuffer, fieldbuffer; +#if 0 +DrawBuffer drawto; +#endif + +DrawBuffer drawto_field, fieldbuffer; +#if 0 Colormap cmap; +#endif + +#if 0 +char *sound_device_name = AUDIO_DEVICE; +#endif -int sound_pipe[2]; -int sound_device; -char *sound_device_name = SOUND_DEVICE; int joystick_device = 0; char *joystick_device_name[MAX_PLAYERS] = { @@ -57,15 +75,19 @@ boolean motion_status = FALSE; int key_joystick_mapping = 0; int global_joystick_status = JOYSTICK_STATUS; int joystick_status = JOYSTICK_STATUS; -int sound_status = SOUND_STATUS; -boolean sound_loops_allowed = FALSE; + +#if 0 boolean fullscreen_available = FULLSCREEN_STATUS; boolean fullscreen_enabled = FALSE; +#endif boolean redraw[MAX_BUF_XSIZE][MAX_BUF_YSIZE]; int redraw_x1 = 0, redraw_y1 = 0; + +#if 0 int redraw_mask; int redraw_tiles; +#endif short Feld[MAX_LEV_FIELDX][MAX_LEV_FIELDY]; short Ur[MAX_LEV_FIELDX][MAX_LEV_FIELDY]; @@ -97,7 +119,12 @@ int SBX_Left, SBX_Right; int SBY_Upper, SBY_Lower; int ZX,ZY, ExitX,ExitY; int AllPlayersGone; -int FrameCounter, TimeFrames, TimePlayed, TimeLeft; + +#if 0 +int FrameCounter; +#endif + +int TimeFrames, TimePlayed, TimeLeft; boolean network_player_action_received = FALSE; @@ -105,11 +132,21 @@ struct LevelDirInfo *leveldir_first = NULL, *leveldir_current = NULL; struct LevelInfo level; struct PlayerInfo stored_player[MAX_PLAYERS], *local_player = NULL; struct HiScore highscore[MAX_SCORE_ENTRIES]; -struct SoundInfo Sound[NUM_SOUNDS]; +struct SampleInfo Sound[NUM_SOUNDS]; struct TapeInfo tape; + +#if 0 struct OptionInfo options; +#endif + struct SetupInfo setup; struct GameInfo game; + +#if 0 +struct VideoSystemInfo video; +struct AudioSystemInfo audio; +#endif + struct GlobalInfo global; /* data needed for playing sounds */ @@ -565,6 +602,8 @@ int num_element_info = sizeof(element_info)/sizeof(char *); +#if 0 + /* +-----------------------------------------------------------------------+ */ /* | SDL TEST STUFF | */ /* +-----------------------------------------------------------------------+ */ @@ -939,6 +978,8 @@ void TEST_SDL_JOYSTICK() /* | SDL TEST STUFF | */ /* +-----------------------------------------------------------------------+ */ +#endif + int main(int argc, char *argv[])