Example #1
0
        // External
        public Chunk GenerateChunk(Vector2DI inChunkPos)
        {
            Chunk.Data newChunkData = _chunkDataGenerator.Generate(inChunkPos);

            Chunk newChunk = new Chunk(newChunkData, _world);

            return(newChunk);
        }
Example #2
0
            // Exposed
            public Chunk.Data Generate(Vector2DI inChunkPos)
            {
                Chunk.Data newChunkData = new Chunk.Data(inChunkPos);

                NoiseGenerator.Output   chunkNoiseData   = _noiseGenerator.Generate(inChunkPos);
                TileMapGenerator.Output chunkTileMapData = _tileMapGenerator.Generate(inChunkPos, chunkNoiseData);

                newChunkData.SetTiles(chunkTileMapData.tiles);

                return(newChunkData);
            }