New Road Creation Tools

Intro
As a roblox developer, it is currently too hard to create twisty and realistic roads in roblox. Currently, developers have to use square parts to fit in with things like smooth terrain. This is a difficult task to do, and often requires lots of work on a builder’s end to make the terrain look like it’s supposed to be with the road. Not only this, but it raises the part count substantially.

Alternatives
The best method I’ve seen for making roads quickly was actually in the Torque3D engine, via BeamNG.Drive. Here is a video of someone making a road in BeamNG. Notice how the texture image behaves exactly like a regular roblox texture, except instead of having it based on a world axis, it’s based on a local axis.

Terrain
Terrain tools can effect how these roads are made greatly. I think a tool like the one shown in the video used to raise the terrain to the road level would be an amazing feature to roblox and would be extremely useful for all kinds of development, not just roads. Not only that, but the tool used to smooth out the rock walls had a threshold for how much it was to smooth out the wall. With this, we can make scenes like this one with ease.

Current Flaws
Currently, it’s quite inefficient to put a part down for every line and detail on the road. Now, that’s okay to an extent - Arrows and parking spaces would be pretty difficult to use in a texture. In these cases it’s alright to use parts and decals. However, it’s quite tedious and relatively GPU-costing to make a part for every line on the road. Especially when there is a complex road system with many lanes. Using textures would not only speed the game up, but it would make for a more realistic and immersive experience in the game.

How it should be done
In the video, there were bones on the road, similar to animation. Each bone could be extruded and the road would be extended. I think this is a pretty simple, but very useful concept that roblox is lacking and could really use. The road, when seen in the client, would function like a MeshPart (though with a better collision fidelity hopefully). Each “Road” would have one texture that is projected on top. It would be useful to have fade options so the texture fades out on the ends (like double lines and dirt roads on the sides) but I suppose that’s not completely necessary because of the capabilities of the graphical designer. The road, under the hood of roblox, would have lots of different parts. If you’ve ever seen TwentyTwoPilots’ road plugin, it’s sorta like that, only mesh.

Example:

Each “Part” would have a texture in it. That way we can have cool road textures like Asphalt, mud, rock, gravel, etc.

So here are the special properties of the Instance:
FrontTexture (string)
BackTexture (string)
LeftTexture (string)
RightTexture (string)
TopTexture (string)
BottomTexture (string)
(Per Each Face Texture)
–StudsPerTileU (int)
–StudsPerTileV (int)
Color3 (Color3)
Length (this would be locked, it’s an integer for how long the road is from start to finish)
Width (int)
Height (int)
TextureTransparency (int)
PartTransparency (int)
MiddleOffset (Vector3)

The reason I put Width in there is because that way, we can duplicate the road and make it narrow to make lines that only appear on the sides of the road and things of that sort. I also think it’s imperative that the texture is stretched to fit the shape of the road.

Editor
I thought about how making the road should be done, and I think the most effective way to do it would be by using bones. Bones are used in animating a lot, but I think they’d be very useful in making roads as well because this way the pitch, roll, and turn of a road piece would be so easily done that someone could make an open-world universe in a day. If you look in the video, I think that works off something similar to bones. I think being able to extrude bones and make roads longer that way would be very useful as well. With these kinds of tools, mountainous terrains won’t be too far in the future.

Here’s an example of me editing the bones of a road I rigged up in Blender:
https://gyazo.com/42609e9aa49bc8a001f05faac05a2eef.gif


Conclusion
I think this road idea would basically put project development on steroids because of how useful this would be. I find myself constantly avoiding smoothterrain because of the difficulty of installing roads (especially because there is no way to specify a set height/roll for the terrain). I know new features aren’t added overnight, but I think this one’s at the top of my list.

This video features a little bit more of the road editor and how it fuses to terrain, and also some other nice things I’d like to see in roblox.

.FBX file with the armature so you can play around with it: RoadDemo.fbx (52.4 KB)

New stuff (Edited 4.3.18)

I’m pretty sure every good engine has this feature as a standard, it makes everything 1000 times easier on their developers, which makes games better overall :slight_smile:

Road creation’s been mastered already, and roblox falls short on it.

This is also a request directed towards plugin makers; It can be achieved without meshes at a higher cost. I’m not good enough of a scripter to make this happen.

List of game engines that support this method of road creation to an extent:

  • Unreal engine
  • Unity
  • Cryengine
  • Blender
  • Torque3D
  • Probably a lot more

I’m begging for this to become a feature.

  • I want this feature
  • I do not want this feature
  • I’m indifferent on the fate of this feature

0 voters

59 Likes

please make this a thing I beg you

15 Likes

I like this idea, kind of. I think it should be more like a path generation thing in general, instead of just making roads with it. Decent idea, not sure how it could be implemented.

7 Likes

I’ve been using a (somewhat) similar method to what you are describing to build roads recently. Basically I build the bones of the track first, and then come back and fill in the gaps. Here is an example of a track segment with the bones.

And then once I fill it in and add terrain.

The biggest issue I’ve run into is terrain. Not how to manipulate it or anything, but just terrain in general. One problem is that, currently, brick textures do not match terrain textures. In BeamNG, the textures for dirt paths and actual dirt are very similar, while this is hard to get in Roblox. Even using Color3 to get similar part colors to how terrain looks, the different from where terrain ends and brick starts is obvious.

The next issue is with the terrain LOD system. In the second screenshot it appears that there is a large gap between the road and terrain on the inside of the hairpin. But there isn’t.

The terrain LOD system just shrinks the terrain in that area, causing it to appear to be under the track. There is a similar case in other areas, where the terrain appears to be larger than it actual is at a distance, causing the terrain to poke through the track itself.

8 Likes

I don’t think this is a bad idea by any means, but would it not be possible to implement this sort of functionality with a plugin? The technique Torque3D was using seems viable to implement into a plugin context.

2 Likes

As far as bones and mesh deformation goes, no way, but perhaps it would be possible by making an insane part count. For the terrain height tools, however, it might be possible, though I’m not exactly up-to-date on the terrain’s API so I’m not sure what kinds of things it’s capable of doing in a regular environment. Even if it is possible, it would probably be extremely difficult just solely because of the infancy of the terrain API. I feel like all of this is less necessary if we only had height map importing… (hint hint)

Are you using GapFill by Stravant or something else? I didn’t know there was a way to fill inbetween :slight_smile: Also, maybe creating small mountains or changing the material around the edges of your track will make a difference.

Mostly gapfil. For some stuff I just free-hand it with wedges and bricks.

1 Like