Пример #1
0
        public void Initialize(Game1 setGame, ContentManager setContent, Rectangle setWorldRect, Rectangle setCameraRect, GraphicsDevice graphics)
        {
            game = setGame;
            cutscene = new Cutscene();
            worldRect = setWorldRect;
            cameraRect = setCameraRect;

            content = setContent;

            drawRect = new Rectangle(0, 0, 0, 0);

            layerTextures = new Texture2D[8];
            
            tileRenderTarget = new RenderTarget2D(graphics, worldRect.Width, worldRect.Height);

            drawLayer = new bool[8];
            tileLayer = new bool[8];

            camera = new Camera2D(new Viewport(cameraRect), worldRect);

            worldIndex = 0;

            LoadWorld(worldIndex);
        }
Пример #2
0
 static void Main()
 {
     using (var game = new Game1())
         game.Run();
 }