I'm trying to figure out how to measure a vehicle's acceleration, but I'm running into two problems:
1) Acceleration values log fine for normal Pawns (not in a vehicle), but trying to log the vehicle's values gets 0 all the time.
2) The acceleration values are absolute, meaning they follow the world's XYZ values instead of the Pawn's rotational XYZ values.
I'm thinking I can use VSize(Velocity), then compare the rotation of the velocity with the last measured value against the pawn's rotation, and use sin/cos to figure out acceleration for X and Y, but I'm hoping there's an easier way.
1) Acceleration values log fine for normal Pawns (not in a vehicle), but trying to log the vehicle's values gets 0 all the time.
2) The acceleration values are absolute, meaning they follow the world's XYZ values instead of the Pawn's rotational XYZ values.
I'm thinking I can use VSize(Velocity), then compare the rotation of the velocity with the last measured value against the pawn's rotation, and use sin/cos to figure out acceleration for X and Y, but I'm hoping there's an easier way.
Comment