コード例 #1
0
        public Multiverse(HughGame game, TmxMap map)
        {
            HasWon  = false;
            HasDied = false;

            Game           = game;
            UniverseLayout = map.Properties["layout"];

            BorderTexture = new Texture2D(game.GraphicsDevice, 1, 1);
            BorderTexture.SetData(new[] { Color.Black });

            LayoutHeight = CountChars(UniverseLayout, ';');
            LayoutWidth  = CountChars(UniverseLayout, '|') / LayoutHeight + 1;

            for (int i = 1; i <= LayoutHeight * LayoutWidth; i++)
            {
                Worlds.Add(new World(game, map, i));
            }
        }
コード例 #2
0
 public TilesetManager(HughGame game)
 {
     Game        = game;
     TmxList     = new List <TmxTileset>();
     TextureList = new List <Texture2D>();
 }