Speedometer is not accurate

So these lines of codes should show me the current meters per second of my player, but the actual float just doesnt seem right. What I mean is that, when idle, the value is something random such as: 1.376649e-05 not 0? And when walking the value also changes constantly.

The code that im using that every post seems to recommend

var vel: Vector3 = rb.velocity;
vel.y = 0;
mph = vel.magnitude * 2.237;

Change your var to int. That’ll display a more whole number (0, 1, 2, 3 vs 1.38927398127)

Also, why are you vel.y = 0? that doesn’t seem necessary.