Independent game developers - making Avoyd


en  fr

Support our work on Avoyd and open source software through Github Sponsors or Patreon
Sponsor Doug Binks and Juliette Foucaut on Github  Become a Patron

Importing Minecraft maps in Avoyd Voxel Editor improved

Doug Binks - Juliette Foucaut - 25 Feb 2021


Our Avoyd Voxel Editor has come a long way since the last devlog post about it in 2018, and having just released a significant update which enhances the Minecraft import pipeline this seems like as good a time as any to talk about it once again.


Minecraft maps Greenfield city and Cuirassé DSD-401 by MrBatou imported and combined together in Avoyd voxel editor Minecraft maps Greenfield city and Cuirassé DSD-401 by MrBatou imported and combined together in Avoyd's Voxel Editor.


As many of you know, in addition to making the Avoyd game free to download, we make the Avoyd Voxel Editor which is bundled with it. As well as being the tool we use to build everything in the game, the editor can import Minecraft maps, MagicalVoxel files, Slab .vox files, heightmaps, and export to Wavefront .obj vertex data (for use as general 3D data in tools like Blender 3D). So it's a usable general voxel tool designed to work with large voxel models/worlds.

In october 2020 we started to see one of our early Minecraft import videos featuring Westeroscraft's King's Landing gain a large (for us) number of views, all down to a Lazy Assassin Youtube video "10 SHOCKING THINGS THAT ARE MADE IN MINECRAFT! 😱😱".

I decided to make an updated video with some new content, and set off to download a new map I'd heard of - Greenfield City - and try it out. This turned out to be in a new Minecraft map format which I didn't support in the enki Minecraft Import library enkiMI, so a small step turned into a journey down a long and winding road. The views along the way were, however, pretty sweet.


Video showing the result of our work: large Minecraft maps loaded into Avoyd, featuring

Music: 'Just a Suggestion' by nervous_testpilot


Minecraft 1.13+ new voxel data format

Version 1.13 of Minecraft Java Edition introduced a new format for the base voxel data which had previously been stored as a simple 3D array of bytes per chunk section (a chunk section is a 16x16x16 volume), with optional extra arrays for extended data. The new format has a palette of string named block types per chunk section, and then a variable width array of bitstream data indexing the palette (with the format changed in 1.16 so that voxels were stored on 64bit boundaries for performance reasons). Additionally, block types no longer have an integer id, and are known by their namespaced string name. Currently the enkiMI library only supports a default set of Minecraft block types, and returns a byte id per block. In future, I hope to have time to expand this to allow the full palette blocks of any map to be read.

Loading large Minecraft maps faster by multithreading the octree construction

Whilst I was testing the importer changes, I became frustrated with the performance of loading large Minecraft maps. Whilst most of the testing could be done with portions of the data, I had found some cases where the region files (individual files of data in the region folder of a Minecraft map) had variations on the tagged format I was expecting, so it was important to test against a wide range of data. The easiest solution was to move the file processing to a multithreaded operation by threading the loading of each region file, which I did using enkiTS, my open source permissively licensed C and C++ Task Scheduler for creating parallel programs.

Since Avoyd uses a single octree to represent each model, care needs to be taken with the multithreaded construction. Since inserting one octree into another is a fast operation for my octree, even whilst deduplicating the data (I use a reference counted directed acyclic graph sparse voxel octree), I build small octrees from the Minecraft data on multiple threads and then insert them on one thread only. The canonical approach to synchronization with enkiTS is to avoid it entirely and use a combination of 'pinned tasks' (tasks which run on only the assigned thread) and dependencies, but in this case a simple lock proved the easiest approach and profiling showed no contention even on a 36 thread CPU. On my 18 core 36 thread CPU the Minecraft map importer was over 16x faster than before.

Material palette: average colours and specular

Meanwhile, we updated the default Minecraft material palette to complete the range of material colours. Avoyd does not use textures, but the materials used in Avoyd match the Minecraft default materials as closely as possible by basing their colour on Minecraft textures averages.

We also added appropriate Metallic and Smoothness parameters for improved specular lighting, something which really helps bring the loaded maps to light. The materials affected are: water, snow, ice, vegetation, metals, ores, gems, glass and glazed terracottas. Note that there is currently no emissive lighting in Avoyd.

Overall we're really happy with the changes to the Minecraft import pipeline so we decided to submit Avoyd Voxel Editor as a mod on PlanetMinecraft


Screenshot of Minecraft map Greenfield City rendered in Avoyd voxel editor, featuring the default materials derived from Minecraft textures averages and specular reflection on water, glass, metal and vegetation Greenfield City featuring the default materials derived from Minecraft textures averages and specular reflection on water, glass, metal and vegetation.

Greenfield City Minecraft map rendered in Avoyd voxel editor, stadium under construction showing specular lighting. Greenfield City Minecraft map rendered in Avoyd voxel editor, stadium under construction showing specular lighting.


