I have a forge server/client project setup in Eclipse and am running a vanilla server. I'd like to copy some structures my children have built in another vanilla world and modify them slightly (ie. change the scale, replace block types, etc) and place them in the new world. The end goal is to create large towns based on their "designs". Do I need to be looking at the source world mca files and processing them for the relevant data and then injecting that into my target world? I know of MCEdit but haven't used it. Would looking at that source code be a good place to begin?
You have a few different strategies you can follow depending exactly what you want to do.
http://www.mcedit.net/ is an OFFLINE editor (runs outside the game) of Minecraft worlds that allows you to easily copy and paste, edit, and write python scripts to filter and transform blocks.
https://github.com/sk89q/worldedit/ Is an ONLINE editor (runs within the game) of Minecraft worlds that allows you to easily copy and paste (Using schematics) run different commands to run different transformations / brushes, as well as writing javascript scripts, or hooking directly into it's API using Java.
This option requires creating custom world generation via a Mod, Plugin or DataPack
But you can create your own villages that generate naturally in the world.
Minecraft itself has limited support for this without any programming whatsover.
This feature is known as 'structures' and you can create custom structures and export them, for use within DataPacks by using the structure block.
Additionally, if you are creating a mod, the structure block is the easiest way to export buildings from your kids for inclusion in random generation.
Changing scale will be tricky, but you could totally filter the blocks, and save out multiple schematics/structures or else programmatically replace some of the blockstates.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With