Easyroads3D V2 Manual 1. Quick Start
6. General Settings
1. Import the EasyRoads3D package in your project. More Info... 2. You will see a new menu item "EasyRoads3D" in the top horizontal menu under GameObject > Create Other > EasyRoads3D. Select "New EasyRoads3D Object" from the EasyRoads3D menu. In the window that will appear you can select the object type and you can set the name for the new object. Select "Road Object" as the object type and optionally change the name that is displayed by default. More Info... A new EasyRoads3D road object with the name you entered is created in the scene hierarchy. It will be selected automatically and in the Inspector you will see the EasyRoads3D Toolbar. More Info... 3. Select the most left "Add Markers" tab, hold the [Shift] key and click in scene view on the terrain where you want to start the road. Continue adding markers by holding the [shift] key and clicking in scene view on the terrain defining the shape of the road. These are the control points that will define the shape of the road. After placing 3 markers they will start to connect. The white surfaces represent the shape to which the terrain will be adjusted. The road mesh itself will also become visible. Please click here if at this stage you cannot see the road and white surface mesh. More Info... 4. Click the middle mountain (Level terrain) tab in the above toolbar to start deforming the terrain heightmap according the road shape. This may take a while depending on the road shape, length and the terrains heightmap resolution. When finished, the white surfaces will disappear and the terrain will match the road mesh. You have created your first road with EasyRoads3D! You can now tweak the final build settings for the road and the terrain. Or you can click the middle mountain tab again to switch back to Edit Mode and add more markers, Insert Markers or tweak marker specific settings (Full version & Pro only). After getting familiar with all these road specific features it is time to start with the Side Objects features. (Full version & Pro only) For this it is recommended to have a close look at the demo project. It includes various type of ide objects. You can see how they are build in the Side Object Manager and how they are used in the scene regarding marker specific settings and side object specific Inspector settings.
DOWNLOAD FILES FROM www.unityterraintools.com The zip file contains the following items: 1. EasyRoads3D.unityPackage
ADD THE EASYROADS3D TOOL TO YOUR PROJECT This applies to packages downloaded from our website. Assetstore packages should directly import. Menu > Assets > Import Package > Custom Package... This will open the file dialog window. Browse to the EasyRoads3D folder and select the EasyRoads3D.unityPackage.
All necessary assets will be imported in your project. A new menu item EasyRoads3D will be available in the top horizontal menu under GameObject > Create Other > EasyRoads3D. Click on an empty area in the top menu bar to update it, if the EasyRoads3D menu is not yet visible in that sub menu. After creating your first road object and selecting this object you will be asked to enter license info:
You can find the EasyRoads3D Menu in the top horizontal menu under GameObject > Create Other > EasyRoads3D 1. New EasyRoads3D Object
Select this menu item to add a new EasyRoads3D road object to the scene. A dialog window will appear where you can set the name of the new object and select the type of EasyRoads3D object, road or river. After clicking the "Create Object" button the new EasyRoads3D object will be added to the scene. After the road object is created some other processes are executed. A temporary script will be attached to all terrain objects. This script is used to identify the terrain. Backups of the original terrain height data and splatmaps will be save in the folder EasyRoads3D/<terrainid> and can be used at any time to restore the terrain at any stage to its original state. 2. Backup Terrain Height Data (Full version & Pro only) Execute this option to update the terrain height data backups after making changes to the terrain. You will always have a fresh backup of the terrain height data! 3. Restore Terrain Height Data (Full version & Pro only) Execute this option if you want to restore the terrain height data to its original state. Terrain height data is automatically restored when switching between Edit and Terrain mode. 4. Backup Terrain Splatmaps (Full version & Pro only) Execute this option to update the terrain splatmap data backups after making changes to the terrain splatmap(s). You will always have a fresh backup of the terrain splatmap(s)! In the case of multiple terrains in the scene, first select the terrain you want to backup otherwise the terrain selected in General Settings will be backed up. 5. Restore Terrain Splatmaps (Full version & Pro only) Execute this option if you want to restore the terrain splatmap data to its original state. The terrain splatmap data is automatically restored when switching between Edit and Terrain mode. Optionally you may also select a texture with the manually edited road splatmap. The road shape will be blended in the terrain splatmap(s). In the case of multiple terrains in the scene, first select the terrain you want to restore otherwise the terrain selected in General Settings will be restored. 6. Backup Terrain Vegetation (Full version & Pro only) Execute this option to update the terrain vegetation data backups after adding or removing trees or detail objects. You will always have a fresh backup of the terrain vegetation data! 7. Restore Terrain Vegetation (Full version & Pro only) Execute this option if you want to restore the terrain vegetation data to its original state. Vegetation data is automatically restored when switching back from Terrain mode to Edit mode. 8. Side Objects (Full version & Pro only) This will open the Side Object Manager. Use it to create and edit side objects. 9. Build EasyRoads3D Objects (Full version & Pro only) Execute this option when you are ready with all EasyRoads3D terrain objects in the scene. If not already done, the terrain will be leveled according the created road objects, road geometry, side objects and terrain splatmaps will be created according the settings and all EasyRoads3D editor objects will be destroyed including the temporary script added to terrain objects in the scene. This process will also automatically save the road geometry in the folder project/EasyRoads3D/[roadname]/ under the same as the EasyRoads3D object name with "_final" added to it.
GETTING STARTED CREATING THE ROAD Select New EasyRoads3D Object from the EasyRoads3D Menu. A dialog window will appear where you can name the new road object. The new road object will be added to the hierarchy panel after clicking the Create Object button. In the property Inspector you will see the EasyRoads3D toolbar:
Add road markers by activating the Add Markers toolbar tab. Move the mouse to the position where you want the road to start and click the left mouse button while holding the [shift] key. Continue adding markers according the shape of the desired road. You will see that the road system will create surfaces representing the road and the affected surrounding which are configurable in General Settings. NOTE: Make sure the scene camera is in perspective mode when adding or inserting markers. In isometric mode the markers will be placed in the center of the screen!
Insert road markers works similar as adding road markers but instead of adding the marker at the end of the road, it will insert the marker between the 2 closest markers to the mouse position. Make sure you are in Insert Markers mode by activating the Insert Markers toolbar tab!
Click on one of the generated surfaces to change its properties. Soft Selection: When enabled for the selected marker all other markers within the entered soft selection distance will be affected to an extend as the distance to the selected marker. Left/Right Indent. Use this feature to increase the distance between the road and the edge where the terrain has the same height as the road. This is useful in hilly areas to avoid the terrain break through the road because of the Unity terrain LOD system. (In the free version only the right indents are editable)
Left/Right Surrounding: This represents the distance used to level the area between the road and the current terrain height. This property gives you full control over the area around the road, especially in hilly areas. (In the free version only the right surrounding is editable)
Left/Right Tilting (Full version & Pro only). This feature will lift the road up to a maximum of the road width minus 1 meter. You will get the best results when used together with the soft selection tool so the tilting affects all road surfaces in a bended road. (In the free version only right tilting is editable) Refresh Surfaces (). By default the road surfaces will be updated instantly after changing one of the above settings. However when Auto Updates in General Settings is toggled off this will not be the case. Click the Refresh Surface button to update the surfaces manually. Delete Road Marker. Clicking this button will remove the selected road marker.
Bridge Object (Full version & Pro only): Activate this toggle to create bridges. The terrain will not be deformed while the road geometry will still follow the marker positions. Distribute Heights: This toggle is associated with bridge objects. Activating it will distribute the road surface heights evenly from the previous marker position to the terrain height at the selected marker position. This feature is useful to create realistic viaducts. Simply select a marker, make sure the road surface area between this marker and the previous marker is raised above the ground and check "Bridge Object". You will see that the white surfaces disappear. This means that the terrain will not be adjusted for this part of the road. Alternatively you can check "Distribute Heights" which will gradually lower the terrain from the previous marker to the terrain height at the selected marker. The shape will be visually represented by the white surfaces. A bridge with distributed heights enabled, consists of at least 3 markers:
Start New LOD Segment (Full version & Pro only): In EasyRoads3d v2 you can create and save your road geometry in different LOD segments. Simply check this checkbox when you want to start a new road LOD segment at the selected marker. When rendering the road object you will see that the road asset in the hierarchy now has a number of child assets matching the number of LOD segments. Exporting the road geometry will save each segment in its own group. To create the geometry for your LOD system, export the road with a high resolution, rename the files, switch to a lower resolution and again save the road.
Additional Marker Functions When two markers are selected you will see the below buttons in the Inspector:
SIDE OBJECT MARKER PROPERTIES (Full version & Pro only) By default markers cannot be accessed when road objects are in render mode (see just below). However when side objects have been built in render mode you will see that the marker objects appear again. By selecting a marker you can adjust the side object settings for this marker for any of the available side objects. Depending on the type of side object you will see the following properties: Selected Object: this is a combobox with all available side objects. Select the side object from the list you want to edit. Display Object: Toggle this on/off when you want to render the selected side object for the selected marker. Spline Node: Toggle this respectively on/off when you want to use this marker for the spline shape. The road scene in the demo project uses this feature for the "Right Fence" in the sharp corner. It cuts of a large part of the road shape. This allows you to create shapes that run independently from the actual road shape. Distance Sideways: This allows you to move the spline path for the selected side object away from the road shape.
Click the Level Terrain tab on the toolbar to level the terrain according to the created road and road surrounding surfaces. Depending on the resolution of the terrain and the size of the road this may take a while. Click the Level Terrain Tab again to switch back to "Edit Mode" and continue adding markers or tweaking markers settings (Full version & Pro only). Clicking the Terrain tab from the marker toolbar will select the main road object first. In this case, click this tab again to activate the terrain rendering. NOTE: If you save a scene while an EasyRoads3D objects is in "Render" state and then close Unity, these objects will automatically switch back to edit mode after reopening the scene. This is to make sure the EasyRoads3D object is correctly initialized on startup and also to ensure that the original terrain data is preserved. It is therefor recommended to save your scenes with all EasyRoads3D objects in edit mode. After leveling is finished the following properties will appear in the Inspector Panel: Render: When this property is toggled on, terrain matching road geometry will be created. Material (Full version & Pro only): This will display the current road texture. Click on the texture to open the Road Texture Window. This will display all available road textures in the folder: /Assets/EasyRoads3D/Textures/Road Textures. You can add your own textures in this folder if you like to use this system. Below each texture you will see the supported shaders for this texture. Currently supported shaders are: Diffuse, Bumped Diffuse and Bumped Specular. The name convention is: texturename_d for the diffuse texture and texturename_b for the bumped texture. When the window opens, the above mentioned folder will be scanned and matching materials will be added to the dropdown box accordingly. Select the shader type and then click the road texture to assign it to the road material. The folder /Assets/EasyRoads3D/Shaders/ contains 6 different depth offset shaders to make sure the road is rendered on top of the terrain. When using a low Field of View on the camera you may still encounter some z-fighting. In this case open the respective shader and tweak the two Offset factor and unit parameters (just below LOD) further downwards. NOTE: Currently all road objects in a project use the same material. Changing the material on one of them will change the material on all other road objects. In the next version this will be handled per road object individually. Meanwhile you can manually create new materials or duplicate /Assets/EasyRoads3D/Resources/roadMaterial and assign different textures to them once the road is ready. Blend the start and / or end (Full version & Pro only): This will blend the start and / or the end of the road with the terrain for a more fluent transition. When checked the below control will be enabled. See the below note regarding the shader requirements for blending. Start Distance: the distance over which the road will be blended at the start End Distance: the distance over which the road will be blended at the start NOTE: For road blending one of the transparency shaders is required. Select the "road" game object inside the EasyRoads3D road editor object. In the Inspector look for the road material and choose one of the "EasyRoads3D/Transparent/" shaders from the shader dropdown. Also apply this shader to the following material in the project folder: /Assets/EasyRoads3D/Resources/roadMaterial so the transparency shader will be automatically applied on next builds. Please use the transparency shaders inside the Unity 3 folder if you are using Unity 3, otherwise the road will be invisible! Road Segments (Full version & Pro only): The number of segments over the width of the road. When this number is larger then 1 you will see the following new properties:
Resolution. This represents the geometry resolution of the road. UVMapping. This allows you to control the texture mapping on the road. Raise (cm).Represents how much the geometry is positioned above the terrain. On relatively flat surface 2 cm should be fine. Below 2 cm some terrain adjusting is necessary using the unity terrain tools at specific spots. Calculate Tangents (Full version & Pro only). This will calculate the mesh tangents which is required if you use a bumped shader on the road mesh. This button is disabled when "Tangents" in General Settings is enabled. Save Geometry (Full version & Pro only). This will create a .obj file of the road geometry with the name of the road object saved in the folder project/EasyRoads3D/[roadname]/. Finalize Object (Full version & Pro only). This process does the same as "Build EasyRoads3D Objects" from the main EasyRoads3D Menu but only for this road object. It will unlink the road mesh from the EasyRoads3D object, rename it to the same name as the EasyRoads3D object and destroy the EasyRoads3D editor object. Note that after this process the road cannot be edited anymore. However you could try reloading the scene, the full road object should this be there unless you save the scene after this process. NOTE: When exporting the terrain the geometry will match the position of the resolution slider! NOTE: The road object created by EasyRoads3D includes uv2 coordinates matching the terrain boundaries. This will allow you to use the terrain lightmap on the road. Simply choose a lightmapped shader for the road material and drag the terrain lightmap in the lightmap slot of this shader.
EasyRoads3D can embed the shape of the road in the terrain splatmap. Apply Splatmap. When toggled on the road shape will be included in the terrain splatmap. You will have access to a number of splatmap properties. Terrain texture. Select the terrain texture you like to use for the road shape. The splatmap features support terrains with up to 8 textures (2 splatmaps). Expand Width: This will make the road shape wider. The actual sizes depends on the Control Texture Resolution of your terrain. Smooth Level. This will smoothen the edges of the road splatmap slightly. Better results can be achieved in your paint program especially when you use a resolution of 512 or lower. The smoothing algorithm will be improved in next updates. You can find the raw road splatmap in the folder: project folder > EasyRoads3D > [road name] > roadSplatMap.png. You may edit it in your paint program and merge it with the terrain splatmaps. Offset x/ Offset y. Especially when the Control Texture Resolution is low compared to the size of the terrain the road shape on the splatmap can be slightly out of position compared to the road geometry. Changing the Offset parameters may give better results. Alternatively and recommended, reposition markers to better match the terrain splatmap resolution or increase the Control Texture Resolution of the terrain. Opacity. Controls the blend level of the road splatmap with the rest of the terrain. Apply Changes. Click this button to apply changes made to above settings.
SMOOTH EDGES This will smoothen the terrain near the indent edges to the left and right over the distance set in Distance (m). Click the "Smooth Edges" button to apply the smoothing.
SMOOTH SURROUNDING This will smoothen the terrain near the surrounding edges to the left and right over the distance set in Distance (m). Click the "Smooth Surrounding" button to apply the smoothing. SIDE OBJECT SETTINGS (Full version & Pro only) When this road object has active side objects you will see a button "Built Side Objects". Click this button to create / remove the side objects. Note: Click the "Terrain" tab once again (or any other toolbar tab) to switch back to edit mode.
CAM FLY OVER (Full version & Pro only) The cam fly over is very useful to quickly explore the roads directly in scene view. Position: with the position slider you can control the cam position from the start to the end of the road. Height: Use this to control the height of the cam above the road.
- The general road settings are displayed in this toolbar item
NOTE: Multiple terrains. Currently terrains are processed individually by selecting the active terrain (point 14 above). This minimizes processing time when working on a specific part of the road. In the next release a progressbar will be visible and the option to proces all terrains at once. The reason why this is not implemented right now is because procssing a large number of terrains at once can take some time. It will be confusing to know what is going on without a progressbar visible. NOTE: EasyRoads3D uses layers 29, 30 and 31. Make sure other game objects in the scene are not on one of these layers to avoid unexpected behaviour! Road Splatmap to Terrain Splatmap
NOTE: Photoshop users, it is recommended to use "Save for web..." to save the png. If you save the image using "Save as...", be sure to select the png format. Do not simply select the already existing file in your folder as this will probably NOT import well in Unity. NOTE: DO NOT use the splatmap features if you are using more then 8 textures on your terrain!
The road geometry exported from EasyRoads3D contains vertex info, face info and UV info. You will have to apply normal info in your modeling application. If you exported the geometry with terrain lightmap support you will see 4 corner faces. Select all road faces and corner faces and use a planar type of uvmapping on the second channel. Save or export to .fbx. In Unity make sure that the import setting for size is 1. Choose a lightmap supported shader on your road asset and drag the terrain lightmap to the shaders lightmap slot. Drag the asset to your scene go to the EasyRoads3D menu and select "Position Road", browse to the EasyRoads3D terrain export file and select it. The road will be positioned correctly. Depending on your modeling application and/or the export settings you used to export the road, it could be that you have to rotate the object on 1 or more axis. The "Position Road" editor script has some commented code in it that can take care of this automatically once you figured out the correct settings for your case. Just uncomment the lines and fill in the right amounts. RIVER OBJECTS (Full version & Pro only): EasyRoads3D Menu > New Object > Object Type: River Object River objects essentially work similar as road objects. With the following differences. In Settings you will see 4 more properties: - Water Level. The minimum distance between the water surface and the surrounding. In the case the surrounding is below the water level it will be raised with this value. - Floor Depth. This represents the depth of the river relative to the marker position. This value can be adjusted per marker. - Material: This will display the currently available water materials in the project folder. Import the water packages if there are no materials available! - Script: This will display the currently available water scripts in the project folder. Import the water packages if there are no scripts available! After Leveling the terrain and creating the river you will see also the the Material and Script options. Changing these in this mode will instantly update the river object. If you cannot see the changes, simply click in the scene view to update it. You now probably want to see the river animation. Please note this will output a warning regarding loss of the original terrain data stored in memory. Read about this here.
SIDE OBJECTS (Full version & Pro only): The Side Objects feature is a powerful tool which will significantly lower your production time. In general you can create 3 types of side objects: 1. By instantiating game objects / prefabs. Side Objects are managed through the Side Object Manager. Menu > EasyRoads3D > Side Objects > Object Manager Instantiated Side Objects:
For procedural objects choose "Procedural Mesh Object" as the Object Type. You will see that the properties will change:
Update button. Click this button to automatically update the currently selected side object in the scene. This will only work if this side object is currently rendered for one of the EasyRoads3D objects in the scene.
IMPORTANT NOTE REGARDING PREFAB ROTATIONS! The rotation of prefabs whether used as Start Asset, End Assets, connection object or when used on an Instantitaed Object type is important: As explained above you can use start and end gameobjects / prefabs to close gaps on procedurally created geometry. It is important that these objects are correctly rotated. Depending on the modeling application you use, gameobjects may be rotated and point in the wrong direction after being imported. Always make sure that they point in the correct direction. You can check this by selecting the object with the mesh renderer attached in the project view and have a close look at the preview pane. Look at the images below. On the left you see the imported geometry of the "left end of the wall" object in the road demo. The intention is to snap this object to the end of the wall with the open gap. However the closed area is pointing towards us, this is the wrong direction. The importer rotated the object by 180 degrees on the y-axis.
You can also see if the rotation is correct by dropping the object in the scene. Check the rotation values in the Inspector. Did Unity automatically apply rotations to one or more of the axis? These rotation values are ignored in the side objects system. The solution is to create a new prefab and use the gameobject with the mesh renderer attached as a child of this new prefab. It is very important that the mesh renderer is a component of the child of the prefab and not the parent object. Make sure that the relative position of this child object to the new prefab is at (0,0,0) and, rotate the child object 180 degrees on the y-axis in the Inspector or according the same rotation values as Unity automatically applies when dropping the prefab in th scene. You can see the result on the right. Now the gameobject is pointing in the correct direction. Have a look at the demo project. So, depending on your modeling application and export settings within the modeling application you may have to rotate the child on the x-axis, Y-axis or z-axis.
Procedural Object Editor Window: For procedural objects you can define the shape of the object in the Procedural Object Editor Window. This window will open when you click the button "Edit Geometry" on the right of the Object Type combo box. This button will become visible when "Procedural Mesh Object" is selected. The editor window gives a 2D representation of the shape of the procedural geometry. You can define any shape you want:
Controls / Hot Keys:
Side Object Geometry Controls:
Update button. Click this button to automatically update the currently selected side object in the scene. This will only work if this side object is currently rendered for one of the EasyRoads3D objects in the scene.
NOTE: If you use the geometry trace feature it may happen that you clearly see the correct shape but the points do not connect to each other in the right order. This is due to the vertice order in the mesh. You can correct this by changing the index of points. Start at one of the two points that should have only one connection. If the index is not 0 you can either set it to 0 by selecting 0 from the combobox at the top left. But preferably first check the other point that should only have one connection. If this point is set to index 0, start here. Now select the next point to which this point should connect. If it already connects, the index will be 1. If not, then select index 1 in the combobox for this point. Repeat this procedure until all points are correctly connected.
Managing Side Objects in your scene Select an EasyRoads3D object in the scene and make sure the General Settings tab is selected . At the bottom you will see a list with all available side objects in this project. You can activate / deactivate side objects per scene. For example in the demo, the train track side objects are not used in the road scene so we uncheck all side objects related to the train track. This same list is also available after your build the side objects. If you toggle / off side objects the scene will update and you will instantly see how the changes affect the scene. Building the Side Objects To built the side objects of an EasyRoads3d object , first render the road and terrain by clicking the middle tab, . At the bottom you will see "Side Objects Settings". Click the button "Built Side Objects". Now all active side objects will be built and you will see a new button "Save Side Object Geometry". This will create .obj files of each individual side object. Find the files in: your unity project/EasyRoads3D/road object name/ Controlling Side Objects per Marker After building the side objects you will also see that the Marker Objects will become visible. This allows you to easily select a marker. Instead of the default marker properties, You will now see a combobox with all active side objects and below the properties of the currently selected side object:
Tweaking Side Object Properties At this stage you might notice for example that the normals of a side object point in the wrong direction. You can correct this by going back to edit mode and opening the Side Object Manager, but you can also tweak side object properties by selecting them in the scene or in the hierarchy (RoadObject Asset> Side Objects > ...).
PROCEDURAL MESH OBJECT (Full version & Pro only) EasyRoads3D Menu > New Object > Object Type: Procedural Mesh Object The Procedural Mesh Object is based on the side objects feature. You can associate one or more of the side objects to this object type. The main difference with the road and river object is that this object type will not alter the terrain heights. It is the ideal tool to instantiate objects according a path or create procedural geometry according a path. It can be used to create for example individual fences, walls, hedges, pipelines, rock formations etc. Procedural Mesh Object inspector functionality differences compared to the road and river object: When a marker is selected you will see the markers side object properties (for road and river objects, you will only see these properties after you leveled the terrain and build the side objects). The middle "Process Terrain" tab will not alter the terrain heights. Use it to show / hide the markers. New properties: General Settings > Snap to terrain: This property is checked by default. Uncheck it if you want to have the side object follow the spline shape exactly according the marker positions. In other words, if you do not want the side object to snap to the terrain. Markers > Sharp Corner: This is a very useful property for objects such as fences, hedges. When checked the shape will not have a rounded corner based on the spline path at this marker position, instead the corner will be sharp. NOTE:You may have to move the marker slightly for a perfect sharp corner in order to have the the number of instances exactly fit for a sharp corner.
- adding / inserting markers is done by activating the respective toolbar tab, holding the [shift] key and click. MissingComponentException: There is no 'Renderer' attached to the "road" game object, but a script is trying to access it. This message may appear when clicking the middle tab "Level Terrain" and appears when previous render data has been lost due to for example playing the scene or saving a script while the terrain object was in render mode. For now, to solve this problem, optionally save the scene, create a new scene and reopen the previous scene, this will refresh the terrain object. Mesh.vertices is too large. A mesh may not have more than 65000 vertices. This error may occur when rendering side objects. If the side object is an instantiated object, make sure you uncheck "Combine instantiated objects". Instead, divide the instantiated objects in groups by parenting them to an empty game object and apply the Unity combine script.
The road object is visible in Game View but not in Scene View EasyRoads3D uses layers 30 and 31. These layers must be active in the layers dropdown at the right top of the Unity Editor. If these layers are not named and your Unity Editor is set to use custom layer, layers 30 and 31 will be disabled and therefore the road will not be visible in scene view. Selecting "Everything" however will NOT activate Layers 30 and 31 in this case! The fix, with the EasyRoads3D object selected, In the Inspector select "Add Layer" at the bottom of the Layers dropdown and give layer 30 and 31 a name like EasyRoads3D30 and EasyRoads3D31. These layers will now become visible in the other layers dropdown. Make sure they are active. Mismatched serialization in the builtin class 'Mesh'. (Read 10380 bytes but expected 10381 bytes) This error can appear immediately after importing the package in Unity 4.3. It is harmless. Further info http://forum.unity3d.com/threads/210417-project-4-2-to-4-3-Mismatched-serialization-in-the-builtin-class-Mesh Markers do not connect All Markers are placed at the same position in the center of the scene Make sure the scene camera is in perspective mode (Scene Gizmo) or one of the axis is selected when adding or inserting markers. In isometric mode ("Iso" is displayed in white below the scene gizmo) the markers will be placed in the center of the screen! The road disappears below the terrain This will happen when road vertices are below the terrains Y position because technically it is impossible to set terrain heights below its Y position. The road will be below the terrain in these areas. So make sure all markers are at least positioned at the terrains Y position. Also avoid big height differences between markers at the terrains Y position and the next marker. The road will first slightly move downwards to below the terrains Y position. To fix this situation, move the marker at the terrain Y position slightly upwards. The road can also disappear below the terrain on terrains with a larger heightmap scale and considerable height differences in the road. There are simply not enough terrain points to accurately deform the terrain. You can see this when turning on Wireframe or Tex-Wire for scene view and zoom in to the critical area. You will clearly see the terrain points. To solve these situations, avoid big short height differences in the road or use an higher heightmap resolution on your terrain. Side Objects do not appear This happens when you have chosen to disable this side object by default for each marker. To check this, select a marker, in the inspector select the specific side object from the Selected Object combobox and have a look at the Display Object property. Is it checked? Wrong Rotation Prefabs used in side objects Prefabs may appear in the scene with the wrong rotation. This is directly related to the mesh data of your prefab. First, EasyRoads3D instantiates side objects according the direction of the spline path in the Z direction. So if you want to Instantiate a fence mesh along the track, the fence model must be modelled in the direction of the Z axis, not the X axis. The second thing to check is how Unity displays the prefab and if that is the correct orientation. If it is the correct orientation, check the rotation values in the Inspector. Did Unity automatically apply rotation values to the prefab or are the rotation values (0, 0, 0)? If Unity did apply rotation values, these rotation values are ignored in EasyRoads3D. You can do two things to solve this. First you could change the rotation of the model in your modeling app. Second, you can create an empty prefab, position it a (0, 0, 0), add your real model as a child to this prefab at (0, 0, 0) and apply the same rotation values as Unity does to this child object. Attach this new prefab to the side object, the orientation should now be correct. The importance of the correct rotation setup of prefabs is also explained here.
Side Objects: Error: Mesh.vertices is too large. A mesh may not have more than 65000 vertices. This error may occur when building side objects. If the side object is an instantiated object, make sure you uncheck "Combine instantiated objects". Instead, divide the instantiated objects in groups by parenting them to an empty game object and apply the Unity combine script to each group.
The generated river mesh breaks through the terrain: This most likely due to the terrain heightmap resolution / terrain size settings. Increasing the "River Bank Height" setting in General Settings should solve this.
Errors when swapping river materials / scripts The materials and scripts available in the comboboxes are the currently available assets in the project referring to the water assets in the Standard and Pro Standard Assets folders. If you get error messages when swapping them it means the combination of the selected Material and selected script will not work. This usually happens when using either a Watr3 material or script on one of the older materials or scripts. This is taken care of in the scripts by automatically updating the material or script. However it may still raise an error. This is on the list to fix.
I cannot add a new EasyRoads3D object Do you get error messages in your project also unrelated to EasyRoads3D? Make sure Unity comples the project without red error messages. To ensure the problem is not related to EasyRoads3D you could test it in a new fresh empty project. Please contact us if creating a new object still fails.
I am using Start / End blending but the road does not blend with the terrain. For road blending one of the transparency shaders is required. Select the "road" game object inside the EasyRoads3D road editor object. In the Inspector look for the road material and choose one of the "EasyRoads3D/Transparent/" shaders from the shader dropdown. Also apply this shader to the following material in the project folder: /Assets/EasyRoads3D/Resources/roadMaterial so the transparency shader will be automatically applied on next builds. Please use the transparency shaders inside the Unity 3 folder if you are using Unity 3, otherwise the road will be invisible!
The package does import with errors or fails to import Do you already have the Free version in your project? Please remove that folder first. Or do you have EasyRoads3D already imported and is Monodevelop open? In that case try closing Monodevelop before importing the package.
Terrain Toolbar Tab. When a road marker segment is selected, sometime you may have to click the tab twice to start leveling the terrain . Road Splatmap: On bigger terrains with a low heightmap resolution it may happen that some parts of the generated road splatmap are missing. Edit the road splatmap and re import using Restore Terrain Splatmaps.
Have fun and do not hesitate to contact me if you experience issues or if you have questions! Email |
||||||||||||||||||||||||||||||||||||||||