Screenshot of Minecraft map Greenfield City rendered in Avoyd voxel editor and the Minecraft map import user interface. If you have ‘The Nether’ or ‘The End’ dimensions as well as the normal ‘The Overworld’, a pop-up will enable you to choose which dimension to import Minecraft map import pop-up which will open if you have ‘The Nether’ or ‘The End’ dimensions as well as the normal ‘The Overworld’, enabling you to choose which dimension to import

Screenshot of the entire King's Landing by Westeroscraft Minecraft map, rendered in Avoyd voxel editor King's Landing by Westeroscraft


Starter guide

If this is your first time using Avoyd's voxel editor, the tips below should help you get started.
Don't hesitate to contact us if you have questions.

How to import a Minecraft map into Avoyd

  • Download and install Avoyd
  • Avoyd can load your own maps (stored in %appdata%.minecraft\saves\), or download and save the Minecraft map to disk (extracting it if it is a zip file).
  • In Avoyd:
    • Open the Voxel Editor
    • Go to the menu File > Import > Minecraft Map (*.mca)...
    • Select the region file directory (containing .mca files) and Open to import.
    • If you have ‘The Nether’ or ‘The End’ dimensions as well as the normal ‘The Overworld’, a pop-up will enable you to choose which dimension to import.

How to explore a Minecraft map in Avoyd

  • Lock the camera to the horizontal 'Y' plane for Minecraft maps:
    • Open menu Tools > Camera...
    • Under Align To Axes
      • Tick Align Camera to Axes
      • Select the 'y' axis
      • Set the Axis Preference to 0.80 or above.
  • To move around:
    • Set the camera to "Movement" mode: press the Tab key or hold down the mouse right button
    • Move the mouse to look around
    • Press W to move forward
  • More about camera controls in the voxel editor's help menu:
    • Help > Tutorial... Cameras
    • Help > Controls Documentation... Camera Controls

Avoyd limitations for Minecraft and MagicaVoxel

  • From Avoyd you cannot re-export any edits back to Minecraft or Magicavoxel
  • Avoyd does not use textures, but the materials used in Avoyd match the Minecraft default materials as closely as possible:
    • Their colour is based on Minecraft textures averages
    • They have specular reflection where relevant (water, glass, metal...).
    • Note you can edit the 'Minecraft Default' materials individually from menu Tools > Materials... or from the Palette in Tools > Edit Tool....
  • There are no emissive lights in Avoyd as of version 0.7.5, though we intend to add them in the future

Tips and tricks

  • Once imported, save the Minecraft map as an Avoyd world file. This will enable you to open it faster and use it as a paste brush.
  • Check the size of the world and add notes from menu View > World Properties...
  • Tune the Graphics properties under Settings > Graphics. Increasing the ‘LOD change distance’ improves detail in the distance but reduces performance.
  • Learn the basics of editing in Avoyd: follow the step by step tutorial under menu Help > Tutorial...
  • All controls and keyboard shortcuts are listed in menu Help > Controls Documentation...
  • Make sure the tooltips are enabled by ticking View > Show Tooltips
  • Light or Dark mode UI, adjust font size etc. in menu Settings > Display...
  • For further help see Avoyd News and Support forums


Screenshot of Minecraft map Greenfield City in Avoyd's voxel editing tool, showing the editor's user interface with its Edit Tool selection; Light and Atmosphere settings; Minecraft default Materials used when importing the map; Cameras; the Replace material and Pick tools; as well as the Avoyd World file dimensions and notes. The user is doing a spherical cut and paste of part of the model. Using Avoyd's Edit tool to do a spherical cut and paste of part of the Greenfield map (click to enlarge)


Features of Avoyd Voxel Editor

  • Extremely long view distance
  • World / Model size up to 260k x 260k x 260k voxels
  • Light and atmosphere can be modified
  • Cameras: first person and arcball cameras, teleport and save multiple camera positions
  • Edit tools: add/remove individual voxels or shapes (sphere, box, etc.), paint, copy/paste, undo/redo etc.
  • Constraints and symmetry planes
  • Imports: Minecraft maps, Magicavoxel models, .vox, heightmaps from images, and Avoyd Voxel Models can be edited and mixed together
  • Export to .obj format for use in e.g. Blender 3D

