Structure
Project Scenes
Demo : the main optimized demo scene of the project (read more about scene structure here).
Demo Mono : the new demo scene of the project, which contains an example of traffic & NPCs fully interacting with monobehaviour scripts (v1.1.0+).
Demo source : same as Demo scene, but contains raw 3D models without optimization, also scene streaming objects are disabled, including static physics colliders.
RuntimeTile Road Demo : sample scene showing how to create a city builder based on tiles (runtime spline can be used with Road Constructor plugin). (new)
RuntimeTile Road Mobile Demo : sample scene showing how to create a city builder based on tiles [mobile version]. (new)
Runtime ChunkRoad Demo : sample scene demonstrating the road chunks added at runtime. (new)
Runtime CustomRoad Demo : sample scene to demonstrate the use of the API to generate run-time roads from Unity spline roads or from custom data. (new)
Runtime RawData Demo : sample scene that demonstrates the generation of a road from raw data at runtime. (new)
Custom Train Demo : an example of how a 3rd party train solution can be integrated. (new)
Traffic test scene : traffic test scene where all parameters can be tested with a set of most traffic situations.
Pedestrian test scene : pedestrian test scene where the workability of entities can be tested.
Props test scene : props test scene where the workability of entities can be tested.
City stress scene : stress scene that combines thousands of vehicles and pedestrians.
City stress scene mobile : mobile version of City stress scene.
Traffic stress scene : stressed scene is extremely crowded with vehicles.
Traffic stress scene mobile : mobile version of Traffic stress scene.
Pedestrian stress scene : stressed scene is extremely crowded with pedestrians.
Pedestrian stress scene mobile : mobile version of Pedestrian stress scene.
Pedestrian animation stress scene : performance scene comparison between Unity Animator animations and GPU animations.
Vehicle physics stress scene : stress scene for the thousands cars with Custom vehicle controller.
Vehicle custom physics test scene : scene for testing various parameters of the Custom vehicle controller.
Scene Hierarchy
Main scene.
City debugger : contains all the debuggers for the city.
Hub : contains the Entity Subscene Generator (read more on how to create it).
City Settings Initializer : contains the General Settings of the DOTS city [moved to the Config tab].
Main scene configs (read more about the config editing workflow).
Pools : contains all the entity presets.
Spawnpoint : spawnpoint of the player (assigned in the PlayerSpawner if built-in solution in use).
Subscene (EntitySubScene) : subscene into which all of the entities are converted (generated by the Entity Subscene Generator).
Subscene configs (read more about the config editing workflow).
EntityRoadRoot : object root generated by the Entity Subscene Generator.
Road : road parent (read more about the road editing workflow).
Scene Components
Road Parent
The root of all crossroads in the scene.
How To Use
Read more in the Road Network Workflow section.
Settings
- Connection waypoint offset
Automatically adds a waypoint at each selected offset to the automatically created paths (if the value is greater than zero).
- Cast distance
Raycast connection distance between Traffic nodes. If set to zero, the value is infinite.
- Multi angle raycast
Multi-angle raycasting along the Z-axis.
- Connect crosswalks
Auto-connect Pedestrian node crosswalks.
Utils
- Add crossroads
Adds a scene crossroad if it is missing.
- Connect pedestrian nodes
Automatically connects pedestrian nodes that have auto-connection configured.
- Clear unattached paths
Deletes the paths that are not connected to any TrafficNode.
Entity Subscene Generator
Where To Find
How To Use
Read more in the Road Entity Subscene section.
Settings
- Entity subscene save path
Save path of the subscene.
- Entity subscene name
Name of the subscene.
- Autosync configs
On/off auto-sync config on the main scene & subscene.
- Move tools
On/off moving of the following tools: PedestrianNode Creator, RoadSegmentPlacer.
- Move lights
On/off moving of the subscene lights.
- Move props
On/off moving of props.
- Move surface
On/off moving of the selected physics surface.
- Copy physics shapes
On/off feature of physics shape cloning.
Config
- Copy to subscene
The subscene configs will be synchronized with the main scene.
- Copy from subscene
The main scene configs will be synchronized with the subscene.
Buttons
- Generate
Generates the subscene.
- Move back
Move the road from the subscene to the main scene (can be useful for editing roads in the main scene due to Editor performance).
PedestrianNode Transfer Service
Tool for cloning Pedestrian nodes that are part of the prefab from the main scene to the subscene.
Note
For example, can be useful to separate the Building prefab asset and its attached Pedestrian nodes.
How To Use
Automatically used by the Entity Subscene Generator.
PhysicsShape Transfer Service
This tool only works for DOTS if the DOTS simulation type is selected in the General Settings.
Tool for cloning physical shapes from the main scene to the subscene.
There is also a tool to maintain both the default physical world and the DOTS physical world at the same time, so that default colliders and DOTS colliders exist at the same time if you need to use default colliders in MonoBehaviour classes.
- Current project use cases:
Keep default colliders to work with Legacy ragdoll.
Cloning of physical shapes from the main scene to split them into subscene pieces by using SubSceneChunk Creator or cloned into the main subscene by using Entity Subscene Generator.
Note
The tool can only use one tool at a time, either an Entity Subscene Generator or a SubSceneChunk Creator.
Settings
- Clean components
Removes all components from the physics shape.
- Clean childs
Removes all childs from the physics shape.
- Search type
Searching shapes by layer or tag.
- Proccesing type
Stay previous : cloning found PhysicsShape or Collider to subscene, useful to keep default collider and Unity.Physics collider running at the same time.
Disable collider : cloning found PhysicsShape or Collider to subscene and disable it in the main scene.
- Preinit layer
Enable pre-init cull state for physics objects.
- New layer
Assigns new layer for cloned shape.