Vehicle to Vehicle Collisions

(Forgive me if this is the wrong section, this is my first time posting on the DevFourm :slight_smile:)

What do you want to achieve?

Functional and (somewhat) realistic vehicle to vehicle collision interactions between A-Chassis vehicles.

What is the issue?

VISION LAG. This has been discussed before on the forums, but mostly in late 2022. This post from @GeorgeOfAllTrades very clearly demonstrates my issue.

*What solutions have you tried so far? Did you look for solutions on the Developer Hub?

Again, most of the threads contain outdated solutions, some of which even utilize now deprecated physics properties. I am mainly curious if anyone has found a solution to this in the modern ro-racing community.

Caveats:

  • Yes, I am aware tank chassis exists, no, it does not work for my purposes.
  • From what I have read, giving network ownership to the server does not work with A-Chassis and is too slow from a performance standpoint to be viable anyway.

Some related articles
These are some of the older threads I talked about earlier, might be useful in the solution.

2 Likes

vision lag usually happens due to code that handles visual things is on the server, just fire the front end part for all clients and the back end part handle it on the server. like calculations and allat keep it on the server but changing cframe or everything that is visible in the 3d world handle it on client

1 Like

Thanks for the insight, but I don’t think this is quite what I’m looking for. A-Chassis by default handles car movements on the client.

The actual issue is detailed in this older post that I mentioned in the message: Cars Predictive Pathing

Essentially:

Three players in a server, let’s say two are in a car and one is in the grandstands of our hypothetical racetrack.

Driver 1 sees themself in the lead, with Driver 2 trailing about a car’s length behind.
Driver 2 sees themself in the lead, with Driver 1 trailing about a car’s length behind.
Driver 3 (which is the technically correct view) sees Driver 1 and Driver 2 side by side.

The issue with this is it makes overtaking extremely difficult, as you can’t see where the other vehicles actually are. There are some partially working solutions, but they don’t mitigate the issue and usually create a new issue of input lag, of about 0.3 seconds for the client. This means you have to react extremely quickly, as not only do you have to notice a car moving and react, but three tenths of a second are subtracted from the time you have to react.

Again, thanks for the insight, but I think that someone with more A-Chassis experience might be of more use.

1 Like

Note that it is not plausible to hand network ownership to the server, as I believe for A-Chassis to function, it must be handled on the client. I noted this in the Caveats section of my original post.

1 Like

yea i didnt look at the post you mentioned in the beginning my bad, but after looking i am pretty sure its just the ping difference, and sadly you cant do anything about it, its the same thing in every game that has something where only one person can get the end product first, in the end all that should matter is what the server sees cause you calculate who reached the end first on the server

1 Like

Not marking this as solved yet as I’m curious if any ro-racing devs have found other workarounds.

1 Like

A-Chassis is entirely client sided. That is why changing network ownership doesn’t do anything. As far as making A-Chassis no longer have accurate positioning, you’d need to code a whole system, such as a “Predictive Pathing” system.

I made a secondary feature request, because it was made clear to me that Predictive Pathing as a system is something Roblox never would implement themselves. My second post focused on giving us the tools to do it ourselves.

Notably:

Accurate Ping Detection is still not available. And this is really rough on creating a compensating feature, because you need to think about what is the player’s ping to the server & the player they are replicating’s ping to the server, add those together to get time, and use that with the current speed of the car to get the relating distance.

That said, even if we had ping detection, and you created this system in an efficient way (quite tough), I still wouldn’t recommend this system for A-Chassis. They way they simulate a real world car, does not handle sudden changes very well, and so for example, colliding at speed with another car, could be catastrophic, even with a system in place to get positioning a little better.

If you’re really on the hunt for such a thing, you’d be better off creating your own system. Like for example this NASCAR system. I can’t confirm exactly what they are doing, but Pummu’s Stock Cars have typically been NVL [setting network ownership to nil, aka the server] so my guess is same thing just running with Roblox’s Mechanical Constraints.

If you’d like, you can take a look at a system I made a while back. It’s lacking a suspension system. But has the basis of using constraints & handling the controls for it.
g-chassis-package.rbxm (24.5 KB)

TL;DR

  • doing it with a-chassis is nearly impossible, make something from scratch
  • even then, good luck managing input lag and “server slowdowns”, because that’s the current trade off

If I’m wrong and you figure it out, there are various racing games that would pay a lot of money for a copy. But as far as things go, mostly it’s either vision lag or input lag. The choice is yours.

3 Likes

Thank you very much for the comprehensive reply! I’ll be sure to check out G-Chassis. I did suspect that having no reliable ping detection would be part of the issue, thanks for confirming that as well.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.