Implemented Importing and Exporting Tile Entities; Additional Improvements #41

Merged
SenseiKiwi merged 15 commits from master into master 2013-07-15 22:08:53 +00:00
Showing only changes of commit d21f29ec2c - Show all commits

View File

@@ -488,10 +488,11 @@ public class DungeonHelper
//Get the tile entity's description as a compound NBT tag //Get the tile entity's description as a compound NBT tag
NBTTagCompound entityData = new NBTTagCompound(); NBTTagCompound entityData = new NBTTagCompound();
tileEntity.writeToNBT(entityData); tileEntity.writeToNBT(entityData);
//Change the tile entity's location to be relative to (xMin, yMin, zMin) //Change the tile entity's location to the schematic coordinate system
entityData.setInteger("x", entityData.getInteger("x") - xMin); entityData.setInteger("x", x);
entityData.setInteger("y", entityData.getInteger("y") - yMin); entityData.setInteger("y", y);
entityData.setInteger("z", entityData.getInteger("z") - zMin); entityData.setInteger("z", z);
tileEntities.appendTag(entityData); tileEntities.appendTag(entityData);
} }
} }