How do you make the tire tracks in Swerve?
Also, want to make something like explosions marks/bullet holes on surfaces (potentially curved/complex), is that a similar technique?
I saw the post about how decals aren’t supported, is that pretty much what I’d need to implement?
In the Valve Hammer level editor, I could plop a decal on some surface, and it would wrap around a curved/complex surface as expected, and I think that’s what I’d want from this functionality. Also, things like roads and paths, I could warp and merge. Also, putting a large muddy decal with offset rotation on a repeating surface really helped break up the repeating pattern.
This would be a useful thing to put up as an example if there isn’t one already for us content creators vs the harder core programmers.
Tire tracks in SWERVE, is basically many quads one after the other. They always face up as game design does not requires anything else. Each point within length of track can be opaque, so we check if tire is above road, then apply usual opacity calculations (drifting, etc), if tire is not above road tile, set opacity to 0. That way we avoid floating tire tracks.
Those are not full on decals, as game design allowed to simplify rules for making them be always at same height and always facing up.
In source engine (Valve Hammer) they have BSP geometry, that has uniformly unwrapped blocks. Decals there is essentially drawing one texture on top of the other texture. They are not full-on decals that is geometry that would wrap around anything.
There are many techniques to make full on decals, one of modern is to do as post-effect, but it mostly done with Deferred Renderer as you need to have scene data like position and normals, and then for each decal you would make small post effect to project decal on top of geometry.
By the way, here’s the original test project for tire tracks:
Launch it and hold space to leave marks
You can use the scripts/shaders in your projects.
Neat code! I don’t really understand all that GL code, but was able to muddle through it to excrete some rainbows
Is there a newer version of the test trail game that uses the new 2.0 scripts?
Is there any updated version of this Tire trail?
Tire Trail Updated