Remove REMDEBUG

This commit is contained in:
twinaphex 2015-03-25 11:11:12 +01:00
parent c17051d5b0
commit 36c2f16b5b
3 changed files with 1 additions and 165 deletions

View File

@ -930,7 +930,7 @@ void ClipMove (objtype *ob, int32_t xmove, int32_t ymove)
if (TryMove (ob))
return;
#ifndef REMDEBUG
#if 0
if (noclip && ob->x > 2*TILEGLOBAL && ob->y > 2*TILEGLOBAL
&& ob->x < (((int32_t)(mapwidth-1))<<TILESHIFT)
&& ob->y < (((int32_t)(mapheight-1))<<TILESHIFT) )

View File

@ -1578,34 +1578,8 @@ void ThreeDRefresh (void)
}
else
{
#ifndef REMDEBUG
if (fpscounter)
{
fontnumber = 0;
SETFONTCOLOR(7,127);
PrintX=4; PrintY=1;
VWB_Bar(0,0,50,10,bordercol);
US_PrintSigned(fps);
US_Print(" fps");
}
#endif
SDL_BlitSurface(screenBuffer, NULL, screen, NULL);
SDL_Flip(screen);
}
#ifndef REMDEBUG
if (fpscounter)
{
fps_frames++;
fps_time+=tics;
if(fps_time>35)
{
fps_time-=35;
fps=fps_frames<<1;
fps_frames=0;
}
}
#endif
}

138
wl_game.c
View File

@ -988,146 +988,8 @@ void ShowActStatus()
char demoname[13] = "DEMO?.";
#ifndef REMDEBUG
#define MAXDEMOSIZE 8192
void StartDemoRecord (int levelnumber)
{
demobuffer=malloc(MAXDEMOSIZE);
CHECKMALLOCRESULT(demobuffer);
demoptr = (int8_t *) demobuffer;
lastdemoptr = demoptr+MAXDEMOSIZE;
*demoptr = levelnumber;
demoptr += 4; // leave space for length
demorecord = true;
}
/*
==================
=
= FinishDemoRecord
=
==================
*/
void FinishDemoRecord (void)
{
int32_t length,level;
demorecord = false;
length = (int32_t) (demoptr - (int8_t *)demobuffer);
demoptr = ((int8_t *)demobuffer)+1;
demoptr[0] = (int8_t) length;
demoptr[1] = (int8_t) (length >> 8);
demoptr[2] = 0;
VW_FadeIn();
CenterWindow(24,3);
PrintY+=6;
fontnumber=0;
SETFONTCOLOR(0,15);
US_Print(" Demo number (0-9): ");
VW_UpdateScreen();
if (US_LineInput (px,py,str,NULL,true,1,0))
{
level = atoi (str);
if (level>=0 && level<=9)
{
demoname[4] = (char)('0'+level);
CA_WriteFile (demoname,demobuffer,length);
}
}
free(demobuffer);
}
//==========================================================================
/*
==================
=
= RecordDemo
=
= Fades the screen out, then starts a demo. Exits with the screen faded
=
==================
*/
void RecordDemo (void)
{
int level,esc,maps;
CenterWindow(26,3);
PrintY+=6;
CA_CacheGrChunk(STARTFONT);
fontnumber=0;
SETFONTCOLOR(0,15);
#ifndef SPEAR
#ifdef UPLOAD
US_Print(" Demo which level(1-10): "); maps = 10;
#else
US_Print(" Demo which level(1-60): "); maps = 60;
#endif
#else
US_Print(" Demo which level(1-21): "); maps = 21;
#endif
VW_UpdateScreen();
VW_FadeIn ();
esc = !US_LineInput (px,py,str,NULL,true,2,0);
if (esc)
return;
level = atoi (str);
level--;
if (level >= maps || level < 0)
return;
VW_FadeOut ();
#ifndef SPEAR
NewGame (gd_hard,level/10);
gamestate.mapon = level%10;
#else
NewGame (gd_hard,0);
gamestate.mapon = level;
#endif
StartDemoRecord (level);
DrawPlayScreen ();
VW_FadeIn ();
startgame = false;
demorecord = true;
SetupGameLevel ();
StartMusic ();
if(usedoublebuffering) VH_UpdateScreen();
fizzlein = true;
PlayLoop ();
demoplayback = false;
StopMusic ();
VW_FadeOut ();
ClearMemory ();
FinishDemoRecord ();
}
#else
void FinishDemoRecord (void) {return;}
void RecordDemo (void) {return;}
#endif
//==========================================================================