+ if (showspeed.integer)
+ {
+ double speed, speedxy, f;
+ const char *unit;
+ speed = VectorLength(cl.movement_velocity);
+ speedxy = sqrt(cl.movement_velocity[0] * cl.movement_velocity[0] + cl.movement_velocity[1] * cl.movement_velocity[1]);
+ switch(showspeed.integer)
+ {
+ default:
+ case 1:
+ unit = "qups";
+ f = 1.0;
+ break;
+ case 2:
+ unit = "m/s";
+ f = 0.0254;
+ if(gamemode != GAME_NEXUIZ) f *= 1.5;
+ // 1qu=1.5in is for non-Nexuiz only - Nexuiz players are overly large, but 1qu=1in fixes that
+ break;
+ case 3:
+ unit = "km/h";
+ f = 0.0254 * 3.6;
+ if(gamemode != GAME_NEXUIZ) f *= 1.5;
+ break;
+ case 4:
+ unit = "mph";
+ f = 0.0254 * 3.6 * 0.6213711922;
+ if(gamemode != GAME_NEXUIZ) f *= 1.5;
+ break;
+ case 5:
+ unit = "knots";
+ f = 0.0254 * 1.943844492;
+ if(gamemode != GAME_NEXUIZ) f *= 1.5;
+ break;
+ }
+ dpsnprintf(speedstring, sizeof(speedstring), "%.0f (%.0f) %s", f*speed, f*speedxy, unit);
+ }
+ if (fpsstring[0] || timestring[0] || datestring[0] || speedstring[0])