mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-15 01:01:33 +00:00
now that V_FLIP's effects are always supported in V_DrawFixedPatch, there's no need for the "flip" variable anymore
This commit is contained in:
parent
2fa0896fd0
commit
22e8dd1f9d
1 changed files with 2 additions and 6 deletions
|
@ -331,7 +331,6 @@ void V_DrawFixedPatch(fixed_t x, fixed_t y, fixed_t pscale, INT32 scrn, patch_t
|
|||
{
|
||||
UINT8 (*patchdrawfunc)(const UINT8*, const UINT8*, fixed_t);
|
||||
UINT32 alphalevel = 0;
|
||||
boolean flip = false;
|
||||
|
||||
fixed_t col, ofs, colfrac, rowfrac, fdup;
|
||||
INT32 dupx, dupy;
|
||||
|
@ -415,10 +414,7 @@ void V_DrawFixedPatch(fixed_t x, fixed_t y, fixed_t pscale, INT32 scrn, patch_t
|
|||
|
||||
// left offset
|
||||
if (scrn & V_FLIP)
|
||||
{
|
||||
flip = true;
|
||||
offsetx = FixedMul((SHORT(patch->width) - SHORT(patch->leftoffset))<<FRACBITS, pscale) + 1;
|
||||
}
|
||||
else
|
||||
offsetx = FixedMul(SHORT(patch->leftoffset)<<FRACBITS, pscale);
|
||||
|
||||
|
@ -510,7 +506,7 @@ void V_DrawFixedPatch(fixed_t x, fixed_t y, fixed_t pscale, INT32 scrn, patch_t
|
|||
for (col = 0; (col>>FRACBITS) < SHORT(patch->width); col += colfrac, ++offx, desttop++)
|
||||
{
|
||||
INT32 topdelta, prevdelta = -1;
|
||||
if (flip) // offx is measured from right edge instead of left
|
||||
if (scrn & V_FLIP) // offx is measured from right edge instead of left
|
||||
{
|
||||
if (x+pwidth-offx < 0) // don't draw off the left of the screen (WRAP PREVENTION)
|
||||
break;
|
||||
|
@ -534,7 +530,7 @@ void V_DrawFixedPatch(fixed_t x, fixed_t y, fixed_t pscale, INT32 scrn, patch_t
|
|||
prevdelta = topdelta;
|
||||
source = (const UINT8 *)(column) + 3;
|
||||
dest = desttop;
|
||||
if (flip)
|
||||
if (scrn & V_FLIP)
|
||||
dest = deststart + (destend - desttop);
|
||||
dest += FixedInt(FixedMul(topdelta<<FRACBITS,fdup))*vid.width;
|
||||
|
||||
|
|
Loading…
Reference in a new issue