Also tested and functional on version 2022.3.62f2 of the editor.
LIVE DEMO available here
TerrainGen is a powerful, deterministic procedural terrain generation system for Unity, allowing developers to create infinite, fully customizable worlds with multiple biomes, dynamic vegetation, modular structures, and integrated navigation and pathfinding systems.
The system generates infinite terrain using noise-based algorithms. Terrain loads dynamically around the player or camera position at runtime. Multiple biomes can be created, each supporting custom materials, height multipliers, and surface levels. The terrain is generated automatically with full collision support.
Rivers can be generated with configurable depth, width, and erosion parameters.
Vegetation and objects spawn intelligently based on biome-specific rules. The system supports trees, grass, general objects and far object with different render distances. Spawn probabilities, distances, object limits, and more are fully configurable.
Grass and far object rendering uses Unity's Graphics.DrawMeshInstanced and Frustum culling for high performance. Grass density, height constraints, and surface angle limits are all configurable.
Structures can be placed as prefabs with automatic terrain adaptation. Structures can carve terrain in hollow mode or anchor to terrain height. Spawn rules include spacing, biome restrictions, and unique instance options.
A built-in A* pathfinding system works across the generated terrain. Navigation grids are generated automatically per terrain tile. Walkable surface angles and height constraints are configurable.
Editor tools include a scene creator for quick setup, a terrain preview window for visualization, automatic tag setup, and biome visualization gizmos.
The system is highly customizable and suitable for open-world games, survival games, RPGs, simulation games, and sandbox games. All components are modular and configured through ScriptableObjects and Inspector settings.
Comprehensive documentation with examples is included, along with a demo scene for quick start build in URP.
Important Notes:
This asset includes a set of demo graphical assets (models, textures, materials, and prefabs) created for this asset. No third‑party visual assets are included; details and inventory are provided in the ASSETS_LICENSE_INFO.md file inside the package.
The terrain generation system uses a third‑party noise library (FastNoiseLiteBurstCompatibleForUnity), which is distributed under the MIT license. License information and credits are documented in the included THIRD_PARTY_NOTICES.txt file.
For support or inquiries, please contact me at guillaume.marrec.frey@proton.me. I am happy to help with any problems or concerns.