mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 08:52:00 +00:00
- simplify some of my math in the the fullscreen HUD drawers.
May no one ever see the original code again... :S
This commit is contained in:
parent
5cb3562bc1
commit
4e0bef35c0
3 changed files with 3 additions and 6 deletions
|
@ -167,8 +167,7 @@ public:
|
|||
auto strlen = format.Len();
|
||||
if (strlen > 1)
|
||||
{
|
||||
auto scaler = strlen - 1;
|
||||
imgX += ((imgX / 2.) * scaler) + ((imgX / (10. * scale)) * scaler);
|
||||
imgX += (imgX * 0.6) * (strlen - 1);
|
||||
}
|
||||
DrawGraphic(imgWeap, -imgX, -1.5, DI_ITEM_RIGHT_BOTTOM, 1, -1, -1, weapScale, weapScale);
|
||||
}
|
||||
|
|
|
@ -153,8 +153,7 @@ public:
|
|||
auto strlen = format.Len();
|
||||
if (strlen > 1)
|
||||
{
|
||||
auto scaler = strlen - 1;
|
||||
imgX += ((imgX / 2.) * scaler) + ((imgX / (7.8125 * scale)) * scaler);
|
||||
imgX += (imgX * 0.755) * (strlen - 1);
|
||||
}
|
||||
DrawGraphic(imgWeap, -imgX, -2, DI_ITEM_RIGHT_BOTTOM, 1, -1, -1, weapScale, weapScale);
|
||||
}
|
||||
|
|
|
@ -810,8 +810,7 @@ private:
|
|||
auto strlen = format.Len();
|
||||
if (strlen > 1)
|
||||
{
|
||||
auto scaler = strlen - 1;
|
||||
imgX += ((imgX / 2.) * scaler) + ((imgX / 2.85) * scaler);
|
||||
imgX += (imgX * 0.855) * (strlen - 1);
|
||||
}
|
||||
DrawGraphic(imgWeap, -imgX, -1, DI_ITEM_RIGHT_BOTTOM, 1, -1, -1, weapScale, weapScale);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue