mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-17 18:21:10 +00:00
Essentially - show how close the numwadfiles is getting to the maximum as WELL as the packetsizetally.
This commit is contained in:
parent
d3bd17d862
commit
cbe56b1b06
1 changed files with 4 additions and 1 deletions
|
@ -4870,11 +4870,14 @@ static void M_DrawAddons(void)
|
||||||
|
|
||||||
if (numwadfiles <= mainwads+1)
|
if (numwadfiles <= mainwads+1)
|
||||||
y = 0;
|
y = 0;
|
||||||
else if (numwadfiles >= MAX_WADFILES) // difficult to happen with current limits, but still worth thinking of
|
else if (numwadfiles >= MAX_WADFILES)
|
||||||
y = FRACUNIT;
|
y = FRACUNIT;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
x = FixedDiv((numwadfiles - mainwads+1)<<FRACBITS, (MAX_WADFILES - mainwads+1)<<FRACBITS);
|
||||||
y = FixedDiv(((packetsizetally-mainwadstally)<<FRACBITS), (((MAXFILENEEDED*sizeof(UINT8)-mainwadstally)-(5+22))<<FRACBITS)) + 1; // 5+22 = (a.ext + checksum length) is minimum addition to packet size tally
|
y = FixedDiv(((packetsizetally-mainwadstally)<<FRACBITS), (((MAXFILENEEDED*sizeof(UINT8)-mainwadstally)-(5+22))<<FRACBITS)) + 1; // 5+22 = (a.ext + checksum length) is minimum addition to packet size tally
|
||||||
|
if (x > y)
|
||||||
|
y = x;
|
||||||
if (y > FRACUNIT) // happens because of how we're shrinkin' it a little
|
if (y > FRACUNIT) // happens because of how we're shrinkin' it a little
|
||||||
y = FRACUNIT;
|
y = FRACUNIT;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue