mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-15 08:51:24 +00:00
Cleanups
git-svn-id: https://svn.eduke32.com/eduke32@91 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
59649efc87
commit
2455734c76
21 changed files with 83 additions and 176 deletions
|
@ -35,7 +35,7 @@ endif
|
||||||
CC=gcc
|
CC=gcc
|
||||||
CXX=g++
|
CXX=g++
|
||||||
# -Werror-implicit-function-declaration
|
# -Werror-implicit-function-declaration
|
||||||
OURCFLAGS=$(debug) -W -Wall -Wimplicit -Wno-char-subscripts -Wno-unused \
|
OURCFLAGS=$(debug) -W -Wall -Wimplicit -Wno-char-subscripts -Wunused \
|
||||||
-funsigned-char -fno-strict-aliasing -DNO_GCC_BUILTINS -DNOCOPYPROTECT \
|
-funsigned-char -fno-strict-aliasing -DNO_GCC_BUILTINS -DNOCOPYPROTECT \
|
||||||
-I$(INC:/=) -I$(EINC:/=) -I$(SRC)jmact -I$(SRC)jaudiolib -I../jfaud/src
|
-I$(INC:/=) -I$(EINC:/=) -I$(SRC)jmact -I$(SRC)jaudiolib -I../jfaud/src
|
||||||
OURCXXFLAGS=-fno-exceptions -fno-rtti
|
OURCXXFLAGS=-fno-exceptions -fno-rtti
|
||||||
|
|
|
@ -276,15 +276,6 @@ static char * mousedigitaldefaults[] =
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
static char * gamepaddigitaldefaults[] =
|
|
||||||
{
|
|
||||||
"Turn_Left",
|
|
||||||
"Turn_Right",
|
|
||||||
"Move_Forward",
|
|
||||||
"Move_Backward",
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
static char * joystickanalogdefaults[] =
|
static char * joystickanalogdefaults[] =
|
||||||
{
|
{
|
||||||
"analog_turning",
|
"analog_turning",
|
||||||
|
|
|
@ -475,7 +475,7 @@ BOLT:
|
||||||
int movesprite(short spritenum, long xchange, long ychange, long zchange, unsigned long cliptype)
|
int movesprite(short spritenum, long xchange, long ychange, long zchange, unsigned long cliptype)
|
||||||
{
|
{
|
||||||
long daz,h, oldx, oldy;
|
long daz,h, oldx, oldy;
|
||||||
short retval, dasectnum, a, cd;
|
short retval, dasectnum, cd;
|
||||||
char bg;
|
char bg;
|
||||||
|
|
||||||
bg = badguy(&sprite[spritenum]);
|
bg = badguy(&sprite[spritenum]);
|
||||||
|
@ -859,7 +859,7 @@ short ifhitsectors(short sectnum)
|
||||||
|
|
||||||
short ifhitbyweapon(short sn)
|
short ifhitbyweapon(short sn)
|
||||||
{
|
{
|
||||||
short j, k, p;
|
short j,p;
|
||||||
spritetype *npc;
|
spritetype *npc;
|
||||||
|
|
||||||
if( hittype[sn].extra >= 0 )
|
if( hittype[sn].extra >= 0 )
|
||||||
|
@ -1366,8 +1366,8 @@ BOLT:
|
||||||
|
|
||||||
void movestandables(void)
|
void movestandables(void)
|
||||||
{
|
{
|
||||||
short i, j, k, m, nexti, nextj, nextk, p=0, q, sect;
|
short i, j, k, m, nexti, nextj, p=0, sect;
|
||||||
long l=0, x, *t, x1, y1;
|
long l=0, x, *t;
|
||||||
spritetype *s;
|
spritetype *s;
|
||||||
int switchpicnum;
|
int switchpicnum;
|
||||||
|
|
||||||
|
@ -2340,8 +2340,8 @@ void bounce(short i)
|
||||||
|
|
||||||
void moveweapons(void)
|
void moveweapons(void)
|
||||||
{
|
{
|
||||||
short i, j=0, k, f, nexti, p, q, tempsect;
|
short i, j=0, k, f, nexti, p, q;
|
||||||
long dax,day,daz, x, l, ll, x1, y1;
|
long dax,day,daz, x, ll;
|
||||||
unsigned long qq;
|
unsigned long qq;
|
||||||
spritetype *s;
|
spritetype *s;
|
||||||
|
|
||||||
|
@ -3125,7 +3125,7 @@ BOLT:
|
||||||
void movetransports(void)
|
void movetransports(void)
|
||||||
{
|
{
|
||||||
char warpspriteto;
|
char warpspriteto;
|
||||||
short i, j, k, l, p, sect, sectlotag, nexti, nextj, nextk;
|
short i, j, k, l, p, sect, sectlotag, nexti, nextj;
|
||||||
long ll,onfloorz,q;
|
long ll,onfloorz,q;
|
||||||
|
|
||||||
i = headspritestat[9]; //Transporters
|
i = headspritestat[9]; //Transporters
|
||||||
|
@ -4762,7 +4762,7 @@ BOLT:
|
||||||
|
|
||||||
void moveexplosions(void) // STATNUM 5
|
void moveexplosions(void) // STATNUM 5
|
||||||
{
|
{
|
||||||
short i, j, k, nexti, sect, p;
|
short i, j, nexti, sect, p;
|
||||||
long l, x, *t;
|
long l, x, *t;
|
||||||
spritetype *s;
|
spritetype *s;
|
||||||
int switchpicnum;
|
int switchpicnum;
|
||||||
|
|
|
@ -198,7 +198,7 @@ void endanimvol43(long fr)
|
||||||
void playanm(char *fn,char t)
|
void playanm(char *fn,char t)
|
||||||
{
|
{
|
||||||
char *animbuf, *palptr;
|
char *animbuf, *palptr;
|
||||||
long i, j, k, length=0, numframes=0;
|
long i, j, length=0, numframes=0;
|
||||||
int32 handle=-1;
|
int32 handle=-1;
|
||||||
|
|
||||||
// return;
|
// return;
|
||||||
|
|
|
@ -305,8 +305,6 @@ const char *ExtGetSectorCaption(short sectnum)
|
||||||
|
|
||||||
const char *ExtGetWallCaption(short wallnum)
|
const char *ExtGetWallCaption(short wallnum)
|
||||||
{
|
{
|
||||||
long i=0;
|
|
||||||
|
|
||||||
if(!(onnames==2 || onnames==4))
|
if(!(onnames==2 || onnames==4))
|
||||||
{
|
{
|
||||||
tempbuf[0] = 0;
|
tempbuf[0] = 0;
|
||||||
|
@ -478,7 +476,7 @@ void ExtShowSectorData(short sectnum) //F5
|
||||||
short statnum=0;
|
short statnum=0;
|
||||||
int x,x2,y;
|
int x,x2,y;
|
||||||
int nexti;
|
int nexti;
|
||||||
int i,c=0;
|
int i;
|
||||||
int secrets=0;
|
int secrets=0;
|
||||||
int totalactors1=0,totalactors2=0,totalactors3=0,totalactors4=0;
|
int totalactors1=0,totalactors2=0,totalactors3=0,totalactors4=0;
|
||||||
int totalrespawn=0;
|
int totalrespawn=0;
|
||||||
|
@ -912,8 +910,7 @@ void ExtShowWallData(short wallnum) //F6
|
||||||
|
|
||||||
void Show2dText(char *name)
|
void Show2dText(char *name)
|
||||||
{
|
{
|
||||||
int i,fp;
|
int fp,t;
|
||||||
int t;
|
|
||||||
char x=0,y=4,xmax=0,xx=0,col=0;
|
char x=0,y=4,xmax=0,xx=0,col=0;
|
||||||
clearmidstatbar16();
|
clearmidstatbar16();
|
||||||
if((fp=kopen4load(name,0)) == -1)
|
if((fp=kopen4load(name,0)) == -1)
|
||||||
|
@ -951,9 +948,9 @@ void Show2dText(char *name)
|
||||||
|
|
||||||
void Show3dText(char *name)
|
void Show3dText(char *name)
|
||||||
{
|
{
|
||||||
int i,fp;
|
int fp,t;
|
||||||
char x=0,y=4,xmax=0,xx=0,col=0;
|
char x=0,y=4,xmax=0,xx=0,col=0;
|
||||||
int t;
|
|
||||||
if((fp=kopen4load(name,0)) == -1)
|
if((fp=kopen4load(name,0)) == -1)
|
||||||
{
|
{
|
||||||
begindrawing();
|
begindrawing();
|
||||||
|
@ -988,8 +985,7 @@ void Show3dText(char *name)
|
||||||
void ShowHelpText(char *name)
|
void ShowHelpText(char *name)
|
||||||
{
|
{
|
||||||
BFILE *fp;
|
BFILE *fp;
|
||||||
int i,t;
|
char x=0,y=4;
|
||||||
char x=0,y=4,xmax=0,xx=0,col=0;
|
|
||||||
if((fp=fopenfrompath("helpdoc.txt","rb")) == NULL)
|
if((fp=fopenfrompath("helpdoc.txt","rb")) == NULL)
|
||||||
{
|
{
|
||||||
begindrawing();
|
begindrawing();
|
||||||
|
@ -1390,7 +1386,7 @@ long lastupdate, mousecol, mouseadd = 1, bstatus;
|
||||||
|
|
||||||
void m32_showmouse(void)
|
void m32_showmouse(void)
|
||||||
{
|
{
|
||||||
int i, j, k, col;
|
int i, j, col;
|
||||||
|
|
||||||
j = (xdimgame > 640);
|
j = (xdimgame > 640);
|
||||||
|
|
||||||
|
@ -1477,15 +1473,11 @@ int AskIfSure(void)
|
||||||
void Keys3d(void)
|
void Keys3d(void)
|
||||||
{
|
{
|
||||||
long i,count,rate,nexti;
|
long i,count,rate,nexti;
|
||||||
short statnum=0;
|
long j, k, templong, changedir, hiz, loz;
|
||||||
|
long hitx, hity, hitz, hihit, lohit;
|
||||||
char smooshyalign=0, repeatpanalign=0, *ptr, buffer[80];
|
|
||||||
short sectnum, nextsectnum, startwall, endwall, dasector, daang;
|
|
||||||
long j, k, cnt, templong, doubvel, changedir, wallfind[2], daz[2];
|
|
||||||
long dashade[2], goalz, xvect, yvect, hiz, loz;
|
|
||||||
short hitsect, hitwall, hitsprite;
|
|
||||||
long hitx, hity, hitz, dax, day, hihit, lohit;
|
|
||||||
long repeatcountx=0,repeatcounty=0;
|
long repeatcountx=0,repeatcounty=0;
|
||||||
|
char smooshyalign=0, repeatpanalign=0, buffer[80];
|
||||||
|
short startwall, endwall, dasector, hitsect, hitwall, hitsprite, statnum=0;
|
||||||
|
|
||||||
/* start Mapster32 */
|
/* start Mapster32 */
|
||||||
|
|
||||||
|
@ -1695,7 +1687,7 @@ void Keys3d(void)
|
||||||
|
|
||||||
if (keystatus[KEYSC_SEMI] && keystatus[KEYSC_V]) // ; V
|
if (keystatus[KEYSC_SEMI] && keystatus[KEYSC_V]) // ; V
|
||||||
{
|
{
|
||||||
short w, start_wall, end_wall, currsector;
|
short currsector;
|
||||||
unsigned char visval;
|
unsigned char visval;
|
||||||
|
|
||||||
keystatus[KEYSC_V] = 0;
|
keystatus[KEYSC_V] = 0;
|
||||||
|
@ -3696,8 +3688,6 @@ void Keys2d(void)
|
||||||
|
|
||||||
if ((totalclock > getmessagetimeoff) && (totalclock > (lastpm16time + 120*3)))
|
if ((totalclock > getmessagetimeoff) && (totalclock > (lastpm16time + 120*3)))
|
||||||
{
|
{
|
||||||
long olinehighlight, opointhighlight, ocursectornum;
|
|
||||||
|
|
||||||
updatesector(mousxplc,mousyplc,&cursectornum);
|
updatesector(mousxplc,mousyplc,&cursectornum);
|
||||||
if (pointhighlight >= 16384)
|
if (pointhighlight >= 16384)
|
||||||
{
|
{
|
||||||
|
@ -4225,7 +4215,7 @@ int osdcmd_quit(const osdfuncparm_t *parm)
|
||||||
|
|
||||||
int ExtInit(void)
|
int ExtInit(void)
|
||||||
{
|
{
|
||||||
long fil, rv = 0;
|
long rv = 0;
|
||||||
char *duke3dgrp = "duke3d.grp";
|
char *duke3dgrp = "duke3d.grp";
|
||||||
|
|
||||||
#if 1 // defined(_WIN32)
|
#if 1 // defined(_WIN32)
|
||||||
|
@ -4336,7 +4326,7 @@ void ExtPreCheckKeys(void) // just before drawrooms
|
||||||
|
|
||||||
void ExtAnalyzeSprites(void)
|
void ExtAnalyzeSprites(void)
|
||||||
{
|
{
|
||||||
long i, j, k;
|
long i, k;
|
||||||
spritetype *tspr;
|
spritetype *tspr;
|
||||||
char frames=0;
|
char frames=0;
|
||||||
signed char l;
|
signed char l;
|
||||||
|
@ -4572,7 +4562,7 @@ void ExtCheckKeys(void)
|
||||||
|
|
||||||
void faketimerhandler(void)
|
void faketimerhandler(void)
|
||||||
{
|
{
|
||||||
long i, j, dax, day, dist;
|
long i, dist;
|
||||||
long hiz, hihit, loz, lohit, oposx, oposy;
|
long hiz, hihit, loz, lohit, oposx, oposy;
|
||||||
short hitwall, daang;
|
short hitwall, daang;
|
||||||
|
|
||||||
|
@ -4648,7 +4638,7 @@ void faketimerhandler(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
void SetBOSS1Palette()
|
void SetBOSS1Palette()
|
||||||
{int x;
|
{
|
||||||
if(acurpalette==3) return;
|
if(acurpalette==3) return;
|
||||||
acurpalette=3;
|
acurpalette=3;
|
||||||
kensetpalette(BOSS1palette);
|
kensetpalette(BOSS1palette);
|
||||||
|
@ -4656,14 +4646,14 @@ void SetBOSS1Palette()
|
||||||
|
|
||||||
|
|
||||||
void SetSLIMEPalette()
|
void SetSLIMEPalette()
|
||||||
{int x;
|
{
|
||||||
if(acurpalette==2) return;
|
if(acurpalette==2) return;
|
||||||
acurpalette=2;
|
acurpalette=2;
|
||||||
kensetpalette(SLIMEpalette);
|
kensetpalette(SLIMEpalette);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SetWATERPalette()
|
void SetWATERPalette()
|
||||||
{int x;
|
{
|
||||||
if(acurpalette==1) return;
|
if(acurpalette==1) return;
|
||||||
acurpalette=1;
|
acurpalette=1;
|
||||||
kensetpalette(WATERpalette);
|
kensetpalette(WATERpalette);
|
||||||
|
@ -4671,7 +4661,7 @@ void SetWATERPalette()
|
||||||
|
|
||||||
|
|
||||||
void SetGAMEPalette()
|
void SetGAMEPalette()
|
||||||
{int x;
|
{
|
||||||
if(acurpalette==0) return;
|
if(acurpalette==0) return;
|
||||||
acurpalette=0;
|
acurpalette=0;
|
||||||
kensetpalette(GAMEpalette);
|
kensetpalette(GAMEpalette);
|
||||||
|
@ -4743,7 +4733,6 @@ void EditSectorData(short sectnum)
|
||||||
{
|
{
|
||||||
char disptext[80];
|
char disptext[80];
|
||||||
char edittext[80];
|
char edittext[80];
|
||||||
char snotbuf[80];
|
|
||||||
char col=1, row=0, rowmax = 6, dispwidth = 24;
|
char col=1, row=0, rowmax = 6, dispwidth = 24;
|
||||||
long xpos = 200, ypos = ydim-STATUS2DSIZ+48;
|
long xpos = 200, ypos = ydim-STATUS2DSIZ+48;
|
||||||
int i = -1;
|
int i = -1;
|
||||||
|
@ -4981,8 +4970,7 @@ void EditWallData(short wallnum)
|
||||||
{
|
{
|
||||||
char disptext[80];
|
char disptext[80];
|
||||||
char edittext[80];
|
char edittext[80];
|
||||||
char snotbuf[80];
|
char row=0, dispwidth = 24;
|
||||||
char col=1, row=0, dispwidth = 24;
|
|
||||||
long xpos = 200, ypos = ydim-STATUS2DSIZ+48;
|
long xpos = 200, ypos = ydim-STATUS2DSIZ+48;
|
||||||
int i = -1;
|
int i = -1;
|
||||||
char editval = 0;
|
char editval = 0;
|
||||||
|
@ -5114,7 +5102,6 @@ void EditSpriteData(short spritenum)
|
||||||
{
|
{
|
||||||
char disptext[80];
|
char disptext[80];
|
||||||
char edittext[80];
|
char edittext[80];
|
||||||
char snotbuf[80];
|
|
||||||
char col=1, row=0, rowmax=5, dispwidth = 24;
|
char col=1, row=0, rowmax=5, dispwidth = 24;
|
||||||
long xpos = 200, ypos = ydim-STATUS2DSIZ+48;
|
long xpos = 200, ypos = ydim-STATUS2DSIZ+48;
|
||||||
int i = -1;
|
int i = -1;
|
||||||
|
@ -5428,9 +5415,10 @@ void Msg(char *string, char color)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
long GetAToken(char *name, char *tc, long length)
|
long GetAToken(char *name, char *tc, long length)
|
||||||
{
|
{
|
||||||
int i,x=0;
|
int x=0;
|
||||||
char t,*tmp,tokenfound=0;
|
char t,*tmp,tokenfound=0;
|
||||||
char *token;
|
char *token;
|
||||||
long count=0;
|
long count=0;
|
||||||
|
@ -5479,7 +5467,7 @@ long GetAToken(char *name, char *tc, long length)
|
||||||
return(count);
|
return(count);
|
||||||
|
|
||||||
}
|
}
|
||||||
/*
|
|
||||||
void ContextHelp(short spritenum)
|
void ContextHelp(short spritenum)
|
||||||
{
|
{
|
||||||
int i,fp;
|
int i,fp;
|
||||||
|
|
|
@ -371,7 +371,7 @@ void CONFIG_ReadKeys( void )
|
||||||
void CONFIG_SetupMouse( void )
|
void CONFIG_SetupMouse( void )
|
||||||
{
|
{
|
||||||
int32 i;
|
int32 i;
|
||||||
char str[80],*p;
|
char str[80];
|
||||||
char temp[80];
|
char temp[80];
|
||||||
int32 function, scale;
|
int32 function, scale;
|
||||||
|
|
||||||
|
@ -438,9 +438,9 @@ void CONFIG_SetupMouse( void )
|
||||||
void CONFIG_SetupJoystick( void )
|
void CONFIG_SetupJoystick( void )
|
||||||
{
|
{
|
||||||
int32 i;
|
int32 i;
|
||||||
char str[80],*p;
|
char str[80];
|
||||||
char temp[80];
|
char temp[80];
|
||||||
int32 function, scale;
|
int32 scale;
|
||||||
|
|
||||||
if (scripthandle < 0) return;
|
if (scripthandle < 0) return;
|
||||||
|
|
||||||
|
|
|
@ -452,8 +452,6 @@ extern long *actorLoadEventScrptr[MAXTILES];
|
||||||
extern char actortype[MAXTILES];
|
extern char actortype[MAXTILES];
|
||||||
extern char *music_pointer;
|
extern char *music_pointer;
|
||||||
|
|
||||||
extern char ipath[80],opath[80];
|
|
||||||
|
|
||||||
extern char music_fn[MAXVOLUMES+1][11][13],music_select;
|
extern char music_fn[MAXVOLUMES+1][11][13],music_select;
|
||||||
extern char env_music_fn[MAXVOLUMES+1][13];
|
extern char env_music_fn[MAXVOLUMES+1][13];
|
||||||
extern short camsprite;
|
extern short camsprite;
|
||||||
|
@ -826,7 +824,7 @@ typedef struct {
|
||||||
signed char sxrepeat, syrepeat, txrepeat, tyrepeat, shade, xrepeat, yrepeat, pal, velmult;
|
signed char sxrepeat, syrepeat, txrepeat, tyrepeat, shade, xrepeat, yrepeat, pal, velmult;
|
||||||
} proj_struct;
|
} proj_struct;
|
||||||
|
|
||||||
proj_struct projectile[MAXTILES], thisprojectile[MAXSPRITES], defaultprojectile[MAXTILES];
|
extern proj_struct projectile[MAXTILES], thisprojectile[MAXSPRITES], defaultprojectile[MAXTILES];
|
||||||
|
|
||||||
// logo control
|
// logo control
|
||||||
|
|
||||||
|
|
|
@ -212,12 +212,12 @@ int txgametext_(int small, int starttile, int x,int y,char *t,char s,char p,shor
|
||||||
|
|
||||||
inline int txgametext(int starttile, int x,int y,char *t,char s,char p,short dabits,long x1, long y1, long x2, long y2)
|
inline int txgametext(int starttile, int x,int y,char *t,char s,char p,short dabits,long x1, long y1, long x2, long y2)
|
||||||
{
|
{
|
||||||
return(txgametext_(0,STARTALPHANUM, x,y,t,s,p,dabits,x1, y1, x2, y2));
|
return(txgametext_(0,starttile, x,y,t,s,p,dabits,x1, y1, x2, y2));
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int txgametextsm(int starttile, int x,int y,char *t,char s,char p,short dabits,long x1, long y1, long x2, long y2)
|
inline int txgametextsm(int starttile, int x,int y,char *t,char s,char p,short dabits,long x1, long y1, long x2, long y2)
|
||||||
{
|
{
|
||||||
return(txgametext_(1,STARTALPHANUM, x,y,t,s,p,dabits,x1, y1, x2, y2));
|
return(txgametext_(1,starttile, x,y,t,s,p,dabits,x1, y1, x2, y2));
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int gametext(int x,int y,char *t,char s,short dabits)
|
inline int gametext(int x,int y,char *t,char s,short dabits)
|
||||||
|
@ -225,7 +225,7 @@ inline int gametext(int x,int y,char *t,char s,short dabits)
|
||||||
return(txgametext_(0,STARTALPHANUM, x,y,t,s,0,dabits,0, 0, xdim-1, ydim-1));
|
return(txgametext_(0,STARTALPHANUM, x,y,t,s,0,dabits,0, 0, xdim-1, ydim-1));
|
||||||
}
|
}
|
||||||
|
|
||||||
inline int mpgametext(int x,int y,char *t,char s,short dabits)
|
inline int mpgametext(int y,char *t,char s,short dabits)
|
||||||
{
|
{
|
||||||
if(xdim >= 640 && ydim >= 480)
|
if(xdim >= 640 && ydim >= 480)
|
||||||
return(txgametextsm(STARTALPHANUM, 5,y,t,s,0,dabits,0, 0, xdim-1, ydim-1));
|
return(txgametextsm(STARTALPHANUM, 5,y,t,s,0,dabits,0, 0, xdim-1, ydim-1));
|
||||||
|
@ -324,7 +324,6 @@ void adduserquote(char *daquote)
|
||||||
void getpackets(void)
|
void getpackets(void)
|
||||||
{
|
{
|
||||||
long i, j, k, l;
|
long i, j, k, l;
|
||||||
FILE *fp;
|
|
||||||
long other, packbufleng;
|
long other, packbufleng;
|
||||||
input *osyn, *nsyn;
|
input *osyn, *nsyn;
|
||||||
|
|
||||||
|
@ -722,8 +721,7 @@ extern void computergetinput(long snum, input *syn);
|
||||||
|
|
||||||
void faketimerhandler()
|
void faketimerhandler()
|
||||||
{
|
{
|
||||||
long i, j, k, l;
|
long i, j, k;
|
||||||
long momx, momy;
|
|
||||||
// short who;
|
// short who;
|
||||||
input *osyn, *nsyn;
|
input *osyn, *nsyn;
|
||||||
|
|
||||||
|
@ -1064,7 +1062,7 @@ void caches(void)
|
||||||
|
|
||||||
void checksync(void)
|
void checksync(void)
|
||||||
{
|
{
|
||||||
long i, k;
|
long i;
|
||||||
|
|
||||||
for(i=connecthead;i>=0;i=connectpoint2[i])
|
for(i=connecthead;i>=0;i=connectpoint2[i])
|
||||||
if (syncvalhead[i] == syncvaltottail) break;
|
if (syncvalhead[i] == syncvaltottail) break;
|
||||||
|
@ -1320,7 +1318,7 @@ void invennum(long x,long y,char num1,char ha,char sbits)
|
||||||
rotatesprite(sbarx(x+4),sbary(y),sbarsc(65536L),0,THREEBYFIVE+dabuf[0]-'0',ha,0,sbits,0,0,xdim-1,ydim-1);
|
rotatesprite(sbarx(x+4),sbary(y),sbarsc(65536L),0,THREEBYFIVE+dabuf[0]-'0',ha,0,sbits,0,0,xdim-1,ydim-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
void orderweaponnum(short ind,long x,long y,long num1, long num2,char ha)
|
void orderweaponnum(short ind,long x,long y,char ha)
|
||||||
{
|
{
|
||||||
rotatesprite(sbarx(x-7),sbary(y),sbarsc(65536L),0,THREEBYFIVE+ind+1,ha-10,7,10,0,0,xdim-1,ydim-1);
|
rotatesprite(sbarx(x-7),sbary(y),sbarsc(65536L),0,THREEBYFIVE+ind+1,ha-10,7,10,0,0,xdim-1,ydim-1);
|
||||||
rotatesprite(sbarx(x-3),sbary(y),sbarsc(65536L),0,THREEBYFIVE+10,ha,0,10,0,0,xdim-1,ydim-1);
|
rotatesprite(sbarx(x-3),sbary(y),sbarsc(65536L),0,THREEBYFIVE+10,ha,0,10,0,0,xdim-1,ydim-1);
|
||||||
|
@ -1444,7 +1442,6 @@ void weapon_amounts(struct player_struct *p,long x,long y,long u)
|
||||||
|
|
||||||
if (VOLUMEONE) {
|
if (VOLUMEONE) {
|
||||||
orderweaponnum(SHRINKER_WEAPON,x+39,y+12,
|
orderweaponnum(SHRINKER_WEAPON,x+39,y+12,
|
||||||
p->ammo_amount[SHRINKER_WEAPON],max_ammo_amount[SHRINKER_WEAPON],
|
|
||||||
(!p->gotweapon[SHRINKER_WEAPON]*9)+12-18*
|
(!p->gotweapon[SHRINKER_WEAPON]*9)+12-18*
|
||||||
(cw == SHRINKER_WEAPON) );
|
(cw == SHRINKER_WEAPON) );
|
||||||
} else {
|
} else {
|
||||||
|
@ -1466,7 +1463,6 @@ void weapon_amounts(struct player_struct *p,long x,long y,long u)
|
||||||
|
|
||||||
if (VOLUMEONE) {
|
if (VOLUMEONE) {
|
||||||
orderweaponnum(DEVISTATOR_WEAPON,x+70,y,
|
orderweaponnum(DEVISTATOR_WEAPON,x+70,y,
|
||||||
p->ammo_amount[DEVISTATOR_WEAPON],max_ammo_amount[DEVISTATOR_WEAPON],
|
|
||||||
(!p->gotweapon[DEVISTATOR_WEAPON]*9)+12-18*
|
(!p->gotweapon[DEVISTATOR_WEAPON]*9)+12-18*
|
||||||
(cw == DEVISTATOR_WEAPON) );
|
(cw == DEVISTATOR_WEAPON) );
|
||||||
} else {
|
} else {
|
||||||
|
@ -1481,7 +1477,6 @@ void weapon_amounts(struct player_struct *p,long x,long y,long u)
|
||||||
if (u != -1) patchstatusbar(158,184,162+29,184+6); //original code: (166,184,166+8,184+6);
|
if (u != -1) patchstatusbar(158,184,162+29,184+6); //original code: (166,184,166+8,184+6);
|
||||||
if (VOLUMEONE) {
|
if (VOLUMEONE) {
|
||||||
orderweaponnum(TRIPBOMB_WEAPON,x+70,y+6,
|
orderweaponnum(TRIPBOMB_WEAPON,x+70,y+6,
|
||||||
p->ammo_amount[TRIPBOMB_WEAPON],max_ammo_amount[TRIPBOMB_WEAPON],
|
|
||||||
(!p->gotweapon[TRIPBOMB_WEAPON]*9)+12-18*
|
(!p->gotweapon[TRIPBOMB_WEAPON]*9)+12-18*
|
||||||
(cw == TRIPBOMB_WEAPON) );
|
(cw == TRIPBOMB_WEAPON) );
|
||||||
} else {
|
} else {
|
||||||
|
@ -1497,7 +1492,6 @@ void weapon_amounts(struct player_struct *p,long x,long y,long u)
|
||||||
if (u != -1) patchstatusbar(158,190,162+29,190+6); //original code: (166,190,166+8,190+6);
|
if (u != -1) patchstatusbar(158,190,162+29,190+6); //original code: (166,190,166+8,190+6);
|
||||||
if (VOLUMEONE) {
|
if (VOLUMEONE) {
|
||||||
orderweaponnum(-1,x+70,y+12,
|
orderweaponnum(-1,x+70,y+12,
|
||||||
p->ammo_amount[FREEZE_WEAPON],max_ammo_amount[FREEZE_WEAPON],
|
|
||||||
(!p->gotweapon[FREEZE_WEAPON]*9)+12-18*
|
(!p->gotweapon[FREEZE_WEAPON]*9)+12-18*
|
||||||
(cw == FREEZE_WEAPON) );
|
(cw == FREEZE_WEAPON) );
|
||||||
} else {
|
} else {
|
||||||
|
@ -1668,7 +1662,7 @@ void coolgaugetext(short snum)
|
||||||
{
|
{
|
||||||
struct player_struct *p;
|
struct player_struct *p;
|
||||||
long i, j, o, ss, u;
|
long i, j, o, ss, u;
|
||||||
char c, permbit;
|
char permbit;
|
||||||
|
|
||||||
p = &ps[snum];
|
p = &ps[snum];
|
||||||
|
|
||||||
|
@ -2010,9 +2004,9 @@ void operatefta(void)
|
||||||
j -= 8;
|
j -= 8;
|
||||||
}
|
}
|
||||||
if (k > 4)
|
if (k > 4)
|
||||||
mpgametext(320>>1,j,user_quote[i],0,2+8+16);
|
mpgametext(j,user_quote[i],0,2+8+16);
|
||||||
else if (k > 2) mpgametext(320>>1,j,user_quote[i],0,2+8+16+1);
|
else if (k > 2) mpgametext(j,user_quote[i],0,2+8+16+1);
|
||||||
else mpgametext(320>>1,j,user_quote[i],0,2+8+16+1+32);
|
else mpgametext(j,user_quote[i],0,2+8+16+1+32);
|
||||||
j -= 8;
|
j -= 8;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2089,8 +2083,6 @@ void FTA(short q,struct player_struct *p)
|
||||||
|
|
||||||
void showtwoscreens(void)
|
void showtwoscreens(void)
|
||||||
{
|
{
|
||||||
short i;
|
|
||||||
|
|
||||||
if (!VOLUMEALL) {
|
if (!VOLUMEALL) {
|
||||||
setview(0,0,xdim-1,ydim-1);
|
setview(0,0,xdim-1,ydim-1);
|
||||||
flushperms();
|
flushperms();
|
||||||
|
@ -2128,8 +2120,6 @@ extern long qsetmode;
|
||||||
|
|
||||||
void gameexit(char *t)
|
void gameexit(char *t)
|
||||||
{
|
{
|
||||||
short i;
|
|
||||||
|
|
||||||
if(*t != 0) ps[myconnectindex].palette = (char *) &palette[0];
|
if(*t != 0) ps[myconnectindex].palette = (char *) &palette[0];
|
||||||
|
|
||||||
if(numplayers > 1)
|
if(numplayers > 1)
|
||||||
|
@ -2224,13 +2214,13 @@ short strget_(int small,short x,short y,char *t,short dalen,short c)
|
||||||
b[ii] = '*';
|
b[ii] = '*';
|
||||||
b[ii] = 0;
|
b[ii] = 0;
|
||||||
if(ps[myconnectindex].gm&MODE_TYPE)
|
if(ps[myconnectindex].gm&MODE_TYPE)
|
||||||
x = mpgametext(x,y,b,c,2+8+16);
|
x = mpgametext(y,b,c,2+8+16);
|
||||||
else x = gametext(x,y,b,c,2+8+16);
|
else x = gametext(x,y,b,c,2+8+16);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if(ps[myconnectindex].gm&MODE_TYPE)
|
if(ps[myconnectindex].gm&MODE_TYPE)
|
||||||
x = mpgametext(x,y,t,c,2+8+16);
|
x = mpgametext(y,t,c,2+8+16);
|
||||||
else x = gametext(x,y,t,c,2+8+16);
|
else x = gametext(x,y,t,c,2+8+16);
|
||||||
}
|
}
|
||||||
c = 4-(sintable[(totalclock<<4)&2047]>>11);
|
c = 4-(sintable[(totalclock<<4)&2047]>>11);
|
||||||
|
@ -2336,7 +2326,7 @@ void typemode(void)
|
||||||
minitext((320>>1)-40-4,j," ESC - Abort",0,2+8+16); j += 7;
|
minitext((320>>1)-40-4,j," ESC - Abort",0,2+8+16); j += 7;
|
||||||
|
|
||||||
if (ud.screen_size > 0) j = 200-45; else j = 200-8;
|
if (ud.screen_size > 0) j = 200-45; else j = 200-8;
|
||||||
mpgametext(320>>1,j,typebuf,0,2+8+16);
|
mpgametext(j,typebuf,0,2+8+16);
|
||||||
|
|
||||||
if( KB_KeyWaiting() )
|
if( KB_KeyWaiting() )
|
||||||
{
|
{
|
||||||
|
@ -2657,8 +2647,6 @@ void drawoverheadmap(long cposx, long cposy, long czoom, short cang)
|
||||||
|
|
||||||
void palto(char r,char g,char b,long e)
|
void palto(char r,char g,char b,long e)
|
||||||
{
|
{
|
||||||
int i;
|
|
||||||
char temparray[768];
|
|
||||||
long tc;
|
long tc;
|
||||||
/*
|
/*
|
||||||
for(i=0;i<768;i+=3)
|
for(i=0;i<768;i+=3)
|
||||||
|
@ -2939,7 +2927,7 @@ void displayrest(long smoothratio)
|
||||||
void view(struct player_struct *pp, long *vx, long *vy,long *vz,short *vsectnum, short ang, short horiz)
|
void view(struct player_struct *pp, long *vx, long *vy,long *vz,short *vsectnum, short ang, short horiz)
|
||||||
{
|
{
|
||||||
spritetype *sp;
|
spritetype *sp;
|
||||||
long i, nx, ny, nz, hx, hy, hz, hitx, hity, hitz;
|
long i, nx, ny, nz, hx, hy, hitx, hity, hitz;
|
||||||
short bakcstat, hitsect, hitwall, hitsprite, daang;
|
short bakcstat, hitsect, hitwall, hitsprite, daang;
|
||||||
|
|
||||||
nx = (sintable[(ang+1536)&2047]>>4);
|
nx = (sintable[(ang+1536)&2047]>>4);
|
||||||
|
@ -3293,10 +3281,10 @@ static long oyrepeat=-1;
|
||||||
|
|
||||||
void displayrooms(short snum,long smoothratio)
|
void displayrooms(short snum,long smoothratio)
|
||||||
{
|
{
|
||||||
long cposx,cposy,cposz,dst,j,fz,cz,hz,lz;
|
long cposx,cposy,cposz,dst,j,fz,cz;
|
||||||
short sect, cang, k, choriz,tsect;
|
short sect, cang, k, choriz;
|
||||||
struct player_struct *p;
|
struct player_struct *p;
|
||||||
long tposx,tposy,tposz,dx,dy,thoriz,i;
|
long tposx,tposy,i;
|
||||||
short tang;
|
short tang;
|
||||||
long tiltcx,tiltcy,tiltcs=0; // JBF 20030807
|
long tiltcx,tiltcy,tiltcs=0; // JBF 20030807
|
||||||
|
|
||||||
|
@ -6413,7 +6401,7 @@ char cheatbuf[MAXCHEATLEN],cheatbuflen;
|
||||||
|
|
||||||
void cheats(void)
|
void cheats(void)
|
||||||
{
|
{
|
||||||
short ch, i, j, k=0,x,y, keystate, weapon;
|
short ch, i, j, k=0,x,y, weapon;
|
||||||
static char z=0;
|
static char z=0;
|
||||||
char consolecheat = 0; // JBF 20030914
|
char consolecheat = 0; // JBF 20030914
|
||||||
|
|
||||||
|
@ -6967,7 +6955,7 @@ FOUNDCHEAT:
|
||||||
long nonsharedtimer;
|
long nonsharedtimer;
|
||||||
void nonsharedkeys(void)
|
void nonsharedkeys(void)
|
||||||
{
|
{
|
||||||
short i,ch, weapon;
|
short i,ch;
|
||||||
long j;
|
long j;
|
||||||
|
|
||||||
if(ud.recstat == 2)
|
if(ud.recstat == 2)
|
||||||
|
@ -7799,38 +7787,9 @@ void checkcommandline(int argc,char **argv)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void printstr(short x, short y, char string[81], char attribute)
|
|
||||||
{
|
|
||||||
char character;
|
|
||||||
short i, pos;
|
|
||||||
/*
|
|
||||||
pos = (y*80+x)<<1;
|
|
||||||
i = 0;
|
|
||||||
while (string[i] != 0)
|
|
||||||
{
|
|
||||||
character = string[i];
|
|
||||||
printchrasm(0xb8000+(long)pos,1L,((long)attribute<<8)+(long)character);
|
|
||||||
i++;
|
|
||||||
pos+=2;
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
void cacheicon(void)
|
|
||||||
{
|
|
||||||
if(cachecount > 0)
|
|
||||||
{
|
|
||||||
if( (ps[myconnectindex].gm&MODE_MENU) == 0 )
|
|
||||||
rotatesprite((320-7)<<16,(200-23)<<16,32768L,0,SPINNINGNUKEICON,0,0,2,windowx1,windowy1,windowx2,windowy2);
|
|
||||||
cachecount = 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
|
|
||||||
void Logo(void)
|
void Logo(void)
|
||||||
{
|
{
|
||||||
short i,j,soundanm;
|
short soundanm;
|
||||||
long logoflags=GetGameVar("LOGO_FLAGS",255, -1, -1);
|
long logoflags=GetGameVar("LOGO_FLAGS",255, -1, -1);
|
||||||
soundanm = 0;
|
soundanm = 0;
|
||||||
|
|
||||||
|
@ -8030,7 +7989,6 @@ void Shutdown( void )
|
||||||
|
|
||||||
void compilecons(void)
|
void compilecons(void)
|
||||||
{
|
{
|
||||||
char *tempname;
|
|
||||||
int i;
|
int i;
|
||||||
label = (char *)&sprite[0]; // V8: 16384*44/64 = 11264 V7: 4096*44/64 = 2816
|
label = (char *)&sprite[0]; // V8: 16384*44/64 = 11264 V7: 4096*44/64 = 2816
|
||||||
labelcode = (long *)§or[0]; // V8: 4096*40/4 = 40960 V7: 1024*40/4 = 10240
|
labelcode = (long *)§or[0]; // V8: 4096*40/4 = 40960 V7: 1024*40/4 = 10240
|
||||||
|
@ -8387,7 +8345,7 @@ int load_script(char *szScript)
|
||||||
|
|
||||||
void app_main(int argc,char **argv)
|
void app_main(int argc,char **argv)
|
||||||
{
|
{
|
||||||
long i, j, k, l;
|
long i, j;
|
||||||
#ifdef RENDERTYPEWIN
|
#ifdef RENDERTYPEWIN
|
||||||
if (win_checkinstance()) {
|
if (win_checkinstance()) {
|
||||||
if (!wm_ynbox("EDuke32","Another Build game is currently running. "
|
if (!wm_ynbox("EDuke32","Another Build game is currently running. "
|
||||||
|
@ -8939,8 +8897,7 @@ oldinput oldrecsync[RECSYNCBUFSIZ];
|
||||||
// extern long syncs[];
|
// extern long syncs[];
|
||||||
long playback(void)
|
long playback(void)
|
||||||
{
|
{
|
||||||
long i,j,k,l,t,tc;
|
long i,j,k,l;
|
||||||
short p;
|
|
||||||
char foundemo;
|
char foundemo;
|
||||||
|
|
||||||
if( ready2send ) return 0;
|
if( ready2send ) return 0;
|
||||||
|
@ -9833,8 +9790,6 @@ char domovethings(void)
|
||||||
|
|
||||||
void doorders(void)
|
void doorders(void)
|
||||||
{
|
{
|
||||||
short i;
|
|
||||||
|
|
||||||
setview(0,0,xdim-1,ydim-1);
|
setview(0,0,xdim-1,ydim-1);
|
||||||
|
|
||||||
fadepal(0,0,0, 0,63,7);
|
fadepal(0,0,0, 0,63,7);
|
||||||
|
@ -9866,7 +9821,7 @@ void doorders(void)
|
||||||
|
|
||||||
void dobonus(char bonusonly)
|
void dobonus(char bonusonly)
|
||||||
{
|
{
|
||||||
short t, r, tinc,gfx_offset;
|
short t, tinc,gfx_offset;
|
||||||
long i, y,xfragtotal,yfragtotal;
|
long i, y,xfragtotal,yfragtotal;
|
||||||
short bonuscnt;
|
short bonuscnt;
|
||||||
int clockpad = 2;
|
int clockpad = 2;
|
||||||
|
|
|
@ -1264,8 +1264,6 @@ char AddGameVar(char *pszLabel, long lValue, unsigned long dwFlags)
|
||||||
int i;
|
int i;
|
||||||
int j;
|
int j;
|
||||||
|
|
||||||
int b=0;
|
|
||||||
|
|
||||||
//Bsprintf(g_szBuf,"AddGameVar(%s, %d, %X)",pszLabel, lValue, dwFlags);
|
//Bsprintf(g_szBuf,"AddGameVar(%s, %d, %X)",pszLabel, lValue, dwFlags);
|
||||||
//AddLog(g_szBuf);
|
//AddLog(g_szBuf);
|
||||||
|
|
||||||
|
@ -1590,7 +1588,6 @@ long getlabeloffset(LABELS *pLabel, char *psz)
|
||||||
{
|
{
|
||||||
// find the label psz in the table pLabel.
|
// find the label psz in the table pLabel.
|
||||||
// returns the offset in the array for the label, or -1
|
// returns the offset in the array for the label, or -1
|
||||||
long l=-1;
|
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for(i=0;pLabel[i].lId >=0 ; i++)
|
for(i=0;pLabel[i].lId >=0 ; i++)
|
||||||
|
@ -1716,7 +1713,7 @@ long transword(void) //Returns its code #
|
||||||
|
|
||||||
void transvartype(int type)
|
void transvartype(int type)
|
||||||
{
|
{
|
||||||
int i=0,l,f=0;
|
int i=0,f=0;
|
||||||
|
|
||||||
skipcomments();
|
skipcomments();
|
||||||
if(!type && !labelsonly && (isdigit(*textptr) || ((*textptr == '-') && (isdigit(*(textptr+1))))))
|
if(!type && !labelsonly && (isdigit(*textptr) || ((*textptr == '-') && (isdigit(*(textptr+1))))))
|
||||||
|
@ -4937,7 +4934,7 @@ void ClearGameVars(void)
|
||||||
|
|
||||||
void InitGameVarPointers(void)
|
void InitGameVarPointers(void)
|
||||||
{
|
{
|
||||||
int i,j;
|
int i;
|
||||||
char aszBuf[64];
|
char aszBuf[64];
|
||||||
// called from game Init AND when level is loaded...
|
// called from game Init AND when level is loaded...
|
||||||
|
|
||||||
|
@ -4990,7 +4987,6 @@ void InitGameVarPointers(void)
|
||||||
void AddSystemVars()
|
void AddSystemVars()
|
||||||
{
|
{
|
||||||
// only call ONCE
|
// only call ONCE
|
||||||
int i;
|
|
||||||
char aszBuf[64];
|
char aszBuf[64];
|
||||||
|
|
||||||
//AddLog("AddSystemVars");
|
//AddLog("AddSystemVars");
|
||||||
|
|
|
@ -34,9 +34,8 @@ static spritetype *g_sp;
|
||||||
|
|
||||||
extern int32 scripthandle;
|
extern int32 scripthandle;
|
||||||
|
|
||||||
void DoUserDef(char bSet, long lVar1, long lLabelID, long lVar2, short sActor, short sPlayer, long lParm2)
|
void DoUserDef(char bSet, long lLabelID, long lVar2, short sActor, short sPlayer)
|
||||||
{
|
{
|
||||||
int iPlayer;
|
|
||||||
long lValue;
|
long lValue;
|
||||||
|
|
||||||
if(sActor < 0 || sActor >= MAXSPRITES || sPlayer < 0 || sPlayer >= MAXPLAYERS)
|
if(sActor < 0 || sActor >= MAXSPRITES || sPlayer < 0 || sPlayer >= MAXPLAYERS)
|
||||||
|
@ -1872,7 +1871,6 @@ void DoInput(char bSet, long lVar1, long lLabelID, long lVar2, short sActor, sho
|
||||||
{
|
{
|
||||||
int iPlayer;
|
int iPlayer;
|
||||||
long lValue;
|
long lValue;
|
||||||
long lTemp;
|
|
||||||
|
|
||||||
if(sActor < 0 || sActor >= MAXSPRITES || sPlayer < 0 || sPlayer >= MAXPLAYERS)
|
if(sActor < 0 || sActor >= MAXSPRITES || sPlayer < 0 || sPlayer >= MAXPLAYERS)
|
||||||
return;
|
return;
|
||||||
|
@ -2959,7 +2957,7 @@ short furthestangle(short sActor,short angs)
|
||||||
|
|
||||||
short furthestcanseepoint(short sActor,spritetype *ts,long *dax,long *day)
|
short furthestcanseepoint(short sActor,spritetype *ts,long *dax,long *day)
|
||||||
{
|
{
|
||||||
short j, hitsect,hitwall,hitspr, angincs, tempang;
|
short j, hitsect,hitwall,hitspr, angincs;
|
||||||
long hx, hy, hz, d, da;//, d, cd, ca,tempx,tempy,cx,cy;
|
long hx, hy, hz, d, da;//, d, cd, ca,tempx,tempy,cx,cy;
|
||||||
spritetype *s = &sprite[sActor];
|
spritetype *s = &sprite[sActor];
|
||||||
|
|
||||||
|
@ -3166,7 +3164,7 @@ void alterang(short a)
|
||||||
void move()
|
void move()
|
||||||
{
|
{
|
||||||
long l, *moveptr;
|
long l, *moveptr;
|
||||||
short j, a, goalang, angdif;
|
short a, goalang, angdif;
|
||||||
long daxvel;
|
long daxvel;
|
||||||
|
|
||||||
a = g_sp->hitag;
|
a = g_sp->hitag;
|
||||||
|
@ -3421,7 +3419,6 @@ char parse(void)
|
||||||
// <varid> <xxxid> <varid>
|
// <varid> <xxxid> <varid>
|
||||||
long lLabelID;
|
long lLabelID;
|
||||||
long lVar1, lVar2;
|
long lVar1, lVar2;
|
||||||
long lParm2;
|
|
||||||
|
|
||||||
insptr++;
|
insptr++;
|
||||||
lVar1=*insptr++;
|
lVar1=*insptr++;
|
||||||
|
@ -3505,7 +3502,6 @@ char parse(void)
|
||||||
case CON_IFCANSEE:
|
case CON_IFCANSEE:
|
||||||
{
|
{
|
||||||
spritetype *s;
|
spritetype *s;
|
||||||
short sect;
|
|
||||||
|
|
||||||
// select sprite for monster to target
|
// select sprite for monster to target
|
||||||
// if holoduke is on, let them target holoduke first.
|
// if holoduke is on, let them target holoduke first.
|
||||||
|
@ -4593,9 +4589,8 @@ SKIPJIBS:
|
||||||
case CON_GAMETEXT:
|
case CON_GAMETEXT:
|
||||||
case CON_DIGITALNUMBER:
|
case CON_DIGITALNUMBER:
|
||||||
{
|
{
|
||||||
long x,y,z;
|
long x,y;
|
||||||
short tilenum=0;
|
short tilenum=0;
|
||||||
short a;
|
|
||||||
signed char shade;
|
signed char shade;
|
||||||
char orientation=0;
|
char orientation=0;
|
||||||
char pal;
|
char pal;
|
||||||
|
@ -5683,15 +5678,13 @@ good:
|
||||||
// syntax [gs]etuserdef.xxx <VAR>
|
// syntax [gs]etuserdef.xxx <VAR>
|
||||||
// <xxxid> <varid>
|
// <xxxid> <varid>
|
||||||
long lLabelID;
|
long lLabelID;
|
||||||
long lVar1, lVar2;
|
long lVar2;
|
||||||
long lParm2=0;
|
|
||||||
|
|
||||||
insptr++;
|
insptr++;
|
||||||
lVar1=-1;
|
|
||||||
lLabelID=*insptr++;
|
lLabelID=*insptr++;
|
||||||
lVar2=*insptr++;
|
lVar2=*insptr++;
|
||||||
|
|
||||||
DoUserDef(tw==CON_SETUSERDEF, lVar1, lLabelID, lVar2, g_i, g_p, lParm2);
|
DoUserDef(tw==CON_SETUSERDEF, lLabelID, lVar2, g_i, g_p);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5702,7 +5695,6 @@ good:
|
||||||
// <varid> <xxxid> <varid>
|
// <varid> <xxxid> <varid>
|
||||||
long lLabelID;
|
long lLabelID;
|
||||||
long lVar1, lVar2;
|
long lVar1, lVar2;
|
||||||
long lParm2;
|
|
||||||
|
|
||||||
insptr++;
|
insptr++;
|
||||||
lVar1=GetGameVarID(*insptr++, g_i, g_p);
|
lVar1=GetGameVarID(*insptr++, g_i, g_p);
|
||||||
|
|
|
@ -176,4 +176,6 @@ int nextvoxid = 0;
|
||||||
|
|
||||||
int spriteflags[MAXTILES], actorspriteflags[MAXSPRITES];
|
int spriteflags[MAXTILES], actorspriteflags[MAXSPRITES];
|
||||||
|
|
||||||
|
proj_struct projectile[MAXTILES], thisprojectile[MAXSPRITES], defaultprojectile[MAXTILES];
|
||||||
|
|
||||||
char cheatkey[2] = { sc_D, sc_N };
|
char cheatkey[2] = { sc_D, sc_N };
|
||||||
|
|
|
@ -907,7 +907,6 @@ void CONTROL_Ack( void )
|
||||||
boolean CONTROL_Startup(controltype which, int32 ( *TimeFunction )( void ), int32 ticspersecond)
|
boolean CONTROL_Startup(controltype which, int32 ( *TimeFunction )( void ), int32 ticspersecond)
|
||||||
{
|
{
|
||||||
int32 i;
|
int32 i;
|
||||||
char *p;
|
|
||||||
|
|
||||||
if (CONTROL_Started) return false;
|
if (CONTROL_Started) return false;
|
||||||
|
|
||||||
|
@ -968,8 +967,6 @@ boolean CONTROL_Startup(controltype which, int32 ( *TimeFunction )( void ), int3
|
||||||
|
|
||||||
void CONTROL_Shutdown(void)
|
void CONTROL_Shutdown(void)
|
||||||
{
|
{
|
||||||
int i;
|
|
||||||
|
|
||||||
if (!CONTROL_Started) return;
|
if (!CONTROL_Started) return;
|
||||||
|
|
||||||
CONTROL_JoyPresent = false;
|
CONTROL_JoyPresent = false;
|
||||||
|
|
|
@ -74,8 +74,6 @@ int32 SafeOpen(const char *filename, int32 mode, int32 sharemode)
|
||||||
|
|
||||||
int32 SafeOpenRead(const char *filename, int32 filetype)
|
int32 SafeOpenRead(const char *filename, int32 filetype)
|
||||||
{
|
{
|
||||||
int32 h;
|
|
||||||
|
|
||||||
switch (filetype) {
|
switch (filetype) {
|
||||||
case filetype_binary:
|
case filetype_binary:
|
||||||
return SafeOpen(filename, O_RDONLY|O_BINARY, S_IREAD);
|
return SafeOpen(filename, O_RDONLY|O_BINARY, S_IREAD);
|
||||||
|
@ -89,8 +87,6 @@ int32 SafeOpenRead(const char *filename, int32 filetype)
|
||||||
|
|
||||||
void SafeClose ( int32 handle )
|
void SafeClose ( int32 handle )
|
||||||
{
|
{
|
||||||
int r;
|
|
||||||
|
|
||||||
if (handle < 0) return;
|
if (handle < 0) return;
|
||||||
if (close(handle) < 0) {
|
if (close(handle) < 0) {
|
||||||
if (handle < MaxFiles)
|
if (handle < MaxFiles)
|
||||||
|
|
|
@ -229,7 +229,6 @@ void KB_FlushKeyboardQueue( void )
|
||||||
|
|
||||||
void KB_ClearKeysDown( void )
|
void KB_ClearKeysDown( void )
|
||||||
{
|
{
|
||||||
int i;
|
|
||||||
KB_LastScan = 0;
|
KB_LastScan = 0;
|
||||||
memset(keystatus, 0, sizeof(keystatus));
|
memset(keystatus, 0, sizeof(keystatus));
|
||||||
//keyfifoplc = keyfifoend = 0;
|
//keyfifoplc = keyfifoend = 0;
|
||||||
|
|
|
@ -600,7 +600,7 @@ boolean SCRIPT_GetDoubleString( int32 scripthandle, char * sectionname, char * e
|
||||||
ScriptSectionType *s;
|
ScriptSectionType *s;
|
||||||
ScriptEntryType *e;
|
ScriptEntryType *e;
|
||||||
char *p, ch;
|
char *p, ch;
|
||||||
int c,d=0;
|
int c;
|
||||||
|
|
||||||
if (!SC(scripthandle)) return 1;
|
if (!SC(scripthandle)) return 1;
|
||||||
if (!SCRIPT(scripthandle,script)) return 1;
|
if (!SCRIPT(scripthandle,script)) return 1;
|
||||||
|
|
|
@ -71,7 +71,6 @@ extern long halfxdim16, midydim16, zoom;
|
||||||
extern void fixrepeats(short i);
|
extern void fixrepeats(short i);
|
||||||
|
|
||||||
char autospritehelp=0,autosecthelp=0;
|
char autospritehelp=0,autosecthelp=0;
|
||||||
static char pskysearch[MAXSECTORS];
|
|
||||||
short MinRate=24, MinD=3;
|
short MinRate=24, MinD=3;
|
||||||
long xoldtimerhandler, lastmessagetime;
|
long xoldtimerhandler, lastmessagetime;
|
||||||
|
|
||||||
|
@ -95,7 +94,6 @@ static int counter=0;
|
||||||
char nosprites=0,purpleon=0,skill=4;
|
char nosprites=0,purpleon=0,skill=4;
|
||||||
char framerateon=1,tabgraphic=2,shadepreview=0,autosave=1;
|
char framerateon=1,tabgraphic=2,shadepreview=0,autosave=1;
|
||||||
|
|
||||||
|
|
||||||
static char sidemode=0;
|
static char sidemode=0;
|
||||||
extern long vel, svel, hvel, angvel;
|
extern long vel, svel, hvel, angvel;
|
||||||
long xvel, yvel, timoff;
|
long xvel, yvel, timoff;
|
||||||
|
|
|
@ -33,7 +33,7 @@ int last_menu;
|
||||||
short sh,onbar,buttonstat,deletespot;
|
short sh,onbar,buttonstat,deletespot;
|
||||||
short last_zero,last_fifty,last_onehundred,last_twoohtwo,last_threehundred = 0;
|
short last_zero,last_fifty,last_onehundred,last_twoohtwo,last_threehundred = 0;
|
||||||
|
|
||||||
static char fileselect = 1, menunamecnt, menuname[256][64], curpath[80], menupath[80];
|
static char fileselect = 1, menunamecnt, menuname[256][64];
|
||||||
|
|
||||||
static CACHE1D_FIND_REC *finddirs=NULL, *findfiles=NULL, *finddirshigh=NULL, *findfileshigh=NULL;
|
static CACHE1D_FIND_REC *finddirs=NULL, *findfiles=NULL, *finddirshigh=NULL, *findfileshigh=NULL;
|
||||||
static int numdirs=0, numfiles=0;
|
static int numdirs=0, numfiles=0;
|
||||||
|
@ -799,6 +799,10 @@ void menus(void)
|
||||||
if(current_menu == 20005 && i == last_probey) continue;
|
if(current_menu == 20005 && i == last_probey) continue;
|
||||||
gametextpal(26,40+(i<<3),ud.ridecule[i],MENUHIGHLIGHT(i),0);
|
gametextpal(26,40+(i<<3),ud.ridecule[i],MENUHIGHLIGHT(i),0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
gametext(160,144,"UP/DOWN = SELECT MACRO",0,2+8+16);
|
||||||
|
gametext(160,144+9,"ENTER = MODIFY",0,2+8+16);
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 20010:
|
case 20010:
|
||||||
|
|
|
@ -48,7 +48,7 @@ int osdcmd_echo(const osdfuncparm_t *parm)
|
||||||
|
|
||||||
int osdcmd_changelevel(const osdfuncparm_t *parm)
|
int osdcmd_changelevel(const osdfuncparm_t *parm)
|
||||||
{
|
{
|
||||||
int volume=0,level,i;
|
int volume=0,level;
|
||||||
char *p;
|
char *p;
|
||||||
|
|
||||||
if (!VOLUMEONE) {
|
if (!VOLUMEONE) {
|
||||||
|
@ -214,8 +214,6 @@ int osdcmd_fileinfo(const osdfuncparm_t *parm)
|
||||||
|
|
||||||
static int osdcmd_restartvid(const osdfuncparm_t *parm)
|
static int osdcmd_restartvid(const osdfuncparm_t *parm)
|
||||||
{
|
{
|
||||||
extern long qsetmode;
|
|
||||||
|
|
||||||
resetvideomode();
|
resetvideomode();
|
||||||
if (setgamemode(ScreenMode,ScreenWidth,ScreenHeight,ScreenBPP))
|
if (setgamemode(ScreenMode,ScreenWidth,ScreenHeight,ScreenBPP))
|
||||||
gameexit("restartvid: Reset failed...\n");
|
gameexit("restartvid: Reset failed...\n");
|
||||||
|
|
|
@ -58,8 +58,7 @@ void fadepal(int r, int g, int b, int start, int end, int step)
|
||||||
|
|
||||||
void incur_damage(short snum)
|
void incur_damage(short snum)
|
||||||
{
|
{
|
||||||
long damage = 0L, shield_damage = 0L;
|
long damage = 0L, shield_damage = 0L;
|
||||||
short i;
|
|
||||||
|
|
||||||
struct player_struct *p;
|
struct player_struct *p;
|
||||||
|
|
||||||
|
@ -2008,7 +2007,7 @@ void DoSpawn(short snum)
|
||||||
|
|
||||||
void displaymasks(short snum)
|
void displaymasks(short snum)
|
||||||
{
|
{
|
||||||
short i, p;
|
short p;
|
||||||
|
|
||||||
if(sprite[ps[snum].i].pal == 1)
|
if(sprite[ps[snum].i].pal == 1)
|
||||||
p = 1;
|
p = 1;
|
||||||
|
@ -2115,7 +2114,7 @@ char last_quick_kick[MAXPLAYERS];
|
||||||
void displayweapon(short snum)
|
void displayweapon(short snum)
|
||||||
{
|
{
|
||||||
long gun_pos, looking_arc, cw;
|
long gun_pos, looking_arc, cw;
|
||||||
long weapon_xoffset, i, j, x1, y1, x2;
|
long weapon_xoffset, i, j;
|
||||||
char o,pal;
|
char o,pal;
|
||||||
signed char gs;
|
signed char gs;
|
||||||
struct player_struct *p;
|
struct player_struct *p;
|
||||||
|
@ -2713,7 +2712,6 @@ void getinput(short snum)
|
||||||
int32 keymove;
|
int32 keymove;
|
||||||
int32 momx,momy;
|
int32 momx,momy;
|
||||||
struct player_struct *p;
|
struct player_struct *p;
|
||||||
unsigned char tmpbuf[2048];
|
|
||||||
|
|
||||||
momx = momy = 0;
|
momx = momy = 0;
|
||||||
p = &ps[snum];
|
p = &ps[snum];
|
||||||
|
@ -2974,7 +2972,7 @@ void getinput(short snum)
|
||||||
|
|
||||||
char doincrements(struct player_struct *p)
|
char doincrements(struct player_struct *p)
|
||||||
{
|
{
|
||||||
long /*j,*/i,snum;
|
long snum;
|
||||||
|
|
||||||
snum = sprite[p->i].yvel;
|
snum = sprite[p->i].yvel;
|
||||||
// j = sync[snum].avel;
|
// j = sync[snum].avel;
|
||||||
|
@ -3167,8 +3165,7 @@ short weapon_sprites[MAX_WEAPONS] = { KNEE__STATIC, FIRSTGUNSPRITE__STATIC, SHOT
|
||||||
|
|
||||||
void checkweapons(struct player_struct *p)
|
void checkweapons(struct player_struct *p)
|
||||||
{
|
{
|
||||||
short j,cw;
|
short cw;
|
||||||
|
|
||||||
long snum;
|
long snum;
|
||||||
|
|
||||||
snum = sprite[p->i].yvel;
|
snum = sprite[p->i].yvel;
|
||||||
|
|
|
@ -427,7 +427,6 @@ void pickrandomspot(short snum)
|
||||||
void resetplayerstats(short snum)
|
void resetplayerstats(short snum)
|
||||||
{
|
{
|
||||||
struct player_struct *p;
|
struct player_struct *p;
|
||||||
short i;
|
|
||||||
|
|
||||||
p = &ps[snum];
|
p = &ps[snum];
|
||||||
|
|
||||||
|
@ -568,7 +567,6 @@ void resetweapons(short snum)
|
||||||
void resetinventory(short snum)
|
void resetinventory(short snum)
|
||||||
{
|
{
|
||||||
struct player_struct *p;
|
struct player_struct *p;
|
||||||
short i;
|
|
||||||
|
|
||||||
p = &ps[snum];
|
p = &ps[snum];
|
||||||
|
|
||||||
|
@ -1049,7 +1047,6 @@ void newgame(char vn,char ln,char sk)
|
||||||
p->gm = 0;
|
p->gm = 0;
|
||||||
|
|
||||||
{
|
{
|
||||||
int j;
|
|
||||||
//AddLog("Newgame");
|
//AddLog("Newgame");
|
||||||
ResetGameVars();
|
ResetGameVars();
|
||||||
|
|
||||||
|
@ -1351,7 +1348,7 @@ void waitforeverybody()
|
||||||
|
|
||||||
void dofrontscreens(char *statustext)
|
void dofrontscreens(char *statustext)
|
||||||
{
|
{
|
||||||
long tincs,i=0,j;
|
long i=0;
|
||||||
|
|
||||||
if(ud.recstat != 2)
|
if(ud.recstat != 2)
|
||||||
{
|
{
|
||||||
|
@ -1454,7 +1451,7 @@ extern void adduserquote(char *daquote);
|
||||||
|
|
||||||
int enterlevel(char g)
|
int enterlevel(char g)
|
||||||
{
|
{
|
||||||
short i,j;
|
short i;
|
||||||
long l;
|
long l;
|
||||||
char levname[BMAX_PATH];
|
char levname[BMAX_PATH];
|
||||||
|
|
||||||
|
|
|
@ -174,7 +174,6 @@ char menunum=0;
|
||||||
|
|
||||||
void intomenusounds(void)
|
void intomenusounds(void)
|
||||||
{
|
{
|
||||||
short i;
|
|
||||||
short menusnds[] =
|
short menusnds[] =
|
||||||
{
|
{
|
||||||
LASERTRIP_EXPLODE,
|
LASERTRIP_EXPLODE,
|
||||||
|
|
Loading…
Reference in a new issue