rnd-20060816-2-src
authorHolger Schemel <info@artsoft.org>
Wed, 16 Aug 2006 19:25:59 +0000 (21:25 +0200)
committerHolger Schemel <info@artsoft.org>
Sat, 30 Aug 2014 08:52:51 +0000 (10:52 +0200)
13 files changed:
src/conf_gfx.c
src/conftime.h
src/game.c
src/game_em/graphics.c
src/game_em/input.c
src/init.c
src/libgame/system.c
src/main.c
src/main.h
src/screens.c
src/screens.h
src/tools.c
src/tools.h

index f0c99a794cb5e311aa2f824ffe8d3be376f6ad4a..3a5a7a8685af028ba03e4d0a378bd22c80319688 100644 (file)
@@ -4535,6 +4535,9 @@ struct ConfigInfo image_config[] =
   { "menu.list_size.SCORES",                   "-1"                    },
   { "menu.list_size.INFO",                     "-1"                    },
 
+  { "menu.fade_delay",                         "250"                   },
+  { "menu.post_delay",                         "125"                   },
+
   { "door_1.width",                            "-1"                    },
   { "door_1.height",                           "-1"                    },
   { "door_1.step_offset",                      "2"                     },
index 82074becfe6f8b7c8ca7ebccc4830c886f01d61e..a4d3e98d352854cc6957d5e7f0169fa2ecd1a18e 100644 (file)
@@ -1 +1 @@
-#define COMPILE_DATE_STRING "[2006-08-16 01:45]"
+#define COMPILE_DATE_STRING "[2006-08-16 21:23]"
index aa9fa6f4d27b3e07483d5a6cc55c414ecbe872d3..4e4c901c990286248b043614b2716d243a3d822e 100644 (file)
@@ -2634,12 +2634,12 @@ void InitGame()
 
   StopAnimation();
 
-  if (do_fading)
-    FadeOutField(TITLE_SCREEN_FADE_DELAY, TITLE_SCREEN_POST_DELAY);
-
   if (!game.restart_level)
     CloseDoor(DOOR_CLOSE_1);
 
+  if (do_fading)
+    FadeOut(REDRAW_FIELD);
+
   /* !!! FIX THIS (START) !!! */
   if (level.game_engine_type == GAME_ENGINE_TYPE_EM)
   {
@@ -2666,7 +2666,7 @@ void InitGame()
   /* !!! FIX THIS (END) !!! */
 
   if (do_fading)
-    FadeInField(TITLE_SCREEN_FADE_DELAY);
+    FadeIn(REDRAW_FIELD);
 
   if (!game.restart_level)
   {
@@ -3059,11 +3059,11 @@ void GameEnd()
 
   if (!local_player->LevelSolved_SaveScore)
   {
-    FadeOutField(TITLE_SCREEN_FADE_DELAY, TITLE_SCREEN_POST_DELAY);
+    FadeOut(REDRAW_FIELD);
 
     game_status = GAME_MODE_MAIN;
 
-    DrawMainMenuExt(TITLE_SCREEN_FADE_DELAY, REDRAW_FIELD);
+    DrawAndFadeInMainMenu(REDRAW_FIELD);
 
     return;
   }
@@ -3093,7 +3093,7 @@ void GameEnd()
   }
   else
   {
-    FadeOutField(TITLE_SCREEN_FADE_DELAY, TITLE_SCREEN_POST_DELAY);
+    FadeOut(REDRAW_FIELD);
 
     game_status = GAME_MODE_MAIN;
 
@@ -3103,7 +3103,7 @@ void GameEnd()
       TapeErase();
     }
 
-    DrawMainMenuExt(TITLE_SCREEN_FADE_DELAY, REDRAW_FIELD);
+    DrawAndFadeInMainMenu(REDRAW_FIELD);
   }
 
   local_player->LevelSolved_SaveScore = FALSE;
@@ -13434,11 +13434,11 @@ void RequestQuitGame(boolean ask_if_really_quit)
       }
       else
       {
-       FadeOutField(TITLE_SCREEN_FADE_DELAY, TITLE_SCREEN_POST_DELAY);
+       FadeOut(REDRAW_FIELD);
 
        game_status = GAME_MODE_MAIN;
 
-       DrawMainMenuExt(TITLE_SCREEN_FADE_DELAY, REDRAW_FIELD);
+       DrawAndFadeInMainMenu(REDRAW_FIELD);
       }
     }
   }
index 9aff1644d4b8e75f5b4e80efe588d5d48d19ccb2..800ee03faaf8de2a6022b7f3cb5440c36492a99f 100644 (file)
@@ -1028,11 +1028,13 @@ void RedrawPlayfield_EM(boolean force_redraw)
   for (i = 0; i < MAX_PLAYERS; i++)
     blitplayer(&ply[i]);
 
+#if 0
   SyncDisplay();
 
   blitscreen();
 
   FlushDisplay();
+#endif
 }
 
 void game_animscreen(void)
index 353b36eec71687f862d7a44fd7b2f7a0061c9b16..2c6c1faacfb498d0ecbebba05a8f95934166f57b 100644 (file)
@@ -62,6 +62,9 @@ void InitGameEngine_EM()
 
   game_initscreen();
   game_animscreen();
+
+  /* blit playfield from scroll buffer to back buffer for fading in */
+  BlitScreenToBitmap_EM(backbuffer);
 }
 
 void GameActions_EM(byte action[MAX_PLAYERS], boolean warp_mode)
@@ -70,6 +73,14 @@ void GameActions_EM(byte action[MAX_PLAYERS], boolean warp_mode)
 
   game_animscreen();
 
+#if 1
+  SyncDisplay();
+
+  blitscreen();
+
+  FlushDisplay();
+#endif
+
   RandomEM = RandomEM * 129 + 1;
 
   frame = (frame - 1) & 7;
index 1e281a0f30e82779db995da95d86c2e39f4415aa..e8bf10b6882b507396039e60f8e966998f9b457c 100644 (file)
@@ -4496,7 +4496,7 @@ void InitGfx()
     Error(ERR_EXIT, "cannot get filename for '%s'", CONFIG_TOKEN_FONT_INITIAL);
 
   /* create additional image buffers for double-buffering and cross-fading */
-  bitmap_db_title = CreateBitmap(WIN_XSIZE, WIN_YSIZE, DEFAULT_DEPTH);
+  bitmap_db_cross = CreateBitmap(WIN_XSIZE, WIN_YSIZE, DEFAULT_DEPTH);
   bitmap_db_field = CreateBitmap(FXSIZE, FYSIZE, DEFAULT_DEPTH);
   bitmap_db_panel = CreateBitmap(DXSIZE, DYSIZE, DEFAULT_DEPTH);
   bitmap_db_door  = CreateBitmap(3 * DXSIZE, DYSIZE + VYSIZE, DEFAULT_DEPTH);
@@ -4893,7 +4893,7 @@ void OpenAll()
 #endif
 
 #if 0
-  DrawMainMenuExt(TITLE_SCREEN_FADE_DELAY, REDRAW_ALL);
+  DrawMainMenuExt(REDRAW_ALL);
 #else
   DrawMainMenu();
 #endif
index c0448a8e0d14e1d64c8deb694ca4b3e2f685fba5..264a3366832f24750ff3de0a2a9d3527ed2b9377 100644 (file)
@@ -327,6 +327,7 @@ void InitVideoBuffer(DrawBuffer **backbuffer, DrawWindow **window,
   video.width = width;
   video.height = height;
   video.depth = GetRealDepth(depth);
+
   video.fullscreen_available = FULLSCREEN_STATUS;
   video.fullscreen_enabled = FALSE;
   video.fullscreen_modes = NULL;
index 1d48c5d8ac4759147b5a0414f668358aafb242cd..f09dbd62a22d7c8e4ee033673a64d207bd7f33ff 100644 (file)
@@ -20,7 +20,7 @@
 #include "events.h"
 #include "config.h"
 
-Bitmap                *bitmap_db_title;
+Bitmap                *bitmap_db_cross;
 Bitmap                *bitmap_db_field;
 Bitmap                *bitmap_db_panel;
 Bitmap                *bitmap_db_door;
@@ -4664,6 +4664,9 @@ struct TokenIntPtrInfo image_config_vars[] =
   { "menu.list_size.SCORES",   &menu.list_size[GFX_SPECIAL_ARG_SCORES]     },
   { "menu.list_size.INFO",     &menu.list_size[GFX_SPECIAL_ARG_INFO]       },
 
+  { "menu.fade_delay",         &menu.fade_delay                            },
+  { "menu.post_delay",         &menu.post_delay                            },
+
   { "door_1.width",            &door_1.width                               },
   { "door_1.height",           &door_1.height                              },
   { "door_1.step_offset",      &door_1.step_offset                         },
index 1254d9f2ba8116f6e763f37d3bd3d63924963110..cd6ffe2b3bd8d9f020f56221c6a802e26321c2aa 100644 (file)
 #define MICROLEVEL_SCROLL_DELAY        50      /* delay for scrolling micro level */
 #define MICROLEVEL_LABEL_DELAY 250     /* delay for micro level label */
 
-/* values for fading in and out */
-#define TITLE_SCREEN_FADE_DELAY                250
-#define TITLE_SCREEN_POST_DELAY                (TITLE_SCREEN_FADE_DELAY / 2)
-
 /* boundaries of arrays etc. */
 #define MAX_LEVEL_NAME_LEN     32
 #define MAX_LEVEL_AUTHOR_LEN   32
@@ -1846,6 +1842,9 @@ struct MenuInfo
 
   int list_size[NUM_SPECIAL_GFX_ARGS];
 
+  int fade_delay;
+  int post_delay;
+
   int sound[NUM_SPECIAL_GFX_ARGS];
   int music[NUM_SPECIAL_GFX_ARGS];
 };
@@ -2348,7 +2347,7 @@ struct HelpAnimInfo
 };
 
 
-extern Bitmap                 *bitmap_db_title;
+extern Bitmap                 *bitmap_db_cross;
 extern Bitmap                 *bitmap_db_field;
 extern Bitmap                 *bitmap_db_panel;
 extern Bitmap                 *bitmap_db_door;
index 0a4534b5ab7122d4bf3c0a6c93ce8eb4eccafbb6..05956c4c369b741eeed51faf4ae8138b61d0b6c7 100644 (file)
@@ -299,7 +299,7 @@ void DrawTitleScreen()
   StopAnimation();
 }
 
-void DrawMainMenuExt(int fade_delay, int redraw_mask)
+void DrawMainMenuExt(int redraw_mask, boolean do_fading)
 {
   static LevelDirTree *leveldir_last_valid = NULL;
   boolean levelset_has_changed = FALSE;
@@ -532,12 +532,10 @@ void DrawMainMenuExt(int fade_delay, int redraw_mask)
 
 #if 1
 #if 1
-  if (redraw_mask == REDRAW_FIELD)
-    FadeInField(fade_delay);
-  else if (redraw_mask == REDRAW_ALL)
-    FadeIn(fade_delay);
-
-  BackToFront();
+  if (do_fading)
+    FadeIn(redraw_mask);
+  else
+    BackToFront();
 #else
   BackToFront();
 #endif
@@ -552,9 +550,14 @@ void DrawMainMenuExt(int fade_delay, int redraw_mask)
 #endif
 }
 
+void DrawAndFadeInMainMenu(int redraw_mask)
+{
+  DrawMainMenuExt(redraw_mask, TRUE);
+}
+
 void DrawMainMenu()
 {
-  DrawMainMenuExt(0, REDRAW_ALL);
+  DrawMainMenuExt(REDRAW_ALL, FALSE);
 }
 
 #if 0
@@ -594,8 +597,6 @@ void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
   boolean return_to_main_menu = FALSE;
   boolean use_fading_main_menu = TRUE;
   boolean use_cross_fading = TRUE;
-  int fade_delay = TITLE_SCREEN_FADE_DELAY;
-  int post_delay = TITLE_SCREEN_POST_DELAY;
 
   if (button == MB_MENU_INITIALIZE)
   {
@@ -614,7 +615,7 @@ void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
 
       FadeSoundsAndMusic();
 
-      FadeOut(fade_delay, post_delay);
+      FadeOut(REDRAW_ALL);
     }
 
     /* force TITLE music on title info screen */
@@ -627,7 +628,7 @@ void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
 
     DrawTitleScreenImage(title_nr);
 
-    FadeIn(fade_delay);
+    FadeIn(REDRAW_ALL);
 
     return;
   }
