mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 17:57:38 +00:00
Merge pull request #35 from Gerrygames/master
fix NPE when reading sponge schematics with tile entities or entities
This commit is contained in:
commit
be41e8dea0
@ -210,6 +210,7 @@ public class SpongeSchematicReader extends NBTSchematicReader {
|
|||||||
});
|
});
|
||||||
streamer.readFully();
|
streamer.readFully();
|
||||||
if (fc == null) setupClipboard(length * width * height, uuid);
|
if (fc == null) setupClipboard(length * width * height, uuid);
|
||||||
|
else fc.setDimensions(new Vector(width, height, length));
|
||||||
Vector origin = min;
|
Vector origin = min;
|
||||||
CuboidRegion region;
|
CuboidRegion region;
|
||||||
if (offsetX != Integer.MIN_VALUE && offsetY != Integer.MIN_VALUE && offsetZ != Integer.MIN_VALUE) {
|
if (offsetX != Integer.MIN_VALUE && offsetY != Integer.MIN_VALUE && offsetZ != Integer.MIN_VALUE) {
|
||||||
@ -242,7 +243,6 @@ public class SpongeSchematicReader extends NBTSchematicReader {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
fc.setDimensions(new Vector(width, height, length));
|
|
||||||
clipboard.init(region, fc);
|
clipboard.init(region, fc);
|
||||||
clipboard.setOrigin(origin);
|
clipboard.setOrigin(origin);
|
||||||
return clipboard;
|
return clipboard;
|
||||||
|
Loading…
Reference in New Issue
Block a user