mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-14 16:40:52 +00:00
- Blood: Fix shotgun ammo display when player fires a shell, switches weapons, then switches back.
* Such a circumstance reloads the weapon off screen. * While the "right" fix would be to stop that, some fanatics will probably be relying on such a mechanism. * As such, just fudge the printout on the screen instead 🙃. * Fixes #877.
This commit is contained in:
parent
e8f2f98473
commit
30f9ec5fd8
1 changed files with 3 additions and 0 deletions
|
@ -688,6 +688,9 @@ class BloodStatusBar : RazeStatusBar
|
|||
}
|
||||
else
|
||||
{
|
||||
bool stateNeedsEvenAmt = pPlayer.weaponState == 3 || pPlayer.weaponState == 1;
|
||||
bool stateNeedsOddAmt = pPlayer.weaponState == 2;
|
||||
num += stateNeedsEvenAmt && (num % 2) || stateNeedsOddAmt && !(num % 2);
|
||||
int clip = CalcMagazineAmount(num, 2, pPlayer.weaponState == 1);
|
||||
int total = num - clip;
|
||||
String format = String.Format("%d/%d", clip, num - clip);
|
||||
|
|
Loading…
Reference in a new issue