Support our work on Avoyd and open source software through Github Sponsors or Patreon
Sponsor Doug Binks and Juliette Foucaut on Github  Become a Patron

 › 2021
 ›› Importing Minecraft maps in Avoyd Voxel Editor improved 
 › 2020
 › Runtime Compiled C++ Dear ImGui and DirectX11 Tutorial
 › 2019
 › Boxes in Space: procedural generation of abstract worlds in Avoyd
 › Procedural python word generator: making user names out of 4 syllables
 › In-game building
 › Player-deployable turrets in Avoyd
 › 2018
 › Avoyd Game Singleplayer and Coop Multiplayer Test
 › Voxel Editor Evolved
 › 2017
 › Speeding up Runtime Compiled C++ compile times in MSVC with d2cgsummary
 › Multiplayers toxic last hit kill and how to heal it
 › Avoyd Editor Prototype
 › 2016
 › Black triangles and Peter Highspot
 › Colour palettes and lighting
 › Concept art by Rebecca Michalak
 › 2015
 › Internals of a lightweight task scheduler
 › Implementing a lightweight task scheduler
 › Feral Vector
 › Normal generation in the pixel shader
 › 2014
 › Python Google App Engine debugging with PyCharm CE
 › Lighting voxel octrees and procedural texturing
 › Patterns and spheres
 › Python Google App Engine debugging with PyTools
 › Interview
 › Domain masking using Google App Engine
 › Octree streaming - part 4
 › Black triangles and nervous_testpilot
 › Presskit for Google App Engine
 › Octree streaming - part 3
 › Octree streaming - part 2
 › Octree streaming
 › 2013
 › LAN discovery with multiple adapters
 › Playing with material worlds
 › Developer Diary archive
 › Website redesign
 › First Person Editor
 › First Avoyd tech update video
 › Implementing a static website in Google App Engine
 › Multiplayer editing
 › First screenshots
 › Thoughts on gameplay modes
 › Back in 1999
 › 2002
 › ECTS 2002
 › Avoyd Version 1.6.1 out
 › Avoyd Version 1.6 out
 › 2001
 › Biting the bullet
 › Avoyd version 1.5 out
 › Monday Mayhem
 › Avoyd version 1.5 alpha 1 out
 › Avoyd version 1.4 out
 › ECTS 2001
 › Fun with Greek letters
 › Closer just a little closer
 › Back already
 › Artificial Humanity
 › Products and promises
 › Ecommerce
 › Explosions galore
 › Spring fixes
 › Open source and ports to other operating systems
 › Avoyd LAN Demo Version 1.1 is out
 › Thanks for the support
 › Avoyd LAN Demo Ready
 › Game Tech
 ›› Importing Minecraft maps in Avoyd Voxel Editor improved 
 › Runtime Compiled C++ Dear ImGui and DirectX11 Tutorial
 › Boxes in Space: procedural generation of abstract worlds in Avoyd
 › Procedural python word generator: making user names out of 4 syllables
 › Speeding up Runtime Compiled C++ compile times in MSVC with d2cgsummary
 › Internals of a lightweight task scheduler
 › Implementing a lightweight task scheduler
 › Normal generation in the pixel shader
 › Lighting voxel octrees and procedural texturing
 › Octree streaming - part 4
 › Octree streaming - part 3
 › Octree streaming - part 2
 › Octree streaming
 › LAN discovery with multiple adapters
 › enkiTS
 › Internals of a lightweight task scheduler
 › Implementing a lightweight task scheduler
 › RCC++
 › Runtime Compiled C++ Dear ImGui and DirectX11 Tutorial
 › Speeding up Runtime Compiled C++ compile times in MSVC with d2cgsummary
 › Web Tech
 › Procedural python word generator: making user names out of 4 syllables
 › Python Google App Engine debugging with PyCharm CE
 › Python Google App Engine debugging with PyTools
 › Domain masking using Google App Engine
 › Presskit for Google App Engine
 › Implementing a static website in Google App Engine
 › Avoyd
 ›› Importing Minecraft maps in Avoyd Voxel Editor improved 
 › Boxes in Space: procedural generation of abstract worlds in Avoyd
 › In-game building
 › Player-deployable turrets in Avoyd
 › Avoyd Game Singleplayer and Coop Multiplayer Test
 › Voxel Editor Evolved
 › Multiplayers toxic last hit kill and how to heal it
 › Avoyd Editor Prototype
 › Black triangles and Peter Highspot
 › Colour palettes and lighting
 › Concept art by Rebecca Michalak
 › Feral Vector
 › Patterns and spheres
 › Interview
 › Black triangles and nervous_testpilot
 › Playing with material worlds
 › Website redesign
 › First Person Editor
 › First Avoyd tech update video
 › Multiplayer editing
 › First screenshots
 › Thoughts on gameplay modes
 › Back in 1999
 › Avoyd 1999
 › Developer Diary archive
 › Back in 1999
 › ECTS 2002
 › Avoyd Version 1.6.1 out
 › Avoyd Version 1.6 out
 › Biting the bullet
 › Avoyd version 1.5 out
 › Monday Mayhem
 › Avoyd version 1.5 alpha 1 out
 › Avoyd version 1.4 out
 › ECTS 2001
 › Fun with Greek letters
 › Closer just a little closer
 › Back already
 › Artificial Humanity
 › Products and promises
 › Ecommerce
 › Explosions galore
 › Spring fixes
 › Open source and ports to other operating systems
 › Avoyd LAN Demo Version 1.1 is out
 › Thanks for the support
 › Avoyd LAN Demo Ready