mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-11 18:50:46 +00:00
Use mod_dir for savegames
git-svn-id: https://svn.eduke32.com/eduke32@994 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
cbba90b7c2
commit
6def1b0a65
4 changed files with 10 additions and 7 deletions
|
@ -1057,6 +1057,9 @@ typedef struct {
|
||||||
extern keydef keynames[];
|
extern keydef keynames[];
|
||||||
extern char *mousenames[];
|
extern char *mousenames[];
|
||||||
|
|
||||||
|
extern char *duke3dgrp, *duke3dgrpstring;
|
||||||
|
extern char mod_dir[BMAX_PATH];
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -4623,7 +4623,6 @@ repeatcase:
|
||||||
if (Bstrcmp(setupfilename,"duke3d.cfg") == 0) // not set to something else via -cfg
|
if (Bstrcmp(setupfilename,"duke3d.cfg") == 0) // not set to something else via -cfg
|
||||||
{
|
{
|
||||||
char temp[BMAX_PATH];
|
char temp[BMAX_PATH];
|
||||||
extern char mod_dir[];
|
|
||||||
Bstrcpy(temp,tempbuf);
|
Bstrcpy(temp,tempbuf);
|
||||||
CONFIG_WriteSetup();
|
CONFIG_WriteSetup();
|
||||||
Bsprintf(setupfilename,"%s/",mod_dir);
|
Bsprintf(setupfilename,"%s/",mod_dir);
|
||||||
|
|
|
@ -83,7 +83,7 @@ int loadpheader(char spot,struct savehead *saveh)
|
||||||
strcpy(fn, "egam0.sav");
|
strcpy(fn, "egam0.sav");
|
||||||
fn[4] = spot+'0';
|
fn[4] = spot+'0';
|
||||||
|
|
||||||
if ((fil = kopen4load(fn,0)) == -1) return(-1);
|
if ((fil = kopen4loadfrommod(fn,0)) == -1) return(-1);
|
||||||
|
|
||||||
walock[TILE_LOADSHOT] = 255;
|
walock[TILE_LOADSHOT] = 255;
|
||||||
|
|
||||||
|
@ -161,7 +161,7 @@ int loadplayer(int spot)
|
||||||
fn[4] = spot + '0';
|
fn[4] = spot + '0';
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((fil = kopen4load(fnptr,0)) == -1) return(-1);
|
if ((fil = kopen4loadfrommod(fnptr,0)) == -1) return(-1);
|
||||||
|
|
||||||
ready2send = 0;
|
ready2send = 0;
|
||||||
|
|
||||||
|
@ -566,7 +566,11 @@ int saveplayer(int spot)
|
||||||
fn[4] = spot + '0';
|
fn[4] = spot + '0';
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((fil = fopen(fnptr,"wb")) == 0) return(-1);
|
{
|
||||||
|
char temp[BMAX_PATH];
|
||||||
|
Bsprintf(temp,"%s/%s",mod_dir,fnptr);
|
||||||
|
if ((fil = fopen(temp,"wb")) == 0) return(-1);
|
||||||
|
}
|
||||||
|
|
||||||
ready2send = 0;
|
ready2send = 0;
|
||||||
|
|
||||||
|
|
|
@ -600,9 +600,6 @@ int startwin_idle(void *v)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern char *duke3dgrp, *duke3dgrpstring;
|
|
||||||
extern char mod_dir[BMAX_PATH];
|
|
||||||
|
|
||||||
int startwin_run(void)
|
int startwin_run(void)
|
||||||
{
|
{
|
||||||
MSG msg;
|
MSG msg;
|
||||||
|
|
Loading…
Reference in a new issue