Пример #1
0
        private void Init()
        {
            var tileCodes = LoadLevelTileCodes();

            AllTiles = new TileGrid(tileCodes);

            Sprites = new SpriteGrid(tileCodes);

            Graph = new LevelGraph(AllTiles);
        }
Пример #2
0
        public Player(LevelGraph graph)
        {
            _graph = graph;

            var cm = GameServices.GetService <ContentManager>();

            _font = cm.Load <SpriteFont>("Fonts/Arial");

            _pacmanSprite = new AnimatedSprite("pacman", Frames, 0.05f);
        }