//constant definitions:
float PRECACHE_PIC_FROMWAD = 1; // this one actually is part of EXT_CSQC
float PRECACHE_PIC_NOTPERSISTENT = 2; // picture may get deallocated when unused
-float PRECACHE_PIC_NOCLAMP = 4; // do not clamp to edge
float PRECACHE_PIC_MIPMAP = 8; // mipmap the texture for possibly better downscaling at memory expense
//notes: these constants are given as optional second argument to precache_pic()
//constant definitions:
float PRECACHE_PIC_FROMWAD = 1; // this one actually is part of EXT_CSQC
float PRECACHE_PIC_NOTPERSISTENT = 2; // picture may get deallocated when unused
-float PRECACHE_PIC_NOCLAMP = 4; // do not clamp to edge
float PRECACHE_PIC_MIPMAP = 8; // mipmap the texture for possibly better downscaling at memory expense
//notes: these constants are given as optional second argument to precache_pic()
return precache_pic(pic);
}
+string draw_PreloadPictureWithFlags(string pic, float f)
+{
+ pic = draw_UseSkinFor(pic);
+ return precache_pic(pic, f);
+}
+
void draw_Picture(vector theOrigin, string pic, vector theSize, vector theColor, float theAlpha)
{
if(theSize_x == 0 || theSize_y <= 0) // no default sizing please
void draw_drawMousePointer(vector where);
string draw_PreloadPicture(string pic);
+string draw_PreloadPictureWithFlags(string pic, float f);
void draw_ButtonPicture(vector theOrigin, string pic, vector theSize, vector theColor, float theAlpha);
void draw_VertButtonPicture(vector theOrigin, string pic, vector theSize, vector theColor, float theAlpha);
void draw_BorderPicture(vector theOrigin, string pic, vector theSize, vector theColor, float theAlpha, vector theBorderSize);
}
void XonoticGametypeList_configureXonoticGametypeList(entity me)
{
- me.loadCvars(me);
+ float i;
me.configureXonoticListBox(me);
me.nItems = GameType_GetCount();
+
+ // we want the pics mipmapped
+ for(i = 0; i < GameType_GetCount(); ++i)
+ draw_PreloadPictureWithFlags(GameType_GetIcon(i), PRECACHE_PIC_MIPMAP);
+
+ me.loadCvars(me);
}
void XonoticGametypeList_setSelected(entity me, float i)
{