seta hud_panel_physics_acceleration_max_slick "-1" "acceleration progressbar gets completely filled up by this value (in g) while on slick, -1 = same as the normal max"
seta hud_panel_physics_update_interval "0.015625" "how often (in seconds) numeric values get updated on screen"
seta hud_panel_physics_jumpspeed "0" "also show jump speed, replacing the speed unit text (NOTE: ignores vertical speed)"
-seta hud_panel_physics_jumpspeed_time "1" "how many seconds the jump speed takes to fade out"
+seta hud_panel_physics_jumpspeed_time "1" "how many seconds the jumpspeed text takes to fade out"
seta hud_panel_physics_force_layout "0" "1 = force speed and acceleration to be side-by-side, 2 = force them to be above one another"
seta hud_panel_itemstime_progressbar_maxtime "30" "when left time is at least this amount, the status bar is full"
seta hud_panel_physics_acceleration_max "" "acceleration progressbar gets completely filled up by this value (in g)"
seta hud_panel_physics_acceleration_progressbar_mode "" "0 = progressbar increases from the center to the right if the acceleration is positive, to the left if it's negative; 1 = progressbar increases from the border in the same direction for both positive and negative accelerations"
seta hud_panel_physics_acceleration_progressbar_scale "" "multiply acceleration progressbar values by this factor (allow progressbar to go out of panel bounds)"
-seta hud_panel_physics_acceleration_progressbar_nonlinear "" "use a non linear function to display acceleration progressbar values (amplify more smaller values)"
+seta hud_panel_physics_acceleration_progressbar_nonlinear "" "use a nonlinear function to display acceleration progressbar values (amplifies smaller values)"
seta hud_panel_physics_acceleration_vertical "" "include the acceleration on the Z-axis"
seta hud_panel_physics_text "" "show text in panel (2 = only for speed; 3 = only for acceleration)"
seta hud_panel_physics_text_scale "" "scale text height by this factor"
-seta hud_panel_physics_speed_unit_show "" "also show speed unit (NOTE: overriden if both topspeed and jumpspeed are shown)"
+seta hud_panel_physics_speed_unit_show "" "also show speed unit (NOTE: overridden if both topspeed and jumpspeed text are shown)"
seta hud_panel_physics_speed_max "" "speed progressbar gets filled up completely by this value (in qu/s)"
-seta hud_panel_physics_speed_vertical "" "include the speed on the Z-axis (NOTE: doesn't impact jumpspeed)"
+seta hud_panel_physics_speed_vertical "" "include the speed on the Z-axis (NOTE: doesn't affect jumpspeed text)"
seta hud_panel_physics_topspeed "" "also show top speed"
-seta hud_panel_physics_topspeed_time "" "how many seconds the top speed takes to fade out"
+seta hud_panel_physics_topspeed_time "" "how many seconds the topspeed text takes to fade out"
seta hud_panel_centerprint_pos "" "position of this base of the panel"
seta hud_panel_centerprint_size "" "size of this panel"
vector acc_prev_vel;
float acc_prev_time, acc_avg, top_speed, top_speed_time, jump_speed, jump_speed_time;
float prev_vel_z = 0, prev_speed2d = 0;
-float physics_update_time, discrete_speed, discrete_top_speed, discrete_accel; // not done for jump speed
+float physics_update_time, discrete_speed, discrete_top_speed, discrete_accel; // not done for jumpspeed
void HUD_Physics()
{
if (!autocvar__hud_configure)
vector tmp_offset = '0 0 0', tmp_size = '0 0 0';
float speed_size = 0.75;
- int text_bits = BITS(0); // describes which texts may be drawn. BIT(0) = top speed, BIT(1) = jump speed, BIT(2) = speed unit
+ int text_bits = BITS(0); // describes which texts may be drawn. BIT(0) = topspeed, BIT(1) = jumpspeed, BIT(2) = speed unit
// ordered by decreasing priority -- speed unit isn't drawn if the other two are,
- // ... and top speed takes priority over jump speed in the lower spot
+ // ... and topspeed takes priority over jumpspeed in the lower spot
// draw speed
if (!immobile)
HUD_Panel_DrawProgressBar(panel_pos + speed_offset, panel_size, "progressbar", speed / max_speed, 0, speed_baralign,
autocvar_hud_progressbar_speed_color, autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL);
- // compute jump speed text
+ // compute jumpspeed text
float jump_speed_f = 0;
if (autocvar_hud_panel_physics_jumpspeed)
if (autocvar_hud_panel_physics_text == PHYSICS_TEXT_BOTH || autocvar_hud_panel_physics_text == PHYSICS_TEXT_SPEED)
}
}
- // compute and draw top speed
+ // compute and draw topspeed
float top_speed_f = 0;
if (autocvar_hud_panel_physics_topspeed)
if (autocvar_hud_panel_physics_text == PHYSICS_TEXT_BOTH || autocvar_hud_panel_physics_text == PHYSICS_TEXT_SPEED)
top_speed = speed;
top_speed_time = time;
}
- if (top_speed == 0) // hide top speed 0
+ if (top_speed == 0) // hide topspeed 0
top_speed_f = 0;
else
{
top_speed_f = time_frac > 1 ? 0 : cos(time_frac * PI / 2);
}
}
- // top speed progressbar peak
+ // topspeed progressbar peak
if (top_speed_f > 0)
{
if (speed < top_speed)
top_speed_y = panel_size.y * (1 - main_text_size) / 2; // offset halved to center text
jump_speed_y = top_speed_y;
}
- else // both top speed and jump speed are drawn
+ else // both topspeed and jumpspeed are drawn
{
main_text_size = 0.5; // make them equal size
- top_speed_y = panel_size.y * (1 - main_text_size); // put top speed in the lower slot
- jump_speed_y = 0; // put jump speed in the upper slot
+ top_speed_y = panel_size.y * (1 - main_text_size); // put topspeed in the lower slot
+ jump_speed_y = 0; // put jumpspeed in the upper slot
}
- // draw jump speed text
+ // draw jumpspeed text
tmp_size.y = panel_size.y * main_text_size * text_scale;
if ((text_bits & BIT(1)) && jump_speed_f > 0)
{
tmp_offset.y = jump_speed_y;
drawstring_aspect(panel_pos + speed_offset + tmp_offset, ftos(jump_speed), tmp_size, '0 1 0', jump_speed_f * panel_fg_alpha, DRAWFLAG_NORMAL);
}
- // draw top speed text
+ // draw topspeed text
if ((text_bits & BIT(0)) && top_speed_f > 0)
{
top_speed_y += (panel_size.y * main_text_size - tmp_size.y) / 2;