After reviewing some of the code for this mod, it just appears you're adding steering wheel binding for the players movement bindings (which is used for vehicles like the Company Cruiser, of course) but from what I can tell this isn't going to automatically make your steering wheel match up with the Company Cruisers and allow you full control over the steering, there are two main issues I'd like to explain:
- The Company Cruiser has a bug where the actual steering angle de-syncs from the visual steering wheel, you would ideally need to fix this before anything, for steering-wheel sim support, I would suggest patching
Update on VehicleController with:
// prevent patching modded vehicles
if (__instance.vehicleID != 0)
return;
// 50f * steeringWheelAnimFloat is used by the visual front-tyres, so use that as it makes the most sense
__instance.FrontLeftWheel.steerAngle = 50f * __instance.steeringWheelAnimFloat
__instance.FrontRightWheel.steerAngle = 50f * __instance.steeringWheelAnimFloat
This will use the same calculation that is used for the visual front-tyres, which makes sense to me, and now it allows the steering-wheels-float to control the rotation of the front-wheels.
However, please note, the following mods: BetterVehicleControls, CruiserImproved, CruiserAdditions and LethalFixes all apply steeringAngle / 6f directly to steeringWheelAnimFloat , which deletes 2/3s of the steering-wheels animation to "fix" the de-sync bug without changing steering behaviour. For a mod that is meant to allow a sim-wheel to work with the Cruiser, this would not be ideal, as most sim wheels typically allow up to 900 or more degrees of rotation, the Cruiser's steering wheel animation has a full 940. If you try to change the steerAngle calculation, but a mod applies steeringAngle / 6f to steeringWheelAnimFloat , then you will end up being unable to turn the front wheels more than 16.666 (recurring) degrees.
tl;dr mods that mess with the steering-wheel animation would not be compatible, so looking into patching these mods to stop that patch from working would be ideal
- The Company Cruiser increments the steering wheel by the players input, so even if you map the steering wheel (say -1 for left, 0 for no input (neutral/straight) and 1 for right) then it's just going to be incrementing the steering wheel constantly until it reaches either the minimum clamp or the maximum clamp (-0.99 or 0.99 respectively), this could lead to "my sim-wheel is halfway to the left, and I'm not touching it, but the Company Cruisers steering-wheel keeps turning all the way to the left but slowly". Ideally, you would need to directly map the sim-wheels rotation from a -1 to 1 float and apply it to
steeringWheelAnimFloat , which would allow you to actually control the position of the wheel, rather than incrementing it.
After reviewing some of the code for this mod, it just appears you're adding steering wheel binding for the players movement bindings (which is used for vehicles like the Company Cruiser, of course) but from what I can tell this isn't going to automatically make your steering wheel match up with the Company Cruisers and allow you full control over the steering, there are two main issues I'd like to explain:
UpdateonVehicleControllerwith:This will use the same calculation that is used for the visual front-tyres, which makes sense to me, and now it allows the steering-wheels-float to control the rotation of the front-wheels.
However, please note, the following mods: BetterVehicleControls, CruiserImproved, CruiserAdditions and LethalFixes all apply
steeringAngle / 6fdirectly tosteeringWheelAnimFloat, which deletes 2/3s of the steering-wheels animation to "fix" the de-sync bug without changing steering behaviour. For a mod that is meant to allow a sim-wheel to work with the Cruiser, this would not be ideal, as most sim wheels typically allow up to 900 or more degrees of rotation, the Cruiser's steering wheel animation has a full 940. If you try to change thesteerAnglecalculation, but a mod appliessteeringAngle / 6ftosteeringWheelAnimFloat, then you will end up being unable to turn the front wheels more than 16.666 (recurring) degrees.tl;dr mods that mess with the steering-wheel animation would not be compatible, so looking into patching these mods to stop that patch from working would be ideal
steeringWheelAnimFloat, which would allow you to actually control the position of the wheel, rather than incrementing it.