TheDuckCow/godot-road-generator
GDScriptA Godot plugin for creating 3D highways/streets and lane-following traffic
Godot Road Generator
A Godot plugin for creating flexible 3D highways and streets with traffic support
Version Support
:warning: This project is not feature complete yet!
See upcoming milestones.
| Branch | Plugin version | Godot Support |
|---|---|---|
| main | 0.9.1 | 4.4+ |
| dev | Next release | 4.4+ |
| godot4.3 | 0.9.0 | 4.3+ |
| godot3 | 0.6.0 | 3.5-3.6 |
The main branch always matches the current release, which is why main may look inactive. All new development occurs in the dev targeting the Godot version listed above. When a release is ready, the dev branch is merged into main.
How to install and use
Install by going to releases and downloaded the latest release, or get it from the Godot Asset Store (Godot 4.7+, version may lag a few days from the release due to review). Copy at least the addons/road-generator subfolder into your project, and optionally the demo_roads folder.
To get started, follow the Getting Started tutorial here. View demo usage by opening the road_demos/demo_menu.tscn scene, and navigating to any of the connected demo scenes - the "Museum" scene being a good starting place.
Finally, check out the wiki pages for more detailed usage.
What problems this addon solves
Without this plugin, Godot users have a few ways to create roads:
- Use a CSGPolygon following a path
- Simple to use and requires no plugins, but has many limitations
- You need a custom material for every lane combination (1 way street, 2 lane road, multi lane highway)
- No way to transition from one lane count to another
- No easy way to create intersections without fiddly geometry placement
- Largely impossible to avoid mesh gaps between different segments of CSG nodes, and inherent limitation
- Hand-model roads in a 3D modelling software
- This requires additional skills
- Not being dynamic, greatly limits the iterative nature of game development
- Additional file and project management
- Use an asset pack that comes with Road Segments
- Typically limited to square-tile road layouts
- For non grid-based packs, you then have to deal with how to properly line up track pieces
- Hard to customize the pre-baked materials to fit another visual styles (back to point 2 above)
- Write code to generate custom geometry
- It should go without saying, this is extra work! And this is exactly what this plugin aims to provide
In addition to each point above, each scenario requires you to design your own AI traffic system to follow your roads. Furthermore, even when comparing to road generators for other game engines, they lack features to create fine tuned lane shapes such as dynamic lane changes and settings based on discrete cross-sections. They also tend to focus on editor creation and lack functionality necessary for in-game, procedural use cases.
High level Features
| Feature | Demo |
|---|---|
| Cross-section based geometry. The many settings of RoadPoint's smoothly interpolate from one point to the next. Lane-control gizmo adjusts lane count, per RoadPoint or (holding shift) per entire RoadContainer. | ![]() |
| RoadContainer scene organization. Group sibling RoadPoints, and snap together with other RoadContainers. Save a RoadContainer to a scene for reuse. | ![]() |
| RoadPoint inspector panel. Define lane width, shoulder, and more. Hold shift to affect all RoadPoints within same container. | ![]() |
| Click-to draw with collision snapping. Fine tune placement after using native 3D gizmo as needed. | ![]() |
| Procedural intersections. Dynamically connect RoadPoints to create RoadIntersections. Supports non-planar setups. (RoadLane/edge curve support coming soon) | ![]() |
| Prefab intersection RoadContainers. Snap together built-in four way, three way, and highway on/off ramps with ease. | ![]() |
| Terrain3D integration. Flatten terrain to meet the level of your roads with options for margins and falloff. Format extendable for other terrain generators too. | ![]() |
| Multi-material support. Separate surface and underside materials per RoadContainer. Source trim-sheet provided to guide creation of customized materials. | ![]() |
| Auto-generated AI paths. Enable for automatic RoadLane placement, or hand place in your scene. Use the RoadLaneAgent helper to help agents follow roads, handling transitions between segments. | ![]() |
| Decoration edge curves. Once enabled on a RoadContainer, add CSG path geometry or make your own scripts to instance assets along left, right, and center curves. | ![]() |
| Runtime-available functions for procedural use. Operations apply on single RoadSegments at a time to be performant. | ![]() |
| Export RoadContainers to gLTF/glb. Output sections of your road network to edit further in a 3D software, without exporting your whole scene. | ![]() |
| Support for custom-made meshes. Turn off "Create Geo", then drop in your own meshes + colliders. AI paths remain connected. | ![]() |
| GDScript-only (for now). No extra compiling or dependencies to worry about. | ![]() |
Credits
This addon is distributed under the MIT license.
It was developed by Moo-Ack! Productions as a part of the "Wheel Steal" game project. We poured a lot of effort, time, and money into making this an intuitive, highly functional addon - and we chose to give it away for free to the Godot community.
You can share you appreciation by:
- Following or sharing the game project on Bluesky or Instagram
- Joining the Wheel Steal discord
- Becoming a Patron of the project (see special Roadside Support tier for hands on support)
Major contributions by bdog2112, antonkurkin, NoJoseJose, Picorims, and more here.
Logo designed by Kenney.
Games made with the Road Generator
Want to include yours? Create an issue!
- Wheel Steal Game - procedural use case
- Wheelie Big and Small - procedural use case
- Makin'Paper / Racin'Paper - editor created tracks
Future plans
All development ideas are added as enhancement issues here. All prioritized issues are part of milestones defined here.
Contribution
Contributions are welcomed! See the contributing guide for all the details on getting started. It's a good idea to join in the discord if you can, or at least start an issue conversation, before jumping head first into the code. Maintainers will help guide your approach and make sure no effort is wasted.













