Example #1
0
		private void SetupDefaults()
		{
			Scene = new Scene();
			Viewport = Display.CreateViewport(0, 0, DefaultDisplayDimension.Width, DefaultDisplayDimension.Height);
			Display.BackgroundColor = Color.FromArgb(0xff, 0xff, 0xff, 0xff);
			Camera = new Camera();
			Camera.Prepare(Viewport);
			Viewport.Camera = Camera;
			Viewport.Scene = Scene;

			Actors = new ActorCollection();
		}
Example #2
0
File: Game.cs Project: Conn/Balder
        private void InitializeGame()
        {
            if( null == GameClass )
            {
                GameClass = new InternalGame();
            }
            Runtime.RegisterGame(Display, GameClass);

            Viewport = GameClass.Viewport;
            Scene = GameClass.Scene;
            if( null == Camera )
            {
                Camera = new Camera(GameClass.Camera);
            } else
            {
                Camera.ActualCamera = GameClass.Camera;
            }
        }