Guide on exporting buildings from the game
This text describes a feature added to Millénaire in version 1.7.6 that enables the player to export buildings created in-game as PNG building files in the format described in the main building-making guide.
As per version 2.4.6, the import/export system has changed quite a bit. Before this, it only used the summoning wand to do all the tasks. Now you need the summoning wand to import buildings and the negation wand to export buildings.
If you are interested in importing or exporting your building in a Millenaire version older than 2.4.6, then you should check the old guild, located at Guide on exporting buildings from the game (old).
Please take note, that the in-game messages might be a bit confusing, at least, all the way up to version 2.7.4. This is because the messages of the import functions have some textual errors in them. This will be explained later on.
Creating a plan
With the addition of the Negation wand, exporting has become quite simple and intuitive. After you've created your building, you need to place a (free standing) sign at the north-west corner of your building. North-west in this case, would be like how it is in real life, where the sun is rising in the east. (This is unlike how it was in the old system, where you had to obey the Minecraft north.)
On the sign, you need to enter the following text.
On the first line, enter the name of the building plan. This will be the filename of your building plan and doesn't need to be the real in game name, but is more of a system name if you will.
The second line seems to have no function for exporting.
On the third line, you can specify the lowest level of your building. This is optional though. The default is -1 meaning that is saves only one block beneath the sign, so if you want to include a basement or other kind of underground structure then make sure the block where the sign is placed is exactly one block above where you want to save.
That's all you need to do on the first sign.
Now place two more signs, one on the southern edge of your building and one on the eastern edge of your building, again according to the real-life north, east, south and west. Make sure that they are within a straight line to the original sign and should probably be on the same height as well. These signs do not need any text on them. The only condition is that they are within 256 blocks of your main sign. This limit is hard-coded and does mean that your buildings can never be bigger than 256 x 256 blocks.
Now, head back to the first sign and use the Wand of Negation on it.
If all went well, it will give you a message "Exported building as <name>_A<number>.png". The corresponding plan is now located in millenaire-custom/exports.
Handling of upgrades
If a building plan of the name indicated already exists in the exports directory, Millénaire will generate a building upgrade instead, by exporting only differences found between the building in-game and the plans previously exported.
Limits of the tool
Note: This section is copied over from the old guide and hasn't been tested if it's still true.
It is not possible to set "active" block types using the exporter (like the main chest, the standing position, spawn points...). Those must be added manually to the PNG file. Also, extra settings in the text file (like NPC types residing in the building) have to be added by hand.
Importing a plan
In a similar way to the exportation of plans, you can import a plan from millenaire-custom/exports (simply copy a building plan from one of the existing cultures to be able to import it). With the current system, you can use the same sign you've used before. For importing, you will need to use Village wand instead of the Wand of Negation.
Simply place down a sign on the ground where you want the north-west corner of your building to be. The text that you can place on the sign is as follows.
On the first line, put the building's name. If you are unsure on what the name is, simply use the name of the text file of the building you're going to import and strip off the "_A.txt" part.
On the second line, you can specify the upgrade level you want of the building. If you do not give any, then it will use the initial construction, or level 0.
On the third line, the importer only checks for "x2". If it isn't there, then it ignores anything that is on that line. What x2 does, is double the height of the building, doubling every layer it encounters in the building plan. Be careful though, the x2 tag does not seem to be supported by the export function, so leaving it in place and using the Wand of Negation might throw you an error message.
When you're done, use the Village wand on the sign and your building should appear out of thin air.
If it doesn't, you will most like get an error message. These will be explained in the section below.