]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commit
strafehud: improve efficiency and code readability
authorJuhu <5894800-Juhu_@users.noreply.gitlab.com>
Thu, 5 Sep 2024 17:30:54 +0000 (19:30 +0200)
committerJuhu <5894800-Juhu_@users.noreply.gitlab.com>
Thu, 5 Sep 2024 17:35:15 +0000 (19:35 +0200)
commit69c8578a3e2604227e36f593d315e55aba388911
tree15deb7a0b476f3b348e06f92a7164e784dfb90af
parent06aeebfb139e17c159378fd032c4dc1ff5419ee2
strafehud: improve efficiency and code readability

reduce number of conversions between angles and offsets

early out for projection functions in linear mode

if clause now properly encloses call to projection function

deduplicated some calculations in the strafe meter function
qcsrc/client/hud/panel/strafehud/core.qc
qcsrc/client/hud/panel/strafehud/draw.qc
qcsrc/client/hud/panel/strafehud/util.qc