// works for up to 10 decimals!
string ftos_decimals(float number, float decimals)
{
+ // inhibit stupid negative zero
+ if(number == 0)
+ number = 0;
// we have sprintf...
return sprintf("%.*f", decimals, number);
}
{
float eps;
eps = (max(a, -a) + max(c, -c)) * 0.001;
+ if(a > c)
+ eps = -eps;
return b == median(a - eps, b, c + eps);
}
ATTRIB(XonoticModelDialog, title, string, _("Model settings"))
ATTRIB(XonoticModelDialog, color, vector, SKINCOLOR_DIALOG_MODEL)
ATTRIB(XonoticModelDialog, intendedWidth, float, 0.5)
- ATTRIB(XonoticModelDialog, rows, float, 8)
+ ATTRIB(XonoticModelDialog, rows, float, 7)
ATTRIB(XonoticModelDialog, columns, float, 3)
ENDCLASS(XonoticModelDialog)
#endif
e.addValue(e, ZCTX(_("GIBS^Lots")), "0");
e.configureXonoticTextSliderValues(e);
setDependent(e, "cl_gentle", 0, 0);
- me.TR(me);
- me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Playermodel LOD:")));
- me.TD(me, 1, 2, e = makeXonoticSlider(0, 4, 0.1, "cl_playerdetailreduction"));
me.TR(me);
#ifdef ALLOW_FORCEMODELS
me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Force models:")));
e.addValue(e, ZCTX(_("DET^Best")), "2");
e.addValue(e, ZCTX(_("DET^Insane")), "1");
e.configureXonoticTextSliderValues(e);
+ me.TR(me);
+ me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Playermodel LOD:")));
+ me.TD(me, 1, 2, e = makeXonoticSlider(4, 0, -0.1, "cl_playerdetailreduction"));
me.TR(me);
me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Texture resolution:")));
me.TD(me, 1, 2, e = makeXonoticPicmipSlider());
e.addValue(e, ZCTX(_("RES^Good")), "-1");
e.addValue(e, ZCTX(_("RES^Best")), "-2");
e.configureXonoticTextSliderValues(e);
- me.TR(me);
me.TR(me);
{
// detect texture compression method