i worked my self through this tutorial and this addition.
In there, they basically tell you how you can set up the rotation of the wheel depending on the movement of the master control.
However, I struggle to set up the second part with the direction vector. The calculating snippet of the guy looks like this:
local posIncrement = 0.0 as float posIncrement = length((master.pos - (at time (currentTime-1) master.pos)) * master.transform.row2) rotation = (posIncrement+storedDistance)/(wheelRadius)
so how do I get the posIncrement Calculation into the parameter wiring?
I only got that far to take the normal X_Position and divide it by the radius from a spline circle (which I use as dummy to define the radius of the wheels. so the rig gets more reusable)
However, if I try to add the calculation to the wire parameter, I get the following error: “Incompatible types: 0.0, and undefined”
My obviously wrong code looks like that:
local posIncrement = 0.0 as float posIncrement = length(($car_master_rig.pos - (at time (currentTime-1) $car_master_rig.pos)) * $car_master_rig.transform.row2) (posIncrement+storedDistance)/($master_wheel.radius)