@@ -650,7 +651,7 @@ void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
     title_nr++;
 
     if (!use_cross_fading)
-      FadeOut(fade_delay, post_delay);
+      FadeOut(REDRAW_ALL);
 
     if (title_nr < MAX_NUM_TITLE_SCREENS &&
        graphic_info[IMG_TITLESCREEN_1 + title_nr].bitmap != NULL)
@@ -658,22 +659,22 @@ void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
       Bitmap *drawto_last = drawto;
 
       if (use_cross_fading)
-       drawto = bitmap_db_title;
+       drawto = bitmap_db_cross;
 
       DrawTitleScreenImage(title_nr);
 
       drawto = drawto_last;
 
       if (use_cross_fading)
-       FadeCross(fade_delay);
+       FadeCross(REDRAW_ALL);
       else
-       FadeIn(fade_delay);
+       FadeIn(REDRAW_ALL);
     }
     else
     {
       FadeSoundsAndMusic();
 
-      FadeOut(fade_delay, post_delay);
+      FadeOut(REDRAW_ALL);
 
       return_to_main_menu = TRUE;
     }
@@ -681,8 +682,6 @@ void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
 
   if (return_to_main_menu)
   {
-    int menu_fade_delay = (use_fading_main_menu ? fade_delay : 0);
-
     RedrawBackground();
 
     if (game_status == GAME_MODE_INFO)
@@ -690,14 +689,14 @@ void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
       OpenDoor(DOOR_CLOSE_1 | DOOR_CLOSE_2 | DOOR_NO_DELAY | DOOR_FORCE_REDRAW);
 
       info_mode = INFO_MODE_MAIN;
-      DrawInfoScreenExt(menu_fade_delay);
+      DrawInfoScreenExt(use_fading_main_menu);
     }
     else       /* default: return to main menu */
     {
       OpenDoor(DOOR_CLOSE_1 | DOOR_OPEN_2 | DOOR_NO_DELAY | DOOR_FORCE_REDRAW);
 
       game_status = GAME_MODE_MAIN;
-      DrawMainMenuExt(menu_fade_delay, REDRAW_ALL);
+      DrawMainMenuExt(REDRAW_ALL, use_fading_main_menu);
     }
   }
 }
@@ -994,7 +993,7 @@ static struct TokenInfo info_info_main[] =
   { 0,                 NULL,                   NULL                    }
 };
 
-static void DrawInfoScreen_Main(int fade_delay)
+static void DrawInfoScreen_Main(boolean do_fading)
 {
   int i;
 
@@ -1037,7 +1036,11 @@ static void DrawInfoScreen_Main(int fade_delay)
   PlayMenuSound();
   PlayMenuMusic();
 
-  FadeIn(fade_delay);
+  if (do_fading)
+    FadeIn(REDRAW_ALL);
+  else
+    BackToFront();
+
   InitAnimation();
 
 #else
@@ -1466,7 +1469,7 @@ void HandleInfoScreen_Music(int button)
     FadeSoundsAndMusic();
 
     if (button != MB_MENU_INITIALIZE)
-      drawto = bitmap_db_title;
+      drawto = bitmap_db_cross;
 
     ClearWindow();
     DrawHeadline();
@@ -1533,7 +1536,7 @@ void HandleInfoScreen_Music(int button)
     drawto = drawto_last;
 
     if (button != MB_MENU_INITIALIZE)
-      FadeCrossField(TITLE_SCREEN_FADE_DELAY);
+      FadeCross(REDRAW_FIELD);
   }
 
   if (list != NULL && list->is_sound && sound_info[list->music].loop)
@@ -1743,7 +1746,7 @@ void HandleInfoScreen_Credits(int button)
 
     screen_nr++;
 
-    drawto = bitmap_db_title;
+    drawto = bitmap_db_cross;
 
     show_screen = DrawInfoScreen_CreditsScreen(screen_nr);
 
@@ -1751,7 +1754,7 @@ void HandleInfoScreen_Credits(int button)
   
     if (show_screen)
     {
-      FadeCrossField(TITLE_SCREEN_FADE_DELAY);
+      FadeCross(REDRAW_FIELD);
     }
     else
     {
@@ -1893,7 +1896,7 @@ void HandleInfoScreen_LevelSet(int button)
   }
 }
 
