示例#1
0
        /// <summary>
        /// Creates a new level screen
        /// </summary>
        /// <param name="game">Game to bind to</param>
        /// <param name="data">Level data</param>
        public LevelScreen(Game game, Level data)
            : base(game)
        {
            _levelData = data;
            _camera = new Camera2D(game);
            _background = new Layer(game, _camera);
            _foreground = new Layer(game, _camera);
            _overlay = new Layer(game);

            this.Exited += new EventHandler(LevelScreen_Exited);
        }
示例#2
0
文件: Layer.cs 项目: thexa4/ticktick
 /// <summary>
 /// 
 /// </summary>
 /// <param name="game"></param>
 /// <param name="camera"></param>
 public Layer(Game game, Camera2D camera)
     : this(game)
 {
     this.Camera = camera;
 }