Clean up a couple of rotatesprite uses.

The black translucent background underneath the user map list will now
be drawn with a shade 32 tile 0 instead of tile BLANK, since I've seen
the latter being replaced in some mod. Also, it will look the same
regardless of screen aspect.

git-svn-id: https://svn.eduke32.com/eduke32@2928 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2012-08-19 12:56:51 +00:00
parent b07b540c0b
commit 88eb1fac78
5 changed files with 18 additions and 13 deletions

View File

@ -2073,8 +2073,9 @@ void drawpoly(double *dpx, double *dpy, int32_t n, int32_t method)
oy = ox2*gstang + oy2*gctang;
oz = oz2;
#ifdef OBSOLETE_RENDMODES
if ((oz < SCISDIST) && (rendmode < 3)) return; //annoying hack to avoid bugs in software rendering
#endif
r = ghalfx / oz;
dd[j] = (dpx[i]*gdx + dpy[i]*gdy + gdo)*r;

View File

@ -322,7 +322,7 @@ int32_t _EnterText(int32_t small,int32_t x,int32_t y,char *t,int32_t dalen,int32
}
if (small&1)
rotatesprite_fs(textsc(x)<<16,(y<<16),32768,0,SPINNINGNUKEICON+((totalclock>>3)%7),c,0,(small&1)?(8|16):2+8);
else rotatesprite_fs((x+((small&1)?4:8))<<16,((y+((small&1)?0:4))<<16),32768,0,SPINNINGNUKEICON+((totalclock>>3)%7),c,0,(small&1)?(8|16):2+8);
rotatesprite_fs(textsc(x)<<16,(y<<16),32768,0,SPINNINGNUKEICON+((totalclock>>3)%7),c,0,(8|16));
else rotatesprite_fs((x+8)<<16,(y+4)<<16,32768,0,SPINNINGNUKEICON+((totalclock>>3)%7),c,0,2+8);
return (0);
}

View File

@ -606,8 +606,8 @@ static void modval(int32_t min, int32_t max,int32_t *p,int32_t dainc,int32_t dam
// ((x==X)*(-sh))
#define PHX(X) 0
// ((x==X)?1:2)
#define MWIN(X) rotatesprite( 320<<15,200<<15,X,0,MENUSCREEN,-16,0,10+64,0,0,xdim-1,ydim-1)
#define MWINXY(X,OX,OY) rotatesprite( ( 320+(OX) )<<15, ( 200+(OY) )<<15,X,0,MENUSCREEN,-16,0,10+64,0,0,xdim-1,ydim-1)
//#define MWIN(X) rotatesprite( 320<<15,200<<15,X,0,MENUSCREEN,-16,0,10+64,0,0,xdim-1,ydim-1)
//#define MWINXY(X,OX,OY) rotatesprite( ( 320+(OX) )<<15, ( 200+(OY) )<<15,X,0,MENUSCREEN,-16,0,10+64,0,0,xdim-1,ydim-1)
//extern int32_t G_LoadSaveHeader(char spot,struct savehead_ *saveh);
@ -2216,10 +2216,14 @@ cheat_for_port_credits:
rotatesprite_fs(160<<16,19<<16,65536L,0,MENUBAR,16,0,10);
menutext(160,24,0,0,"Select A User Map");
// black translucent background underneath file lists
rotatesprite(0<<16, 0<<16, 65536l<<5, 0, BLANK, 0, 0, 10+16+1+32,
scale(40-4,xdim,320),scale(12+32-2,ydim,200),
scale(320-40+4,xdim,320)-1,scale(12+32+112+4,ydim,200)-1);
{
int32_t width = 160 - (40-4);
// black translucent background underneath file lists
rotatesprite(0<<16, 0<<16, 65536<<5, 0, /*tile*/ 0, numshades, 0, 10+16+1+32,
xdim/2-scale(width,(ydim*4)/3,320),scale(12+32-2,ydim,200),
xdim/2+scale(width,(ydim*4)/3,320)-1,scale(12+32+112+4,ydim,200)-1);
}
// path
minitext(38,45,boardfilename,16,26);

View File

@ -71,8 +71,8 @@ void GAME_drawosdstr(int32_t x, int32_t y, char *ch, int32_t len, int32_t shade,
if (ac < STARTALPHANUM || ac > ENDALPHANUM) { usehightile = ht; return; }
// use the format byte if the text falls within the bounds of the console buffer
rotatesprite(x<<16, (y<<3)<<16, 65536, 0, ac, (*(ch-ptr+fmt)&~0x1F)>>4,
*(ch-ptr+fmt)&~0xE0, 8|16, 0, 0, xdim-1, ydim-1);
rotatesprite_fs(x<<16, (y<<3)<<16, 65536, 0, ac, (*(ch-ptr+fmt)&~0x1F)>>4,
*(ch-ptr+fmt)&~0xE0, 8|16);
x += OSDCHAR_WIDTH+1;
ch++;
}

View File

@ -2004,10 +2004,10 @@ static int32_t P_DisplayFist(int32_t gs,int32_t snum)
fistpal = get_hud_pal(ps);
rotatesprite(
rotatesprite_fs(
(-fisti+222+(g_player[snum].sync->avel>>4))<<16,
(looking_arc+fistz)<<16,
fistzoom,0,FIST,gs,fistpal,2,0,0,xdim-1,ydim-1);
fistzoom,0,FIST,gs,fistpal,2);
return 1;
}