-static void DrawInfoScreenExt(int fade_delay)
+static void DrawInfoScreenExt(boolean do_fading)
 {
   SetMainBackgroundImage(IMG_BACKGROUND_INFO);
 
@@ -1910,7 +1913,7 @@ static void DrawInfoScreenExt(int fade_delay)
   else if (info_mode == INFO_MODE_LEVELSET)
     DrawInfoScreen_LevelSet();
   else
-    DrawInfoScreen_Main(fade_delay);
+    DrawInfoScreen_Main(do_fading);
 
   if (info_mode != INFO_MODE_MAIN &&
       info_mode != INFO_MODE_TITLE &&
@@ -2420,7 +2423,7 @@ void DrawHallOfFame(int highlight_position)
   if (highlight_position < 0) 
     LoadScore(level_nr);
 
-  FadeOutField(TITLE_SCREEN_FADE_DELAY, TITLE_SCREEN_POST_DELAY);
+  FadeOut(REDRAW_FIELD);
 
 #if 0
   FadeToFront();
@@ -2432,7 +2435,7 @@ void DrawHallOfFame(int highlight_position)
 
   HandleHallOfFame(highlight_position, 0, 0, 0, MB_MENU_INITIALIZE);
 
-  FadeInField(TITLE_SCREEN_FADE_DELAY);
+  FadeIn(REDRAW_FIELD);
 }
 
 static void drawHallOfFameList(int first_entry, int highlight_position)
@@ -2524,16 +2527,16 @@ void HandleHallOfFame(int mx, int my, int dx, int dy, int button)
 
     game_status = GAME_MODE_MAIN;
 
-    DrawMainMenuExt(0, REDRAW_FIELD);
+    DrawMainMenu();
   }
   else if (button == MB_MENU_CHOICE)
   {
     FadeSound(SND_BACKGROUND_SCORES);
-    FadeOutField(TITLE_SCREEN_FADE_DELAY, TITLE_SCREEN_POST_DELAY);
+    FadeOut(REDRAW_FIELD);
 
     game_status = GAME_MODE_MAIN;
 
-    DrawMainMenuExt(TITLE_SCREEN_FADE_DELAY, REDRAW_FIELD);
+    DrawAndFadeInMainMenu(REDRAW_FIELD);
   }
 
   if (game_status == GAME_MODE_SCORES)
index 17eec4d3967f96a6d216f6b34afc3f51c1891fbd..f54106e2042b5d9fe6264cfac81cc3d88bc04366 100644 (file)
@@ -21,7 +21,8 @@
 #define SCROLL_PAGE    (2 * SCR_FIELDY)
 
 
-void DrawMainMenuExt(int, int);
+void DrawMainMenuExt(int, boolean);
+void DrawAndFadeInMainMenu(int);
 void DrawMainMenu(void);
 void DrawHallOfFame(int);
 
index 8d0fe8deab0d5524716148911957e9aa00005232..72b5a2902aa290a0dc57f47b64a98cefaf1d2826 100644 (file)
@@ -414,99 +414,60 @@ void FadeToFront()
   BackToFront();
 }
 
