Пример #1
0
 public Chunk(int offset, IWorldGenerator generator)
 {
     Blockstates = new byte[16, 256];
     Blocks      = new short[16, 256];
     for (var x = 0; x < 16; x++)
     {
         for (var y = 0; y < 256; y++)
         {
             Blocks[x, y] = generator.Generate(x + offset, y);
         }
     }
 }
Пример #2
0
 public override void Execute()
 {
     generator.Generate(this);
 }
Пример #3
0
 public void Generation(IWorldGenerator generator)
 {
     _world = generator.Generate(Width, Height);
 }
Пример #4
0
 public Rover(IWorldGenerator worldGenerator, Position position, Direction direction)
 {
     World     = worldGenerator.Generate();
     Position  = position;
     Direction = Direction.North;
 }