Browse Source

World: add Tiles to list so that they're sorted by x-coordinate

GitOrigin-RevId: f9c6cf8be4
master
Colin McMillen 4 years ago
parent
commit
644ed88dd8
  1. 4
      Shared/World.cs

4
Shared/World.cs

@ -110,8 +110,8 @@ namespace SemiColinGames {
Width = worldDesc.AsQueryable().Max(a => a.Length);
Height = worldDesc.Length;
Debug.WriteLine("world size: {0}x{1}", Width, Height);
for (int j = 0; j < Height; j++) {
for (int i = 0; i < Width; i++) {
for (int i = 0; i < Width; i++) {
for (int j = 0; j < Height; j++) {
Terrain terrain = Terrain.Empty;
if (i < worldDesc[j].Length) {
switch (worldDesc[j][i]) {

Loading…
Cancel
Save