-void FadeIn(int fade_delay)
+void FadeExt(int fade_mask, int fade_mode)
 {
-  if (fade_delay == 0)
-  {
-    BackToFront();
+  Bitmap *bitmap = (fade_mode == FADE_MODE_CROSSFADE ? bitmap_db_cross : NULL);
+  int fade_delay = menu.fade_delay;
+  int post_delay = (fade_mode == FADE_MODE_FADE_OUT ? menu.post_delay : 0);
+  int x, y, width, height;
 
-    return;
+  if (fade_mask & REDRAW_ALL)
+  {
+    x = 0;
+    y = 0;
+    width  = WIN_XSIZE;
+    height = WIN_YSIZE;
   }
-
-  FadeRectangle(NULL, 0, 0, WIN_XSIZE, WIN_YSIZE,
-               FADE_MODE_FADE_IN, fade_delay, 0);
-
-  redraw_mask = REDRAW_NONE;
-}
-
-void FadeOut(int fade_delay, int post_delay)
-{
-  if (fade_delay == 0)
+  else if (fade_mask & REDRAW_FIELD)
   {
-    ClearRectangle(backbuffer, 0, 0, WIN_XSIZE, WIN_YSIZE);
-    BackToFront();
-
-    return;
+    x = REAL_SX;
+    y = REAL_SY;
+    width  = FULL_SXSIZE;
+    height = FULL_SYSIZE;
   }
 
-  FadeRectangle(NULL, 0, 0, WIN_XSIZE, WIN_YSIZE,
-               FADE_MODE_FADE_OUT, fade_delay, post_delay);
-
-  redraw_mask = REDRAW_NONE;
-}
+  redraw_mask |= fade_mask;
 
-void FadeCross(int fade_delay)
-{
   if (fade_delay == 0)
   {
-    BlitBitmap(bitmap_db_title, backbuffer, 0, 0, WIN_XSIZE, WIN_YSIZE, 0, 0);
+    if (fade_mode == FADE_MODE_CROSSFADE)
+      BlitBitmap(bitmap, backbuffer, x, y, width, height, x, y);
+    else if (fade_mode == FADE_MODE_FADE_OUT)
+      ClearRectangle(backbuffer, x, y, width, height);
+
     BackToFront();
 
     return;
   }
 
-  FadeRectangle(bitmap_db_title, 0, 0, WIN_XSIZE, WIN_YSIZE,
-               FADE_MODE_CROSSFADE, fade_delay, 0);
+  FadeRectangle(bitmap, x, y, width, height, fade_mode, fade_delay, post_delay);
 
-  redraw_mask = REDRAW_NONE;
+  redraw_mask &= ~fade_mask;
 }
 
-void FadeInField(int fade_delay)
+void FadeIn(int fade_mask)
 {
-  if (fade_delay == 0)
-  {
-    BackToFront();
-
-    return;
-  }
-
-  FadeRectangle(NULL, REAL_SX, REAL_SY, FULL_SXSIZE, FULL_SYSIZE,
-               FADE_MODE_FADE_IN, fade_delay, 0);
-
-  redraw_mask &= ~REDRAW_FIELD;
+  FadeExt(fade_mask, FADE_MODE_FADE_IN);
 }
 
-void FadeOutField(int fade_delay, int post_delay)
+void FadeOut(int fade_mask)
 {
-  if (fade_delay == 0)
-  {
-    ClearRectangle(backbuffer, REAL_SX, REAL_SY, FULL_SXSIZE, FULL_SYSIZE);
-    BackToFront();
-
-    return;
-  }
-
-  FadeRectangle(NULL, REAL_SX, REAL_SY, FULL_SXSIZE, FULL_SYSIZE,
-               FADE_MODE_FADE_OUT, fade_delay, post_delay);
-
-  redraw_mask &= ~REDRAW_FIELD;
+  FadeExt(fade_mask, FADE_MODE_FADE_OUT);
 }
 
-void FadeCrossField(int fade_delay)
+void FadeCross(int fade_mask)
 {
-  if (fade_delay == 0)
-  {
-    BlitBitmap(bitmap_db_title, backbuffer, REAL_SX, REAL_SY,
-              FULL_SXSIZE, FULL_SYSIZE, REAL_SX, REAL_SY);
-    BackToFront();
-
-    return;
-  }
-
-  FadeRectangle(bitmap_db_title, REAL_SX, REAL_SY, FULL_SXSIZE, FULL_SYSIZE,
-               FADE_MODE_CROSSFADE, fade_delay, 0);
-
-  redraw_mask &= ~REDRAW_FIELD;
+  FadeExt(fade_mask, FADE_MODE_CROSSFADE);
 }
 
 void SetMainBackgroundImageIfDefined(int graphic)
index 55929e502d8016fa71103f1fd317c4b91c29f190..21288a94475c080bd740b675a546bdc835ecbd4a 100644 (file)
@@ -68,11 +68,8 @@ void BackToFront();
 void FadeToFront();
 
 void FadeIn(int);
-void FadeOut(int, int);
+void FadeOut(int);
 void FadeCross(int);
-void FadeInField(int);
-void FadeOutField(int, int);
-void FadeCrossField(int);
 
 void ClearWindow();
 void SetMainBackgroundImageIfDefined(int);