Activating Telemetry Output
In ‘my Documents\The Crew’ folder, create a file ExtraConfig.xml.
In this file add those lines
<ExtraConfig
phys_out_sim="127.0.0.1:1337"
phys_out_sim_rate="3"
phys_out_nitro_lean="0.5"
/>
phys_out_sim address: port
Send UDP telemetry packet to address: port.
phys_out_sim_rate X
To control the send rate
1 = send 1 time every 1 physics frame
2 = send 1 time every 2 physics frame
Etc..
Physics engine is refreshed at 300hz. So phys_out_sim_rate 3, will send UDP packet at 100hz.
phys_out_nitro_lean
Will add extra lean in the pitch values when nitro is used
UDP Packet structure
struct SUDPPacket
{
uInt32 time;
float angularVelocity[3];
float orientation[3];
float acceleration[3];
float velocity[3];
uInt32 position[3];
uInt32 gameID;
};
Accelerations and Velocities are in *car coordinate*
Positions and Orientations are in *world coordinate*
Coordinate are right handed, Z is vertical, Y is pointing front, and so X is pointing right.
- time : is incremented every paquet sent - no dimension
- angularVelocity : angular velocity ( pitch, roll, yaw ) - Rad/s
- orientation : euler angles ( Yaw, Pitch Roll ) in radians. - Rad "Note that it’s not same order than angular velocity, because orientation is in World Coordinate !"
- velocity : linear velocity ( lateral,longitudinal,vertical ) - m/s
- acceleration : linear acceleration ( lateral,longitudinal,vertical ) - m/s²
- position : position in world ( x,y,z ) - m*65536
- gameID : 1 - no dimension
Position is not precise and should not be used, but for reference this is world position in meter * 65536.
As the world in the crew is very huge, 125x85 Km ( 125000x85000 m ), the position are between (819187500x5570560000) which is way out of bound of U32 integer.