WebGL - Casual Vehicular Action (Completed)

Since Feedback Friday last week I’ve made some progress. I took the advice of @Antypodish and @Billy4184 about the drifty camera - there’s now a Controls Option that lets you adjust how drifty. I’ve made the default to be 50% of what it was previously. I integrated most of the gameplay from the daytime “rail shooterish” world along with adding indicators for nearby challenges (as shown in the previous post). My current focus is adding gameplay mechanics - I’ll sink time into visual style / design / color palette when everything I want to code is roughed in.

There are interior lobbies to the towers now with a total of over 550 breakable windows. Destroying one also handles related LODs (which took some effort), so no matter how far away you are, the window is still gone. I disabled physics on the shards until I do a “Fragment Physics” slider in options for % of fragments to use it with, but they’re still roughly thrown based on impact. You can drive into/through lobby windows or shoot them out. There’s no sound except for the vehicle right now but I’ll add shatttering glass effects and some other stuff soon, maybe random items inside buildings etc… not to mention random prop placement and other typical stuff, and though I’m not keen on populating the world much as it’s a throwaway, I still do need the functionality as part of my workflow/tools/etc. Not to mention this is already effectively a stress test for WebGL - there’s a lot in this (over 1/4 million objects last time I checked the profiler). Actual game worlds will probably have less / be more tailored to a specific flow of gameplay.

I added an “Advanced Config” button in Graphics Options. Right now the new page just has Structure LOD Bias and Draw Distance, but will have more options soon and be somewhat reorganized. You can increase the distance at which structure interiors are visible with the first slider - but I wouldn’t advise maxing it out unless you’re running the Windows build because not allowing structures to use a lower level of detail further out will drastically increase batch counts. However, the game does have a different feel if you reduce the draw distance and then increase interiors to the edge of that, with buildings and trees coming out of the fog as you’re driving along etc… it’s possible I won’t include a Draw Distance option at all because it could break whatever visual style I go with, but for now it’s fine.

Also since my previous post I’ve roughed in the equivalent of a “rail grinding”/slingshot gameplay mechanic - there’s a couple of examples early in the world, and it’s not quite done yet (still need to have the car banking around corners, optimize things a bit).

In order to slingshot, you have to 1) be going in the direction of the “entry” and 2) be going faster than a minimum speed. The faster you’re moving the more of an effect the slingshot has. There’s an arrow on the ground that’s green if you’re approaching from the right direction (up to an angle difference limit), or red if not. The “11.4” there is the current velocity, as you accelerate towards it the color changes from red to yellow to green then it says “OK!”. I’ll convert this to KPH/MPH eventually. The arrow also needs replacing or to be changed to several in a row, it’s not visually enough at high speed… still mulling over design of it that complements boost pads and checkpoint challenges (some of the next stuff I’ll be roughing in). You’ll be driving over boosts then hitting a rail to get around a corner without losing speed - most rails will line you up perfectly to continue, with the intention of maintaining nausea-inducing speeds for most of the course.

6450105--722289--not_enough_speed.jpg 6450105--722292--wrong_direction.jpg

If you’re going fast enough and approaching from the right direction, the lock opens and hitting it will attach you to the rail and accelerate your motion (like slingshot you off the end of it… which isn’t a big deal if you hit the rail at a slower speed, but if you’re already going fast when you hit it, the boost is huge).

6450105--722298--good_angle_and_speed.jpg

Initially, only the beginning of the rail is glowing/more opaque, but as you get flung along it, the portion of the rail nearest to you (magnified by your speed) lights up, while the rest of the rail is mostly transparent. It looks a lot better in motion but here’s what it’s like exiting the rail from a sharp corner:

6450105--722301--exiting_rail.jpg

There’s also a bridge you use as a ramp further down that road, with a rail you can catch in the air if you have enough speed from the previous rail and your aim is close enough.

Finally, the current build is now using Unity Engine 2021.1.0a2. Hopefully progress continues to be reasonably smooth, I’ve got a long way to go yet. 1 week down, 51 to go. I’m kidding, …probably :roll_eyes: