Subversion Repositories eduke32

Compare Revisions

Ignore whitespace Rev 876 → Rev 877

/polymer/build/include/baselayer.h
132,6 → 132,10
int setgamma(void);
float vid_gamma, vid_contrast, vid_brightness;
 
#define DEFAULT_GAMMA 1.2
#define DEFAULT_CONTRAST 1.2
#define DEFAULT_BRIGHTNESS 0.0
 
int switchrendermethod(int,int); // 0 = software, 1 = opengl | bool = reinit
 
int wm_msgbox(char *name, char *fmt, ...);
/polymer/build/src/baselayer.c
208,45 → 208,6
return OSDCMD_SHOWHELP;
}
 
static int osdcmd_vid_gamma(const osdfuncparm_t *parm)
{
if (parm->numparms != 1)
{
OSD_Printf("\"vid_gamma\" is \"%.1f\"\n",vid_gamma);
return OSDCMD_SHOWHELP;
}
vid_gamma = atof(parm->parms[0]);
OSD_Printf("%s\n",parm->raw);
setgamma();
return OSDCMD_OK;
}
 
static int osdcmd_vid_brightness(const osdfuncparm_t *parm)
{
if (parm->numparms != 1)
{
OSD_Printf("\"vid_brightness\" is \"%.1f\"\n",vid_brightness);
return OSDCMD_SHOWHELP;
}
vid_brightness = atof(parm->parms[0]);
OSD_Printf("%s\n",parm->raw);
setgamma();
return OSDCMD_OK;
}
 
static int osdcmd_vid_contrast(const osdfuncparm_t *parm)
{
if (parm->numparms != 1)
{
OSD_Printf("\"vid_contrast\" is \"%.1f\"\n",vid_contrast);
return OSDCMD_SHOWHELP;
}
vid_contrast = atof(parm->parms[0]);
OSD_Printf("%s\n",parm->raw);
setgamma();
return OSDCMD_OK;
}
 
int baselayer_init(void)
{
#ifdef POLYMOST
273,9 → 234,6
#endif
OSD_RegisterFunction("glinfo","glinfo: shows OpenGL information about the current OpenGL mode",osdcmd_glinfo);
#endif
OSD_RegisterFunction("vid_gamma","vid_gamma <gamma>: adjusts gamma ramp",osdcmd_vid_gamma);
OSD_RegisterFunction("vid_contrast","vid_contrast <gamma>: adjusts gamma ramp",osdcmd_vid_contrast);
OSD_RegisterFunction("vid_brightness","vid_brightness <gamma>: adjusts gamma ramp",osdcmd_vid_brightness);
return 0;
}
 
/polymer/build/src/engine.c
78,8 → 78,11
static int oxdimen = -1, oviewingrange = -1, oxyaspect = -1;
 
int curbrightness = 0, gammabrightness = 0;
float vid_gamma = 1.0, vid_contrast = 1.0, vid_brightness = 0.0;
 
float vid_gamma = DEFAULT_GAMMA;
float vid_contrast = DEFAULT_CONTRAST;
float vid_brightness = DEFAULT_BRIGHTNESS;
 
//Textured Map variables
static char globalpolytype;
static short *dotp1[MAXYDIM], *dotp2[MAXYDIM];
9991,8 → 9994,8
lastbright = curbrightness;
if (!(noapply&4))
curbrightness = min(max((int)dabrightness,0),15);
 
vid_gamma = 1.0 + ((float)curbrightness / 10.0);
if (lastbright != (unsigned)curbrightness)
vid_gamma = 1.0 + ((float)curbrightness / 10.0);
if (setgamma()) j = curbrightness; else j = 0;
 
for (k=i=0;i<256;i++)
/polymer/build/src/osd.c
834,12 → 834,10
if (tabc && tabc->next && findsymbol(osdedittmp, tabc->next))
{
symbol_t *symb=tabc;
int maxwidth = 0, x = 0, num = 0;
int maxwidth = 0, x = 0, num = 0, diffpt;
 
while (symb && symb != lastmatch)
{
int diffpt;
 
num++;
 
if (lastmatch)
846,14 → 844,12
{
diffpt = OSD_FindDiffPoint(symb->name,lastmatch->name);
if (diffpt < commonsize)
{
commonsize = diffpt;
// OSD_Printf("commonsize %d\n",commonsize);
}
}
 
maxwidth = max((unsigned)maxwidth,Bstrlen(symb->name));
lastmatch = symb;
if (!lastmatch->next) break;
symb=findsymbol(osdedittmp, lastmatch->next);
}
OSD_Printf(OSDTEXT_RED "Found %d possible completions for '%s':\n",num,osdedittmp);
864,6 → 860,7
{
tabc = lastmatch = symb;
OSD_Printf("%-*s",maxwidth,symb->name);
if (!lastmatch->next) break;
symb=findsymbol(osdedittmp, lastmatch->next);
x += maxwidth;
if (x > (osdcols - maxwidth))
/polymer/eduke32/source/config.c
653,15 → 653,15
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "ScreenGamma",&ud.brightness);
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "ScreenSize",&ud.screen_size);
 
tempbuf[0] = 0;
SCRIPT_GetString(ud.config.scripthandle, "Screen Setup", "VidGamma",&tempbuf[0]);
if (tempbuf[0]) vid_gamma = atof(tempbuf);
tempbuf[0] = 0;
SCRIPT_GetString(ud.config.scripthandle, "Screen Setup", "VidBrightness",&tempbuf[0]);
if (tempbuf[0]) vid_brightness = atof(tempbuf);
tempbuf[0] = 0;
SCRIPT_GetString(ud.config.scripthandle, "Screen Setup", "VidContrast",&tempbuf[0]);
if (tempbuf[0]) vid_contrast = atof(tempbuf);
tempbuf[0] = 0;
SCRIPT_GetString(ud.config.scripthandle, "Screen Setup", "VidGamma",&tempbuf[0]);
if (tempbuf[0]) vid_gamma = atof(tempbuf);
tempbuf[0] = 0;
SCRIPT_GetString(ud.config.scripthandle, "Screen Setup", "VidBrightness",&tempbuf[0]);
if (tempbuf[0]) vid_brightness = atof(tempbuf);
tempbuf[0] = 0;
SCRIPT_GetString(ud.config.scripthandle, "Screen Setup", "VidContrast",&tempbuf[0]);
if (tempbuf[0]) vid_contrast = atof(tempbuf);
 
#if defined(POLYMOST) && defined(USE_OPENGL)
SCRIPT_GetNumber(ud.config.scripthandle, "Screen Setup", "ScreenBPP", &ud.config.ScreenBPP);
/polymer/eduke32/source/game.c
364,35 → 364,35
return (x);
}
 
int gametextlen(int x,const char *t)
{
int ac;
 
if (t == NULL)
return -1;
 
while (*t)
{
if (*t == 32)
{
x+=5;
t++;
continue;
}
else ac = *t - '!' + STARTALPHANUM;
 
if (ac < STARTALPHANUM || ac > (STARTALPHANUM + 93))
break;
 
if ((*t >= '0' && *t <= '9'))
x += 8;
else x += tilesizx[ac];
t++;
}
 
return (x);
}
int gametextlen(int x,const char *t)
{
int ac;
 
if (t == NULL)
return -1;
 
while (*t)
{
if (*t == 32)
{
x+=5;
t++;
continue;
}
else ac = *t - '!' + STARTALPHANUM;
 
if (ac < STARTALPHANUM || ac > (STARTALPHANUM + 93))
break;
 
if ((*t >= '0' && *t <= '9'))
x += 8;
else x += tilesizx[ac];
t++;
}
 
return (x);
}
 
inline int gametext(int x,int y,const char *t,int s,int dabits)
{
return(gametext_z(0,STARTALPHANUM, x,y,t,s,0,dabits,0, 0, xdim-1, ydim-1, 65536));
/polymer/eduke32/source/gamedef.c
1847,7 → 1847,7
 
// get the ID of the DEF
if (tw == CON_SETTHISPROJECTILE)
labelsonly = 1;
labelsonly = 1;
transvar();
labelsonly = 0;
// now get name of .xxx
/polymer/eduke32/source/menus.c
315,9 → 315,9
return(menutext_(x,y,s,p,(char *)stripcolorcodes(t)));
}
 
static void bar_(int type, int x,int y,short *p,int dainc,int damodify,int s, int pa)
static void _bar(int type, int x,int y,int *p,int dainc,int damodify,int s, int pa, int min, int max)
{
short xloc;
int xloc;
char rev;
 
if (dainc < 0)
332,7 → 332,7
{
if (rev == 0)
{
if (*p > 0 && (KB_KeyPressed(sc_LeftArrow) || KB_KeyPressed(sc_kpad_4) || ((buttonstat&1) && (WHEELUP || mii < -256)))) // && onbar) )
if (*p > min && (KB_KeyPressed(sc_LeftArrow) || KB_KeyPressed(sc_kpad_4) || ((buttonstat&1) && (WHEELUP || mii < -256)))) // && onbar) )
{
KB_ClearKeyDown(sc_LeftArrow);
KB_ClearKeyDown(sc_kpad_4);
339,11 → 339,11
MOUSE_ClearButton(WHEELUP_MOUSE);
mii = 0;
*p -= dainc;
if (*p < 0)
*p = 0;
if (*p < min)
*p = min;
sound(KICK_HIT);
}
if (*p < 63 && (KB_KeyPressed(sc_RightArrow) || KB_KeyPressed(sc_kpad_6) || ((buttonstat&1) && (WHEELDOWN || mii > 256)))) //&& onbar) )
if (*p < max && (KB_KeyPressed(sc_RightArrow) || KB_KeyPressed(sc_kpad_6) || ((buttonstat&1) && (WHEELDOWN || mii > 256)))) //&& onbar) )
{
KB_ClearKeyDown(sc_RightArrow);
KB_ClearKeyDown(sc_kpad_6);
350,21 → 350,21
MOUSE_ClearButton(WHEELDOWN_MOUSE);
mii = 0;
*p += dainc;
if (*p > 63)
*p = 63;
if (*p > max)
*p = max;
sound(KICK_HIT);
}
}
else
{
if (*p > 0 && (KB_KeyPressed(sc_RightArrow) || KB_KeyPressed(sc_kpad_6) || ((buttonstat&1) && minfo.dyaw > 256))) //&& onbar) )
if (*p > min && (KB_KeyPressed(sc_RightArrow) || KB_KeyPressed(sc_kpad_6) || ((buttonstat&1) && minfo.dyaw > 256))) //&& onbar) )
{
KB_ClearKeyDown(sc_RightArrow);
KB_ClearKeyDown(sc_kpad_6);
 
*p -= dainc;
if (*p < 0)
*p = 0;
if (*p < min)
*p = min;
sound(KICK_HIT);
}
if (*p < 64 && (KB_KeyPressed(sc_LeftArrow) || KB_KeyPressed(sc_kpad_4) || ((buttonstat&1) && minfo.dyaw < -256))) // && onbar) )
373,8 → 373,8
KB_ClearKeyDown(sc_kpad_4);
 
*p += dainc;
if (*p > 64)
*p = 64;
if (*p > max)
*p = max;
sound(KICK_HIT);
}
}
381,16 → 381,15
}
 
xloc = *p;
 
rotatesprite((x<<16)+(22<<(16-type)),(y<<16)-(3<<(16-type)),65536L>>type,0,SLIDEBAR,s,pa,10,0,0,xdim-1,ydim-1);
if (rev == 0)
rotatesprite((x<<16)+((xloc+1)<<(16-type)),(y<<16)+(1<<(16-type)),65536L>>type,0,SLIDEBAR+1,s,pa,10,0,0,xdim-1,ydim-1);
rotatesprite((x<<16)+((scale(64,xloc-min,max-min)+1)<<(16-type)),(y<<16)+(1<<(16-type)),65536L>>type,0,SLIDEBAR+1,s,pa,10,0,0,xdim-1,ydim-1);
else
rotatesprite((x<<16)+((65-xloc)<<(16-type)),(y<<16)+(1<<(16-type)),65536L>>type,0,SLIDEBAR+1,s,pa,10,0,0,xdim-1,ydim-1);
rotatesprite((x<<16)+((65-scale(64,xloc-min,max-min))<<(16-type)),(y<<16)+(1<<(16-type)),65536L>>type,0,SLIDEBAR+1,s,pa,10,0,0,xdim-1,ydim-1);
}
 
#define bar(x,y,p,dainc,damodify,s,pa) bar_(0,x,y,p,dainc,damodify,s,pa);
#define barsm(x,y,p,dainc,damodify,s,pa) bar_(1,x,y,p,dainc,damodify,s,pa);
#define bar(x,y,p,dainc,damodify,s,pa) _bar(0,x,y,p,dainc,damodify,s,pa,0,63);
#define barsm(x,y,p,dainc,damodify,s,pa) _bar(1,x,y,p,dainc,damodify,s,pa,0,63);
 
static void modval(int min, int max,int *p,int dainc,int damodify)
{
2556,7 → 2555,69
}
#endif
break;
case 231:
rotatesprite(320<<15,19<<16,65536L,0,MENUBAR,16,0,10,0,0,xdim-1,ydim-1);
menutext(320>>1,24,0,0,"BRIGHTNESS");
 
c = (320>>1)-120;
 
x = 4;
 
onbar = 1;
x = probe(c,probey==3?58:50,16,x);
 
if (x == -1)
{
cmenu(203);
probey = 4;
break;
}
 
menutext(c,50,MENUHIGHLIGHT(0),0,"GAMMA");
menutext(c,50+16,MENUHIGHLIGHT(1),0,"CONTRAST");
menutext(c,50+16+16,MENUHIGHLIGHT(2),0,"BRIGHTNESS");
menutext(c,50+16+16+16+8,MENUHIGHLIGHT(3),0,"RESET TO DEFAULTS");
{
int b = (vid_gamma*40960.f);
_bar(0,c+171,50,&b,4096,x==0,MENUHIGHLIGHT(0),0,8192,163840);
 
if (b != (vid_gamma*40960.f))
{
vid_gamma = b/40960.f;
ud.brightness = min(max((float)((vid_gamma-1.0)*10.0),0),15);
ud.brightness <<= 2;
setgamma();
}
 
b = (vid_contrast*40960.f);
_bar(0,c+171,50+16,&b,4096,x==1,MENUHIGHLIGHT(1),0,4096,122880);
 
if (b != (vid_contrast*40960.f))
{
vid_contrast = b/40960.f;
setgamma();
}
 
b = (vid_brightness*40960.f);
_bar(0,c+171,50+16+16,&b,2048,x==2,MENUHIGHLIGHT(2),0,-32767,32767);
 
if (b != (vid_brightness*40960.f))
{
vid_brightness = b/40960.f;
setgamma();
}
 
if (x == 3)
{
vid_gamma = DEFAULT_GAMMA;
vid_contrast = DEFAULT_CONTRAST;
vid_brightness = DEFAULT_BRIGHTNESS;
setgamma();
}
}
 
break;
 
case 200:
 
