Is there any way to access the Tire Type in blueprint?

I was hoping to be able to access the Tire Data Asset in a blueprint.

What I am trying to do change the friction scale value for the back tires. I want the E brake to not so much slow the car as make the end drift out more, but I don’t want this to be the default behavior. Is there any way to access this through the blueprint? Either to change this specific value in the data asset or change the tire to another Tire Data Asset and switch it back when the e brake is no longer in use. Thanks.

Hello Frate,

I don’t believe there is a way to reference Tire Types from inside of blueprints at the moment. This does seem like a useful feature however. I’ve placed a feature request in to have the Tire Types exposed to blueprints so that they’ll be editable in this way. For reference, the report number is UE-27020

Have a nice day!

Editing TireTypes at runtime as they are an ‘asset’ (like a mesh or texture), not something created at runtime. They could be shared by multiple vehicles. I agree it would be nice to control friction on a per-vehicle basis, but that would need some thought and would be implemented in a different way.

This can be done. Just inherit UWheeledVehicleMovementComponent4W and add the following function:

    UMyWheeledVehicleMovementComponent4W::SwitchTires(UTireType* NewTireType)
    {
    	for (PxU32 Index = 0; Index < PVehicleDrive->mWheelsSimData.getNbWheels(); Index++)
    	{
    		PxVehicleTireData oldTire = PVehicleDrive->mWheelsSimData.getTireData(Index);
    		PxVehicleTireData newTire;
    		newTire.mLatStiffX = oldTire.mLatStiffX;
    		newTire.mLatStiffY = oldTire.mLatStiffY;
    		newTire.mLongitudinalStiffnessPerUnitGravity = oldTire.mLongitudinalStiffnessPerUnitGravity;
    		newTire.mCamberStiffnessPerUnitGravity = oldTire.mCamberStiffnessPerUnitGravity;
    		memcpy(newTire.mFrictionVsSlipGraph, oldTire.mFrictionVsSlipGraph, sizeof(PxReal) * 3 * 2);
    		newTire.mType = NewTireType->GetTireTypeID();
    		PVehicleDrive->mWheelsSimData.setTireData(Index, newTire);
    	}
    }

You can modify as you wish.

Earlyer today i have setup a tire system wich you can easyly just swap out tireClasses on runtime. link text