About Store Forum Documentation Contact
Donations:
309$/mo



Post Reply 
Weird vehicle suspension raycasts effects
Author Message
cat555 Offline
Member

Post: #1
Weird vehicle suspension raycasts effects
Hi,

I'm setting up a racing game, a till now i was tuning a vehicle as a base for others. So, till now i had a race track with a vehicle... all working fine smile

I started then to introduce my AI cars, so i've added some more cars to the game, for testing.

It performs quite well, except a weird behavior that is very annoying... it seems that there are some issues with suspension raycasts, that affects other cars than the one that is being "raycasted".

I've done many tests, and can't figure out what the problem is... a simple test is:

- having X vehicles, apply a vertical impulse (Vec(0,100,0), for example) just to one of them (vehicle A, for instance)
- so, vehicle A flies as expected, but the problem is that some of the other vehicles, just sink in the floor and are not drivable anymore
- but, when the vehicle A drops to the floor, the other vehicles suspensions are now Ok again, above the floor
- worst case is if a vehicle just drops in a floor whole and his gone, the other vehicles sink again and will not recover anymore

So, it looks like, when raycasts of a vehicle just don't return a hit (or returns invalid data), that somehow affects the other cars suspension raycasts... if the floor is irregular, one car climbing a surface for example, it affects other cars raycasts...

Any idea of what could be wrong?

Thanks!
(This post was last modified: 09-25-2014 09:05 PM by cat555.)
09-25-2014 04:41 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: Weird vehicle suspension raycasts effects
Hi,

Thank you for reporting this issue. Could you please provide a sample project on which I can reproduce this?

Thanks a lot
09-26-2014 01:15 AM
Find all posts by this user Quote this message in a reply
cat555 Offline
Member

Post: #3
RE: Weird vehicle suspension raycasts effects
Hi, Ok i've modified your "multiplayer racing game" to show this effect clearly. I'll send you a PM in a moment with more details to exchange the file.

Thanks!
09-26-2014 11:13 AM
Find all posts by this user Quote this message in a reply
cat555 Offline
Member

Post: #4
RE: Weird vehicle suspension raycasts effects
Hi @Esenthel, additionaly to my PM, check this out please:

Can this be concurrency problems when calling "PxVehicleUpdates()".

In PhysX 3.3.1 we have these release notes - http://physxinfo.com/news/12283/physx-sd...available/

See Vehicles section where it says:
Added:
- Vehicles may now be updated concurrently through the addition of a new function
- PxVehiclePostUpdates and passing a PxVehicleConcurrentUpdateData array to PxVehicleupdates.

When looking to specs, it's says:
Code:
void PxVehiclePostUpdates    (    const PxVehicleConcurrentUpdateData *     vehicleConcurrentUpdates,
const PxU32     nbVehicles,
PxVehicleWheels **     vehicles    
)            
Apply actor changes that were computed in concurrent calls to PxVehicleUpdates but which could not be safely applied due to the concurrency.

I believe that in Esenthel we have 3.3.0, right?

============

But, accordingly to your code, it seems that vehicles are not being updated concurrently, so this should not be the case...
(This post was last modified: 09-26-2014 03:48 PM by cat555.)
09-26-2014 03:45 PM
Find all posts by this user Quote this message in a reply
Post Reply