We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 520a9bd commit 182e276Copy full SHA for 182e276
fCraft/MapConversion/MapMCF.cs
@@ -29,14 +29,12 @@ public override Map Load( string fileName ) {
29
Map map = LoadHeaderInternal( gs );
30
map.Blocks = new byte[map.Volume];
31
32
- int i = 0, lo, hi;
33
- while ((lo = gs.ReadByte()) != -1) {
34
- hi = gs.ReadByte();
35
- int id = lo | (hi << 8);
+ int i = 0, id;
+ while ((id = gs.ReadByte()) != -1) {
+ gs.ReadByte(); // NOTE: This breaks the 5 block ids past 255, but I doubt they really had much use.
36
37
if (id <= (byte)Block.StoneBrick) map.Blocks[i] = (byte)id;
38
- else map.Blocks[i] = Mapping[id & 0xFF];
39
- // NOTE: This breaks the 5 block ids past 255, but I doubt they really had much use.
+ else map.Blocks[i] = Mapping[id];
40
i++;
41
}
42
return map;
0 commit comments