From 5e8a1710dc5955751179e3d673123989ccb84cc9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Tue, 4 Feb 2014 21:22:36 +0100 Subject: [PATCH] convert tile ID 0 for RAED compatibility --- OpenRA.Utility/LegacyMapImporter.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/OpenRA.Utility/LegacyMapImporter.cs b/OpenRA.Utility/LegacyMapImporter.cs index 191aaadcd3..30262b8902 100644 --- a/OpenRA.Utility/LegacyMapImporter.cs +++ b/OpenRA.Utility/LegacyMapImporter.cs @@ -240,7 +240,10 @@ namespace OpenRA.Utility for (int j = 0; j < mapSize; j++) for (int i = 0; i < mapSize; i++) - map.MapTiles.Value[i, j].Type = ms.ReadUInt16(); + { + var tileID = ms.ReadUInt16(); + map.MapTiles.Value[i, j].Type = tileID == (ushort)0 ? (ushort)255 : tileID; // RAED weirdness + } for (int j = 0; j < mapSize; j++) for (int i = 0; i < mapSize; i++)