mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-15 17:22:12 +00:00
* Prevent (extremely unlikely) wraparound of patch frame calculation for the epynomous Radio (sigsegv prevention).
* Use thinstring for Authors field on the screen.
This commit is contained in:
parent
d591554a5d
commit
7b640bc81e
1 changed files with 3 additions and 1 deletions
|
@ -7109,6 +7109,8 @@ static void M_DrawSoundTest(void)
|
|||
|
||||
work = FixedDiv(work*180, bpm);
|
||||
frame[0] = 8-(work/(20<<FRACBITS));
|
||||
if (frame[0] > 8) // VERY small likelihood for the above calculation to wrap, but it turns out it IS possible lmao
|
||||
frame[0] = 0;
|
||||
ang = (FixedAngle(work)>>ANGLETOFINESHIFT) & FINEMASK;
|
||||
bounce = (FINESINE(ang) - FRACUNIT/2);
|
||||
hscale -= bounce/16;
|
||||
|
@ -7184,7 +7186,7 @@ static void M_DrawSoundTest(void)
|
|||
}
|
||||
|
||||
if (curplaying)
|
||||
V_DrawRightAlignedString(BASEVIDWIDTH-16, 46, V_ALLOWLOWERCASE, curplaying->authors);
|
||||
V_DrawRightAlignedThinString(BASEVIDWIDTH-16, 46, V_ALLOWLOWERCASE, curplaying->authors);
|
||||
}
|
||||
|
||||
V_DrawFill(165, 60, 140, 112, 159);
|
||||
|
|
Loading…
Reference in a new issue