コード例 #1
0
ファイル: SceneManager.cs プロジェクト: kraban/Outer-Space
        public static void Initialize()
        {
            menuScene       = new MenuScene();
            optionsScene    = new OptionsScene();
            shipSelectScene = new ShipSelectScene();
            inventoryScene  = new InventoryScene();
            mapScene        = new MapScene();
            controlScene    = new ControlScene();
            rankScene       = new RankScene();
            gameOverScene   = new GameOverScene();
            winScene        = new WinScene();

            CurrentScene = menuScene;
            changeTo     = menuScene;

            changeSceneTimer = 40;

            GameObjects = new List <GameObject>();
            for (int i = 0; i < Options.StarChance * 10; i++)
            {
                GameObjects.Add(new Star(new Vector2(Globals.Randomizer.Next(5, Globals.ScreenSize.X - 5), Globals.Randomizer.Next(5, Globals.ScreenSize.Y * 2))));
            }
        }
コード例 #2
0
ファイル: SceneManager.cs プロジェクト: kraban/Outer-Space
        public static void Initialize()
        {
            menuScene = new MenuScene();
            optionsScene = new OptionsScene();
            shipSelectScene = new ShipSelectScene();
            inventoryScene = new InventoryScene();
            mapScene = new MapScene();
            controlScene = new ControlScene();
            rankScene = new RankScene();
            gameOverScene = new GameOverScene();
            winScene = new WinScene();

            CurrentScene = menuScene;
            changeTo = menuScene;

            changeSceneTimer = 40;

            GameObjects = new List<GameObject>();
            for (int i = 0; i < Options.StarChance * 10; i++)
            {
                GameObjects.Add(new Star(new Vector2(Globals.Randomizer.Next(5, Globals.ScreenSize.X - 5), Globals.Randomizer.Next(5, Globals.ScreenSize.Y * 2))));
            }
        }