projects
/
xonotic
/
xonotic-data.pk3dir.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e3c61d7
)
Improve distribution of the icons and therefore use of the available space in the...
author
terencehill <piuntn@gmail.com>
Sun, 25 Jan 2015 18:25:32 +0000
(19:25 +0100)
committer
terencehill <piuntn@gmail.com>
Sun, 25 Jan 2015 18:26:51 +0000
(19:26 +0100)
qcsrc/client/hud.qc
patch
|
blob
|
history
diff --git
a/qcsrc/client/hud.qc
b/qcsrc/client/hud.qc
index 2b067dee82e5d997e19a15c4861a898ba4167af8..e9ed89cd385f50a1bf2ff0d50dc1e5494172c951 100644
(file)
--- a/
qcsrc/client/hud.qc
+++ b/
qcsrc/client/hud.qc
@@
-531,13
+531,8
@@
void HUD_Weapons(void)
// reduce rows and columns as needed
float columns_save = columns;
- if(weapon_count <= rows)
- {
- rows = weapon_count;
- columns = 1;
- }
- else
- columns = ceil(weapon_count / rows);
+ columns = ceil(weapon_count / rows);
+ rows = ceil(weapon_count / columns);
// enlarge weapon_size to match desired aspect ratio in order to capitalize on panel space
if(columns < columns_save)