mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-11 18:50:46 +00:00
Increased BYTEVERSION, removed 1.3D demo versions from opendemoread() and added version 160 (Atomic Edition demos from the previous version of EDuke32) support
git-svn-id: https://svn.eduke32.com/eduke32@43 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
7ad252b0c7
commit
972e60b5f8
2 changed files with 9 additions and 8 deletions
|
@ -51,7 +51,7 @@ extern int shareware;
|
||||||
#define BYTEVERSION_13 27
|
#define BYTEVERSION_13 27
|
||||||
#define BYTEVERSION_14 116
|
#define BYTEVERSION_14 116
|
||||||
#define BYTEVERSION_15 117
|
#define BYTEVERSION_15 117
|
||||||
#define BYTEVERSION_JF 159 // increase by 3, because atomic GRP adds 1, and Shareware adds 2
|
#define BYTEVERSION_JF 162 // increase by 3, because atomic GRP adds 1, and Shareware adds 2
|
||||||
|
|
||||||
#define BYTEVERSION (BYTEVERSION_JF+(PLUTOPAK?1:(VOLUMEONE<<1))) // JBF 20040116: different data files give different versions
|
#define BYTEVERSION (BYTEVERSION_JF+(PLUTOPAK?1:(VOLUMEONE<<1))) // JBF 20040116: different data files give different versions
|
||||||
|
|
||||||
|
|
|
@ -8582,7 +8582,7 @@ char opendemoread(char which_demo) // 0 = mine
|
||||||
if (kread(recfilep,&ud.reccnt,sizeof(long)) != sizeof(long)) goto corrupt;
|
if (kread(recfilep,&ud.reccnt,sizeof(long)) != sizeof(long)) goto corrupt;
|
||||||
if (kread(recfilep,&ver,sizeof(char)) != sizeof(char)) goto corrupt;
|
if (kread(recfilep,&ver,sizeof(char)) != sizeof(char)) goto corrupt;
|
||||||
|
|
||||||
if(ver != BYTEVERSION && ver != 27 && ver != 28 && ver != 116 && ver != 117) { /* old demo playback */
|
if(ver != BYTEVERSION && ver != 160 && ver != 116 && ver != 117) { /* old demo playback */
|
||||||
if (ver == BYTEVERSION_JF) initprintf("Demo %s is for Regular edition.\n", d);
|
if (ver == BYTEVERSION_JF) initprintf("Demo %s is for Regular edition.\n", d);
|
||||||
else if (ver == BYTEVERSION_JF+1) initprintf("Demo %s is for Atomic edition.\n", d);
|
else if (ver == BYTEVERSION_JF+1) initprintf("Demo %s is for Atomic edition.\n", d);
|
||||||
else if (ver == BYTEVERSION_JF+2) initprintf("Demo %s is for Shareware version.\n", d);
|
else if (ver == BYTEVERSION_JF+2) initprintf("Demo %s is for Shareware version.\n", d);
|
||||||
|
@ -8592,7 +8592,9 @@ char opendemoread(char which_demo) // 0 = mine
|
||||||
demo_version = 0;
|
demo_version = 0;
|
||||||
return 0;
|
return 0;
|
||||||
} else {
|
} else {
|
||||||
demo_version = ver;
|
if(ver == 160)
|
||||||
|
demo_version = ver = BYTEVERSION;
|
||||||
|
else demo_version = ver;
|
||||||
OSD_Printf("Demo %s is of version %d.\n", d, ver);
|
OSD_Printf("Demo %s is of version %d.\n", d, ver);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -8651,7 +8653,7 @@ char opendemoread(char which_demo) // 0 = mine
|
||||||
newgame(ud.volume_number,ud.level_number,ud.player_skill);
|
newgame(ud.volume_number,ud.level_number,ud.player_skill);
|
||||||
return(1);
|
return(1);
|
||||||
corrupt:
|
corrupt:
|
||||||
OSD_Printf("Demo file %d is corrupt.\n",which_demo);
|
OSD_Printf("Demo %d header is corrupt.\n",which_demo);
|
||||||
ud.reccnt = 0;
|
ud.reccnt = 0;
|
||||||
kclose(recfilep);
|
kclose(recfilep);
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -8816,20 +8818,19 @@ RECHECK:
|
||||||
ud.reccnt = 0;
|
ud.reccnt = 0;
|
||||||
kclose(recfilep);
|
kclose(recfilep);
|
||||||
ps[myconnectindex].gm |= MODE_MENU;
|
ps[myconnectindex].gm |= MODE_MENU;
|
||||||
break;
|
goto RECHECK;
|
||||||
}
|
}
|
||||||
OSD_Printf("ud.reccnt: %d\n",ud.reccnt);
|
OSD_Printf("ud.reccnt: %d\n",ud.reccnt);
|
||||||
}
|
}
|
||||||
|
|
||||||
for(j=connecthead;j>=0;j=connectpoint2[j])
|
for(j=connecthead;j>=0;j=connectpoint2[j])
|
||||||
{
|
{
|
||||||
OSD_Printf("a:%d, h:%d, s:%d, f:%d, b:%d\n",oldrecsync[i].avel,oldrecsync[i].horz,oldrecsync[i].svel,oldrecsync[i].fvel,oldrecsync[i].bits);
|
OSD_Printf("ud.reccnt: %d, a:%d, h:%d, s:%d, f:%d, b:%d\n",ud.reccnt,oldrecsync[i].avel,oldrecsync[i].horz,oldrecsync[i].svel,oldrecsync[i].fvel,oldrecsync[i].bits);
|
||||||
clearbufbyte(&inputfifo[movefifoend[j]&(MOVEFIFOSIZ-1)][j],sizeof(input),0L);
|
clearbufbyte(&inputfifo[movefifoend[j]&(MOVEFIFOSIZ-1)][j],sizeof(input),0L);
|
||||||
copybufbyte(&oldrecsync[i],&inputfifo[movefifoend[j]&(MOVEFIFOSIZ-1)][j],sizeof(oldinput));
|
copybufbyte(&oldrecsync[i],&inputfifo[movefifoend[j]&(MOVEFIFOSIZ-1)][j],sizeof(oldinput));
|
||||||
movefifoend[j]++;
|
movefifoend[j]++;
|
||||||
i++;
|
i++;
|
||||||
ud.reccnt--;
|
ud.reccnt--;
|
||||||
OSD_Printf("ud.reccnt: %d\n",ud.reccnt);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -8844,7 +8845,7 @@ RECHECK:
|
||||||
ud.reccnt = 0;
|
ud.reccnt = 0;
|
||||||
kclose(recfilep);
|
kclose(recfilep);
|
||||||
ps[myconnectindex].gm |= MODE_MENU;
|
ps[myconnectindex].gm |= MODE_MENU;
|
||||||
break;
|
goto RECHECK;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue