mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-10 23:02:03 +00:00
added some mapster32 config vars; fixed mapster32 crash in linux; DEBUGANYWAY for Makefiles
git-svn-id: https://svn.eduke32.com/eduke32@1296 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
e9821ccb35
commit
ba394b0bcf
5 changed files with 39 additions and 8 deletions
|
@ -24,6 +24,7 @@ RANCID_NETWORKING = 1
|
||||||
|
|
||||||
# Debugging/Build options
|
# Debugging/Build options
|
||||||
RELEASE?=1
|
RELEASE?=1
|
||||||
|
DEBUGANYWAY?=0
|
||||||
NOSOUND?=0
|
NOSOUND?=0
|
||||||
USE_OPENAL ?= 1
|
USE_OPENAL ?= 1
|
||||||
OPTLEVEL?=2
|
OPTLEVEL?=2
|
||||||
|
@ -46,6 +47,10 @@ else
|
||||||
debug=-ggdb -O0 -DDEBUGGINGAIDS
|
debug=-ggdb -O0 -DDEBUGGINGAIDS
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifneq (0,$(DEBUGANYWAY))
|
||||||
|
debug+=-ggdb
|
||||||
|
endif
|
||||||
|
|
||||||
CC=gcc
|
CC=gcc
|
||||||
CXX=g++
|
CXX=g++
|
||||||
AS=nasm
|
AS=nasm
|
||||||
|
@ -261,21 +266,27 @@ eduke32$(EXESUFFIX): $(GAMEOBJS) $(EOBJ)/$(ENGINELIB)
|
||||||
$(LINK_STATUS)
|
$(LINK_STATUS)
|
||||||
if $(CC) -o $@ $^ $(LIBS) $(STDCPPLIB); then $(LINK_OK); else $(LINK_FAILED); fi
|
if $(CC) -o $@ $^ $(LIBS) $(STDCPPLIB); then $(LINK_OK); else $(LINK_FAILED); fi
|
||||||
ifeq (1,$(RELEASE))
|
ifeq (1,$(RELEASE))
|
||||||
|
ifneq (0,$(DEBUGANYWAY))
|
||||||
strip eduke32$(EXESUFFIX)
|
strip eduke32$(EXESUFFIX)
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
mapster32$(EXESUFFIX): $(EDITOROBJS) $(EOBJ)/$(EDITORLIB) $(EOBJ)/$(ENGINELIB)
|
mapster32$(EXESUFFIX): $(EDITOROBJS) $(EOBJ)/$(EDITORLIB) $(EOBJ)/$(ENGINELIB)
|
||||||
$(LINK_STATUS)
|
$(LINK_STATUS)
|
||||||
if $(CC) $(CFLAGS) $(OURCFLAGS) -o $@ $^ $(LIBS) $(STDCPPLIB); then $(LINK_OK); else $(LINK_FAILED); fi
|
if $(CC) $(CFLAGS) $(OURCFLAGS) -o $@ $^ $(LIBS) $(STDCPPLIB); then $(LINK_OK); else $(LINK_FAILED); fi
|
||||||
ifeq (1,$(RELEASE))
|
ifeq (1,$(RELEASE))
|
||||||
|
ifneq (0,$(DEBUGANYWAY))
|
||||||
strip mapster32$(EXESUFFIX)
|
strip mapster32$(EXESUFFIX)
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
duke3d_w32$(EXESUFFIX): $(OBJ)/wrapper.$o
|
duke3d_w32$(EXESUFFIX): $(OBJ)/wrapper.$o
|
||||||
$(LINK_STATUS)
|
$(LINK_STATUS)
|
||||||
if $(CC) $(CFLAGS) $(OURCFLAGS) -o $@ $^ -Wl; then $(LINK_OK); else $(LINK_FAILED); fi
|
if $(CC) $(CFLAGS) $(OURCFLAGS) -o $@ $^ -Wl; then $(LINK_OK); else $(LINK_FAILED); fi
|
||||||
ifeq (1,$(RELEASE))
|
ifeq (1,$(RELEASE))
|
||||||
|
ifneq (0,$(DEBUGANYWAY))
|
||||||
strip duke3d_w32$(EXESUFFIX)
|
strip duke3d_w32$(EXESUFFIX)
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
include Makefile.deps
|
include Makefile.deps
|
||||||
|
|
|
@ -35,6 +35,7 @@ RANCID_NETWORKING ?= 0
|
||||||
# OPTLEVEL - 0..3 = GCC optimization strategy
|
# OPTLEVEL - 0..3 = GCC optimization strategy
|
||||||
#
|
#
|
||||||
RELEASE?=1
|
RELEASE?=1
|
||||||
|
DEBUGANYWAY?=0
|
||||||
EFENCE?=0
|
EFENCE?=0
|
||||||
OPTLEVEL ?= 2
|
OPTLEVEL ?= 2
|
||||||
|
|
||||||
|
@ -68,6 +69,10 @@ else
|
||||||
debug=-ggdb -O0 -DDEBUGGINGAIDS -DNOSDLPARACHUTE
|
debug=-ggdb -O0 -DDEBUGGINGAIDS -DNOSDLPARACHUTE
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifneq (0,$(DEBUGANYWAY))
|
||||||
|
debug+=-ggdb
|
||||||
|
endif
|
||||||
|
|
||||||
CC=gcc
|
CC=gcc
|
||||||
CXX=gcc
|
CXX=gcc
|
||||||
AS=nasm
|
AS=nasm
|
||||||
|
|
|
@ -66,6 +66,8 @@ extern double msens;
|
||||||
extern int32_t editorgridextent;
|
extern int32_t editorgridextent;
|
||||||
extern int32_t showheightindicators;
|
extern int32_t showheightindicators;
|
||||||
extern int32_t graphicsmode;
|
extern int32_t graphicsmode;
|
||||||
|
extern int32_t AmbienceToggle;
|
||||||
|
extern int32_t ParentalLock;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* SETUP.DAT
|
* SETUP.DAT
|
||||||
|
@ -232,6 +234,10 @@ int32_t loadsetup(const char *fn)
|
||||||
if (readconfig(fp, "graphicsmode", val, VL) > 0)
|
if (readconfig(fp, "graphicsmode", val, VL) > 0)
|
||||||
graphicsmode = min(max(Batoi(val),0),2);
|
graphicsmode = min(max(Batoi(val),0),2);
|
||||||
|
|
||||||
|
if (readconfig(fp, "ambiencetoggle", val, VL) > 0) AmbienceToggle = Batoi(val);
|
||||||
|
|
||||||
|
if (readconfig(fp, "parlock", val, VL) > 0) ParentalLock = Batoi(val);
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
{
|
{
|
||||||
extern char map_dik_code(int32_t);
|
extern char map_dik_code(int32_t);
|
||||||
|
@ -376,10 +382,13 @@ int32_t writesetup(const char *fn)
|
||||||
"autosavesec = %d\n"
|
"autosavesec = %d\n"
|
||||||
"\n"
|
"\n"
|
||||||
"; Height indicators (0:none, 1:only 2-sided&different, 2:all)\n"
|
"; Height indicators (0:none, 1:only 2-sided&different, 2:all)\n"
|
||||||
"showheightindicators = %d\n\n"
|
"showheightindicators = %d\n"
|
||||||
"\n"
|
"\n"
|
||||||
"; 2D mode display type (0:classic, 1:textured, 2:textured/animated)\n"
|
"; 2D mode display type (0:classic, 1:textured, 2:textured/animated)\n"
|
||||||
"graphicsmode = %d\n\n"
|
"graphicsmode = %d\n\n"
|
||||||
|
"; Ambient sounds in 3D mode (0:off, 1:on)\n"
|
||||||
|
"ambiencetoggle = %d\n"
|
||||||
|
"parlock = %d\n\n"
|
||||||
#if 1
|
#if 1
|
||||||
"; Key Settings\n"
|
"; Key Settings\n"
|
||||||
"; Here's a map of all the keyboard scan codes: NOTE: values are listed in hex!\n"
|
"; Here's a map of all the keyboard scan codes: NOTE: values are listed in hex!\n"
|
||||||
|
@ -425,6 +434,8 @@ int32_t writesetup(const char *fn)
|
||||||
#endif
|
#endif
|
||||||
// "; Console key scancode, in hex\n"
|
// "; Console key scancode, in hex\n"
|
||||||
"keyconsole = %X\n"
|
"keyconsole = %X\n"
|
||||||
|
"; example: make 'Q' function as CapsLock and 'N' as AltGr:\n"
|
||||||
|
"; remap = 10-3A,31-B8\n"
|
||||||
"remap = ",
|
"remap = ",
|
||||||
|
|
||||||
forcesetup, fullscreen, xdim2d, ydim2d, xdimgame, ydimgame, bppgame,
|
forcesetup, fullscreen, xdim2d, ydim2d, xdimgame, ydimgame, bppgame,
|
||||||
|
@ -441,7 +452,7 @@ int32_t writesetup(const char *fn)
|
||||||
#endif
|
#endif
|
||||||
option[3], msens, unrealedlook, pk_uedaccel, quickmapcycling,
|
option[3], msens, unrealedlook, pk_uedaccel, quickmapcycling,
|
||||||
revertCTRL,scrollamount,pk_turnaccel,pk_turndecel,autosave,
|
revertCTRL,scrollamount,pk_turnaccel,pk_turndecel,autosave,
|
||||||
showheightindicators,graphicsmode,
|
showheightindicators,graphicsmode,AmbienceToggle,ParentalLock,
|
||||||
#if 1
|
#if 1
|
||||||
keys[0], keys[1], keys[2], keys[3], keys[4], keys[5],
|
keys[0], keys[1], keys[2], keys[3], keys[4], keys[5],
|
||||||
keys[6], keys[7], keys[8], keys[9], keys[10], keys[11],
|
keys[6], keys[7], keys[8], keys[9], keys[10], keys[11],
|
||||||
|
|
|
@ -1966,6 +1966,7 @@ static int32_t dist(spritetype *s1,spritetype *s2)
|
||||||
extern int32_t NumVoices;
|
extern int32_t NumVoices;
|
||||||
extern int32_t g_numEnvSoundsPlaying;
|
extern int32_t g_numEnvSoundsPlaying;
|
||||||
int32_t AmbienceToggle = 1; //SoundToggle;
|
int32_t AmbienceToggle = 1; //SoundToggle;
|
||||||
|
int32_t ParentalLock = 0;
|
||||||
#define T1 (s->filler)
|
#define T1 (s->filler)
|
||||||
|
|
||||||
// adapted from actors.c
|
// adapted from actors.c
|
||||||
|
@ -4225,14 +4226,14 @@ static void Keys3d(void)
|
||||||
|
|
||||||
if (keystatus[KEYSC_F3])
|
if (keystatus[KEYSC_F3])
|
||||||
{
|
{
|
||||||
mlook = 1-mlook;
|
mlook = !mlook;
|
||||||
message("Mouselook: %s",mlook?"enabled":"disabled");
|
message("Mouselook: %s",mlook?"enabled":"disabled");
|
||||||
keystatus[KEYSC_F3] = 0;
|
keystatus[KEYSC_F3] = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (keystatus[KEYSC_F4])
|
if (keystatus[KEYSC_F4])
|
||||||
{
|
{
|
||||||
AmbienceToggle = 1-AmbienceToggle;
|
AmbienceToggle = !AmbienceToggle;
|
||||||
message("Ambience sounds: %s",AmbienceToggle?"enabled":"disabled");
|
message("Ambience sounds: %s",AmbienceToggle?"enabled":"disabled");
|
||||||
if (!AmbienceToggle)
|
if (!AmbienceToggle)
|
||||||
{
|
{
|
||||||
|
@ -4245,7 +4246,7 @@ static void Keys3d(void)
|
||||||
// PK
|
// PK
|
||||||
if (keystatus[KEYSC_F5])
|
if (keystatus[KEYSC_F5])
|
||||||
{
|
{
|
||||||
unrealedlook = 1-unrealedlook;
|
unrealedlook = !unrealedlook;
|
||||||
message("UnrealEd mouse navigation: %s",unrealedlook?"enabled":"disabled");
|
message("UnrealEd mouse navigation: %s",unrealedlook?"enabled":"disabled");
|
||||||
keystatus[KEYSC_F5] = 0;
|
keystatus[KEYSC_F5] = 0;
|
||||||
}
|
}
|
||||||
|
@ -9092,8 +9093,8 @@ int32_t parseconsounds(scriptfile *script)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (g_sounds[sndnum].filename == NULL)
|
if (g_sounds[sndnum].filename == NULL)
|
||||||
g_sounds[sndnum].filename = Bcalloc(BMAX_PATH,sizeof(uint8_t));
|
g_sounds[sndnum].filename = Bcalloc(slen+1,sizeof(uint8_t));
|
||||||
// do other callers ever mess with g_sounds[].filename?
|
// Hopefully noone does memcpy(..., g_sounds[].filename, BMAX_PATH)
|
||||||
if (!g_sounds[sndnum].filename)
|
if (!g_sounds[sndnum].filename)
|
||||||
{
|
{
|
||||||
Bfree(definedname);
|
Bfree(definedname);
|
||||||
|
@ -9105,6 +9106,7 @@ int32_t parseconsounds(scriptfile *script)
|
||||||
if (scriptfile_getnumber(script, &pe)) goto BAD;
|
if (scriptfile_getnumber(script, &pe)) goto BAD;
|
||||||
if (scriptfile_getnumber(script, &pr)) goto BAD;
|
if (scriptfile_getnumber(script, &pr)) goto BAD;
|
||||||
if (scriptfile_getnumber(script, &m)) goto BAD;
|
if (scriptfile_getnumber(script, &m)) goto BAD;
|
||||||
|
if (ParentalLock && (m&8)) goto BAD;
|
||||||
if (scriptfile_getnumber(script, &vo)) goto BAD;
|
if (scriptfile_getnumber(script, &vo)) goto BAD;
|
||||||
if (0)
|
if (0)
|
||||||
{
|
{
|
||||||
|
@ -9124,6 +9126,8 @@ BAD:
|
||||||
g_sounds[sndnum].vo = vo;
|
g_sounds[sndnum].vo = vo;
|
||||||
g_sndnum[g_numsounds] = g_definedsndnum[g_numsounds] = sndnum;
|
g_sndnum[g_numsounds] = g_definedsndnum[g_numsounds] = sndnum;
|
||||||
g_numsounds++;
|
g_numsounds++;
|
||||||
|
if (g_numsounds == MAXSOUNDS)
|
||||||
|
goto END;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case T_EOF:
|
case T_EOF:
|
||||||
|
|
|
@ -78,7 +78,7 @@ int32_t xoldtimerhandler, lastmessagetime=-1;
|
||||||
char tempbuf[1024]; //1024
|
char tempbuf[1024]; //1024
|
||||||
int32_t numsprite[MAXSPRITES];
|
int32_t numsprite[MAXSPRITES];
|
||||||
int32_t multisprite[MAXSPRITES];
|
int32_t multisprite[MAXSPRITES];
|
||||||
char lo[32];
|
char lo[64];
|
||||||
char levelname[255];
|
char levelname[255];
|
||||||
int16_t curwall=0,curwallnum=0;
|
int16_t curwall=0,curwallnum=0;
|
||||||
int16_t cursearchsprite=0,cursearchspritenum=0,cursector_lotag=0,cursectornum=0;
|
int16_t cursearchsprite=0,cursearchspritenum=0,cursector_lotag=0,cursectornum=0;
|
||||||
|
|
Loading…
Reference in a new issue