rotatesprite(320<<15,19<<16,65536L,0,MENUBAR,16,0,10,0,0,xdim-1,ydim-1);
2640,7 → 2701,7
{
int i;
i = ud.screen_size;
barsm(d+8,yy+7, (short *)&ud.screen_size,-4,x==io,MENUHIGHLIGHT(io),PHX(-5));
barsm(d+8,yy+7, &ud.screen_size,-4,x==io,MENUHIGHLIGHT(io),PHX(-5));
if (i < ud.screen_size && i == 8 && ud.statusbarmode == 1 && bpp > 8)
{
ud.statusbarmode = 0;
2659,9 → 2720,9
break;
case 3:
{
short sbs, sbsl;
int sbs, sbsl;
sbs = sbsl = ud.statusbarscale-37;
barsm(d+8,yy+7, (short *)&sbs,8,x==io,MENUHIGHLIGHT(io),PHX(-5));
barsm(d+8,yy+7, &sbs,8,x==io,MENUHIGHLIGHT(io),PHX(-5));
if (x == io && sbs != sbsl)
{
sbs += 37;
2965,7 → 3026,7
#else
x = 6;
#endif
onbar = (probey == 4);
onbar = 0; // (probey == 4);
if (probey == 0 || probey == 1 || probey == 2)
x = probe(c,50,16,x);
else if (probey == 3)
3187,6 → 3248,7
break;
 
case 4:
cmenu(231);
break;
 
case 5:
3239,16 → 3301,16
menutext(c+16,50+16+16+22,MENUHIGHLIGHT(3),changesmade==0,"APPLY CHANGES");
 
menutext(c,50+62+16,MENUHIGHLIGHT(4),PHX(-6),"BRIGHTNESS");
{
short ss = ud.brightness;
bar(c+171,50+62+16,&ss,8,x==4,MENUHIGHLIGHT(4),PHX(-6));
if (x==4)
{
ud.brightness = ss;
setbrightness(ud.brightness>>2,&g_player[myconnectindex].ps->palette[0],0);
}
}
 
/* {
short ss = ud.brightness;
bar(c+171,50+62+16,&ss,8,x==4,MENUHIGHLIGHT(4),PHX(-6));
if (x==4)
{
ud.brightness = ss;
setbrightness(ud.brightness>>2,&g_player[myconnectindex].ps->palette[0],0);
}
}
*/
if (bpp == 8)
{
menutext(c,50+62+16+16,MENUHIGHLIGHT(5),0,"DETAIL");
3520,7 → 3582,7
gametextpal(40,122+9+9+9,"ADVANCED",MENUHIGHLIGHT((MAXMOUSEBUTTONS-2)*2+2+2+1),10);
 
{
short sense;
int sense;
sense = CONTROL_GetMouseSensitivity()-1;
barsm(248,128,&sense,2,x==(MAXMOUSEBUTTONS-2)*2+2,MENUHIGHLIGHT((MAXMOUSEBUTTONS-2)*2+2),PHX(-7));
CONTROL_SetMouseSensitivity(sense+1);
3774,7 → 3836,7
 
menutext(c,46,MENUHIGHLIGHT(0),0,"X-AXIS SCALE");
l = (ud.config.MouseAnalogueScale[0]+262144) >> 13;
bar(c+160+40,46,(short *)&l,1,x==0,MENUHIGHLIGHT(0),0);
bar(c+160+40,46,&l,1,x==0,MENUHIGHLIGHT(0),0);
l = (l<<13)-262144;
if (l != ud.config.MouseAnalogueScale[0])
{
3786,7 → 3848,7
 
menutext(c,46+16,MENUHIGHLIGHT(1),0,"Y-AXIS SCALE");
l = (ud.config.MouseAnalogueScale[1]+262144) >> 13;
bar(c+160+40,46+16,(short *)&l,1,x==1,MENUHIGHLIGHT(1),0);
bar(c+160+40,46+16,&l,1,x==1,MENUHIGHLIGHT(1),0);
l = (l<<13)-262144;
if (l != ud.config.MouseAnalogueScale[1])
{
3798,7 → 3860,7
 
menutext(c,46+16+16,MENUHIGHLIGHT(2),0,"DEAD ZONE");
l = ud.config.MouseFilter>>1;
bar(c+160+40,46+16+16,(short *)&l,2,x==2,MENUHIGHLIGHT(2),0);
bar(c+160+40,46+16+16,&l,2,x==2,MENUHIGHLIGHT(2),0);
ud.config.MouseFilter = l<<1;
menutext(c,46+16+16+16+8,/*(MENUHIGHLIGHT(3))+(MENUHIGHLIGHT(4))+(MENUHIGHLIGHT(5))+(MENUHIGHLIGHT(6))-24*/0,0,"DIGITAL AXES ACTIONS");
 
4053,7 → 4115,7
}
gametext(76,38,"SCALE",0,2+8+16);
l = (ud.config.JoystickAnalogueScale[thispage*2]+262144) >> 13;
bar(140+56,38+8,(short *)&l,1,x==0,0,0);
bar(140+56,38+8,&l,1,x==0,0,0);
l = (l<<13)-262144;
if (l != ud.config.JoystickAnalogueScale[thispage*2])
{
4094,7 → 4156,7
{
gametext(76,38+64,"SCALE",0,2+8+16);
l = (ud.config.JoystickAnalogueScale[thispage*2+1]+262144) >> 13;
bar(140+56,38+8+64,(short *)&l,1,x==4,0,0);
bar(140+56,38+8+64,&l,1,x==4,0,0);
l = (l<<13)-262144;
if (l != ud.config.JoystickAnalogueScale[thispage*2+1])
{
4172,7 → 4234,7
 
for (m=first;m<last;m++)
{
unsigned short odx,dx,ody,dy;
int odx,dx,ody,dy;
Bstrcpy(tempbuf,(char *)getjoyname(0,m));
menutext(32,48+30*(m-first),0,0,tempbuf);
 
4182,8 → 4244,8
dx = odx = min(64,64l*ud.config.JoystickAnalogueDead[m]/10000l);
dy = ody = min(64,64l*ud.config.JoystickAnalogueSaturate[m]/10000l);
 
bar(217,48+30*(m-first),(short *)&dx,4,x==((m-first)*2),0,0);
bar(217,48+30*(m-first)+15,(short *)&dy,4,x==((m-first)*2+1),0,0);
bar(217,48+30*(m-first),&dx,4,x==((m-first)*2),0,0);
bar(217,48+30*(m-first)+15,&dy,4,x==((m-first)*2+1),0,0);
 
Bsprintf(tempbuf,"%3d%%",100*dx/64);
gametext(217-49,48+30*(m-first)-8,tempbuf,0,2+8+16);
4294,7 → 4356,7
{
l = ud.config.FXVolume;
ud.config.FXVolume >>= 2;
bar(c+167+40,50+16+16,(short *)&ud.config.FXVolume,4,(ud.config.FXDevice>=0)&&x==2,MENUHIGHLIGHT(2),ud.config.SoundToggle==0||(ud.config.FXDevice<0));
bar(c+167+40,50+16+16,&ud.config.FXVolume,4,(ud.config.FXDevice>=0)&&x==2,MENUHIGHLIGHT(2),ud.config.SoundToggle==0||(ud.config.FXDevice<0));
if (l != ud.config.FXVolume)
ud.config.FXVolume <<= 2;
if (l != ud.config.FXVolume)
4306,7 → 4368,7
l = ud.config.MusicVolume;
ud.config.MusicVolume >>= 2;
bar(c+167+40,50+16+16+16,
(short *)&ud.config.MusicVolume,4,
&ud.config.MusicVolume,4,
(ud.config.MusicDevice>=0) && x==3,MENUHIGHLIGHT(3),
ud.config.MusicToggle==0||(ud.config.MusicDevice<0));
ud.config.MusicVolume <<= 2;
/polymer/eduke32/source/osdcmds.c
1232,6 → 1232,47
return OSDCMD_OK;
}
 
static int osdcmd_vid_gamma(const osdfuncparm_t *parm)
{
if (parm->numparms != 1)
{
OSD_Printf("\"vid_gamma\" is \"%.1f\"\n",vid_gamma);
return OSDCMD_SHOWHELP;
}
vid_gamma = atof(parm->parms[0]);
ud.brightness = min(max((float)((vid_gamma-1.0)*10.0),0),15);
ud.brightness <<= 2;
OSD_Printf("%s\n",parm->raw);
setgamma();
return OSDCMD_OK;
}
 
static int osdcmd_vid_brightness(const osdfuncparm_t *parm)
{
if (parm->numparms != 1)
{
OSD_Printf("\"vid_brightness\" is \"%.1f\"\n",vid_brightness);
return OSDCMD_SHOWHELP;
}
vid_brightness = atof(parm->parms[0]);
OSD_Printf("%s\n",parm->raw);
setgamma();
return OSDCMD_OK;
}
 
static int osdcmd_vid_contrast(const osdfuncparm_t *parm)
{
if (parm->numparms != 1)
{
OSD_Printf("\"vid_contrast\" is \"%.1f\"\n",vid_contrast);
return OSDCMD_SHOWHELP;
}
vid_contrast = atof(parm->parms[0]);
OSD_Printf("%s\n",parm->raw);
setgamma();
return OSDCMD_OK;
}
 
int registerosdcommands(void)
{
unsigned int i;
1302,7 → 1343,10
OSD_RegisterFunction("unbind","unbind <key>: unbinds a key.", osdcmd_unbind);
OSD_RegisterFunction("unbindall","unbindall: unbinds all keys.", osdcmd_unbindall);
 
OSD_RegisterFunction("vidmode","vidmode [xdim ydim] [bpp] [fullscreen]: immediately change the video mode",osdcmd_vidmode);
OSD_RegisterFunction("vidmode","vidmode [xdim ydim] [bpp] [fullscreen]: change the video mode",osdcmd_vidmode);
OSD_RegisterFunction("vid_gamma","vid_gamma <gamma>: adjusts gamma ramp",osdcmd_vid_gamma);
OSD_RegisterFunction("vid_contrast","vid_contrast <gamma>: adjusts gamma ramp",osdcmd_vid_contrast);
OSD_RegisterFunction("vid_brightness","vid_brightness <gamma>: adjusts gamma ramp",osdcmd_vid_brightness);
OSD_RegisterFunction("savestate","",osdcmd_savestate);
OSD_RegisterFunction("restorestate","",osdcmd_restorestate);
//baselayer_onvideomodechange = onvideomodechange;
/polymer/eduke32/source/savegame.c
89,12 → 89,12
// AddLog(g_szBuf);
 
if (kdfread(&bv,4,1,fil) != 1) goto corrupt;
/* if (bv != BYTEVERSION)
{
FTA(114,g_player[myconnectindex].ps);
kclose(fil);
return 1;
}*/
/* if (bv != BYTEVERSION)
{
FTA(114,g_player[myconnectindex].ps);
kclose(fil);
return 1;
}*/
 
if (kdfread(&saveh->numplr,sizeof(int32),1,fil) != 1) goto corrupt;