HOW-TO: Import and export terrain tiles
Learn how to export and import your terrain tiles from other projects or in some cases, even from external tools.
Export terrain tiles
Here’s how you can export some or all of your tiles.
Open the Terrain Edit Tools.
You can export terrain by selecting either a specific selection of your tiles or all of your tiles. Don’t have any yet? Create your terrain tiles (if you haven’t already), and assign a material for them in the Material tab:
It’s important to keep in mind the resolution and LOD config that you are currently using, as it will be important to have your exported and imported tiles in the same resolution and settings later!
You can select the tiles that you want to export by either individually selecting by Ctrl + LMB or by choosing the Select all tiles button at the bottom left corner of the Terrain edit dialog.
Once you have your tiles selected, head on over the Import / Export tab and at the middle, under the Export Tiles button, select the Heightmap and colormap mode, then click on the Export Tiles button.
In the Open-File-Dialog select the desired location for your exports. Once the editor is done exporting the tiles, you will see the following structure at your export path location:
t_output.csv: The filename may vary based on the name you gave at the Open-File-Dialog. This file is responsible for stating the offset and resolution of the exported tiles at the very top row. e.g. 0 - 0 - 32 - 32
Where each digit does the following from left to right:
There is 0 offset on the X axes. This number can be added to each tile's x coordinate as an offset value.
There is 0 offset on the Y axes. This number can be added to each tile’s y coordinate as an offset value.
The next two digits is basically the resolution X, Y axes wise. So the resolution is 32x32.
The rest of the rows are exact path info of all the exported tiles:
The two folders above the csv file,
<filename>_input: Here you can add all the tiles that you want to import into the engine.
<filename>_output: This is the place where all the exported tiles are located, each tile is in a png format, where the name states the x and y coordinate of the current tile.
Import terrain tiles
Imagine you have another project with an empty world, but you want to import all of the tiles exported from the previous one to import full terrain.
1. Open the Terrain Edit Tools,
Remember to set the exact same LOD config and resolution options as it was in the previous project.
Then select Import full terrain. Now select the folder where all the exported tiles are located from the previous project, so that we can import them in here:
You’ll be presented with the following dialog stating with some information before the import process:
Click on Yes and wait until the process if finished.
If you only want to import some of the tiles but not all of them from a previous world next to your already existing terrain, put the tiles that you want to import inside the <filename>_input folder, then navigate to the Import / Export tab, and select Import Tiles.
Then select the previously exported .csv file that is located next to the <filename>_input folder.
Table of contents:
______________________________________
The Witcher 3: Wild Hunt Complete Edition © 2024 CD PROJEKT S.A. Published by CD PROJEKT S.A. Developed by CD PROJEKT RED. CD PROJEKT®, The Witcher®, REDengine® are registered trademarks of CD PROJEKT Capital Group. All rights reserved. The Witcher game is set in the universe created by Andrzej Sapkowski in his series of books. All rights reserved.