Exemplo n.º 1
0
        protected void initialize()
        {
            initialize_base();
            Scene_Type = "Scene_Title";

            if (SkipIntro)
            {
                if (Global.scene.scene_type == "Scene_Soft_Reset")
                {
                    MenuManager = TitleMenuManager.MainMenu(this);
                    TitleTheme  = TitleThemeStarts.FadeInTheme;
                }
                else
                {
                    MenuManager = TitleMenuManager.TitleScreen(this);
                    TitleTheme  = TitleThemeStarts.PlayTheme;
                }
            }
            else
            {
                MenuManager = TitleMenuManager.Intro(this);
                TitleTheme  = TitleThemeStarts.Transition;
            }

            Global.load_save_info = true;
            Global.check_for_updates();
        }
Exemplo n.º 2
0
        public void update(KeyboardState key_state)
        {
            update_message();

            Player.update_anim();
            if (update_soft_reset())
            {
                return;
            }

            if (!Global.load_save_info)
            {
                if (TitleTheme != TitleThemeStarts.None)
                {
                    switch (TitleTheme)
                    {
                    case TitleThemeStarts.PlayTheme:
                        Global.Audio.PlayBgm(Global.BgmConfig.TitleTheme);
                        break;

                    case TitleThemeStarts.FadeInTheme:
                        Global.Audio.PlayBgm(Global.BgmConfig.TitleTheme, true);
                        break;

                    case TitleThemeStarts.Transition:
                        Global.Audio.PlayBgm(Global.BgmConfig.ChapterTransitionTheme);
                        break;
                    }
                    TitleTheme = TitleThemeStarts.None;
                }
            }

            if (Closing)
            {
                // If trying to load suspend and failed
                if (Loading_Suspend && !Global.suspend_load_successful)
                {
                    Loading_Suspend = false;
                    Closing         = false;
                }
                else
                {
                    Timer++;
                    if (Timer >= Config.TITLE_GAME_START_TIME)
                    {
                        // If shutting down
                        if (Quitting)
                        {
                            Global.quit();
                        }
                        // If loading suspend
                        else if (Loading_Suspend)
                        {
                            Global.scene_change("Load_Suspend");
                        }
                        // Else start game
                        else
                        {
                            Global.game_system.Difficulty_Mode = Global.save_file.Difficulty;
                            start_game();
                        }
                        MenuManager = null;
                        return;
                    }
                }
            }

            MenuManager.Update(!Closing);
            SoftResetBlocked = MenuManager != null && MenuManager.SoftResetBlocked;
        }