FGear Vehicle Physics (v1.4)

most of the settings can be configured from unreals interface in both editor & play mode. there a couple of settings that can only be changed in editor time like mass & inertia settings. camera is also configurable, if you set its spring to zero it will not look towards the vehicle, i will check if mouse control is possible to add.

i have a question guys, 4.23 is released a couple weeks ago and we want to start with this version.
do you think we should add support for 4.22 or just go with the latest version, thank you.

I think since 4.23 has just been released (and no patch yet), you should add support for 4.22 too. Many people are sticking to 4.22 even for their new project.

i donā€™t understand why are we not able to change values of the car at runtime.

Say i offer upgrade to my players where they can upgrade their steering or suspension.
your plugin would be severely limited if it cannot update values at runtime.

you misunderstand, you can change them at runtime, what i am trying to say is that you do not need an in game ui to tweak your setups during development.

what i meant is to include an in game ui to tweak values in your demo, so we can see how your physics calculations are behaving for different values before buying the plugin.

i see, if we put all the settings including the tire models, there can be up to 150+ parameters so it is a lot work, anyway we will consider this in the future, right now we are focused on deploying the initial version.

The demo feels great! I hope the code is stable and performing well enough to be used in production.
Does it use the PhysX lib?

thanks, glad you like it.
unreal uses physx so we do use physx but that does not mean we use any vehicle functionality of physx.
tire friction and suspensions are all handled by fgear, we only make calls to the FBodyInstance struct like AddForceAtPosition or GetUnrealWorldVelocityAtPoint.

You can do something similar to this guy. https://youtu.be/PCyL7QcKKO4

its fairly straight forward, and understandable ui to change the parameters on runtime.
Iā€™m only asking this because iā€™m in a dire need for a good car physics.

it is finally available in marketplace : https://www.unrealengine.com/marketpā€¦7d00ddbe1121df

From the documentation this looks very well thought out.
Can you please provide some benchmarks for the simulation of the a vehicle? Preferably in comparison with the default UE vehicle implementation. What if there are 30-50 vehicles in a scene where some of them just stand still and others drive around.

good idea, will do it, thank you.
i wouldnā€™t use fgear for stationary or traffic vehicles though, it would be overkill.
anyway a comparison with ue vehicles will make things clear.

i added a list of known issues to the first post.
these will be updated as bugs are discovered or solved.

made a quick test and recorded a video.
test map contains 200 basic cars(uses simplified pacejka tire model + no effects + 100hz) and 4 sandbox demo vehicles.
when all 200 cars are visible i get around 65-70 fps at average, if i look away from vehicles i get 140+ fps.
my system is i7 4790k + 2gb R9 380

Thanks, bought the plugin and it looks great so far. Just wanted to test it on Android but getting this error when launching it: ā€œPlugin FGearPlugin failed to load because module FGearPlugin could not be found.ā€

i have just tried it from ground up and it just worked ok.

may be it is related with another problem like the following topic: "Plugin 'X' failed to load because module 'X' could not be found. - Plugins - Epic Developer Community Forums

here is a preview screen from runtime modification sample, we only took a small set of parameters for this otherwise it could take forever to complete the ui blueprints:

Found the issue regarding the module not being found on Android. You need to add ā€œFGearPluginā€ to your PublicDependencyModuleNames in your Build.cs of your project.

Some suggestions and requests:

You have very much logic inside the AFGearVehicle class. Most of that should be inside of a component instead. The reason for that is it makes inheritance easier. For example in my project I have a base class ā€œAVehicleā€ that inherits APawn. Now there is ABoat, AHelicopter, AWheeledVehicle and APlane. All of them inherit AVehicle.
For cars I use the default UE4 vehicles right now so I just have to add some components to AWheeledVehicle. If I wanted to use your plugin I would need to copy everything from AFGearVehicle to AWheeledVehicle.

Do not override UPhysicalMaterial. It just makes everything harder for existing projects to use your plugin. I would need to recreate all physical materials. It also prevents users from defining settings per vehicle (friction, roughness, smoke particles etc.)
Instead do it similar to UE4ā€™s vehicle system. They have a tire config class where you can define friction etc. per physical material surface. You can then assign the tire config per wheel. (You already have UFGearTire or UFGearWheelOptions that you could use here.)

Do not override USkeletalMeshComponent. Basically same as above. Makes it hard to switch to your plugin. I also see no usage of your custom class in the code.

Replication! I know itā€™s already on your list, just saying this is important.

Backfire detection for the effects class. Somebody else already suggested.

Support for more platforms. Probably works but if you could support Linux and Mac that would be great.