ref: 6b422a3ed52742adeb57da3fa934090130696d2a
parent: b83132a4962787aabf2e07ae90d37d6d87b001b3
parent: af553de8c714a80ea6ada5cc7487c689ed9fccb0
author: Simon Howard <fraggle@gmail.com>
date: Wed Aug 13 17:14:21 EDT 2014
Merge branch 'master' of github.com:chocolate-doom/chocolate-doom
--- a/configure.ac
+++ b/configure.ac
@@ -1,6 +1,7 @@
AC_INIT(Chocolate Doom, 2.0.0, fraggle@gmail.com, chocolate-doom)
-PACKAGE_SHORTDESC="Conservative Doom source port"
+PACKAGE_SHORTNAME=${PACKAGE_NAME% Doom}
+PACKAGE_SHORTDESC="Conservative source port"
PACKAGE_COPYRIGHT="Copyright (C) 1993-2013"
PACKAGE_LICENSE="GNU General Public License, version 2"
PACKAGE_MAINTAINER="Simon Howard"
@@ -135,6 +136,7 @@
AC_SUBST(ac_aux_dir)
+AC_SUBST(PACKAGE_SHORTNAME)
AC_SUBST(PACKAGE_SHORTDESC)
AC_SUBST(PACKAGE_COPYRIGHT)
AC_SUBST(PACKAGE_LICENSE)
@@ -160,7 +162,9 @@
src/doom.desktop
src/doom-screensaver.desktop
src/doom/Makefile
+src/heretic.desktop
src/heretic/Makefile
+src/hexen.desktop
src/hexen/Makefile
src/resource.rc
src/setup-res.rc
@@ -167,6 +171,7 @@
src/setup/Makefile
src/setup/setup.desktop
src/setup/setup-manifest.xml
+src/strife.desktop
src/strife/Makefile
textscreen/Makefile
textscreen/examples/Makefile
--- a/man/.gitignore
+++ b/man/.gitignore
@@ -1,3 +1,11 @@
+CMDLINE.doom
+CMDLINE.heretic
+CMDLINE.hexen
+CMDLINE.strife
+INSTALL.doom
+INSTALL.heretic
+INSTALL.hexen
+INSTALL.strife
Makefile.in
Makefile
*.6
--- a/msvc/doom.vcproj
+++ b/msvc/doom.vcproj
@@ -123,7 +123,11 @@
<Tool
Name="VCCLCompilerTool"
Optimization="2"
+ InlineFunctionExpansion="2"
EnableIntrinsicFunctions="true"
+ FavorSizeOrSpeed="1"
+ OmitFramePointers="true"
+ WholeProgramOptimization="true"
AdditionalIncludeDirectories=".;..\src;..\src\doom;..\textscreen;..\pcsound;..\opl"
PreprocessorDefinitions="WIN32;_CRT_SECURE_NO_WARNINGS;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;PROGRAM_PREFIX="\"chocolate-\"""
RuntimeLibrary="2"
@@ -130,7 +134,7 @@
EnableFunctionLevelLinking="true"
UsePrecompiledHeader="0"
WarningLevel="3"
- DebugInformationFormat="3"
+ DebugInformationFormat="0"
CompileAs="1"
/>
<Tool
@@ -149,6 +153,7 @@
LinkIncremental="0"
IgnoreDefaultLibraryNames="msvcrtd"
GenerateDebugInformation="false"
+ GenerateMapFile="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
--- a/msvc/heretic.vcproj
+++ b/msvc/heretic.vcproj
@@ -115,14 +115,17 @@
<Tool
Name="VCCLCompilerTool"
Optimization="2"
+ InlineFunctionExpansion="2"
EnableIntrinsicFunctions="true"
+ FavorSizeOrSpeed="1"
+ OmitFramePointers="true"
+ WholeProgramOptimization="true"
AdditionalIncludeDirectories=".;..\src;..\src\heretic;..\textscreen;..\pcsound;..\opl"
PreprocessorDefinitions="WIN32;_CRT_SECURE_NO_WARNINGS;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;PROGRAM_PREFIX="\"chocolate-\"""
- StringPooling="true"
- ExceptionHandling="0"
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
- WarningLevel="0"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
DebugInformationFormat="0"
CompileAs="1"
/>
@@ -139,11 +142,16 @@
Name="VCLinkerTool"
AdditionalDependencies="SDL.lib SDL_mixer.lib SDL_net.lib SDLmain.lib"
OutputFile="$(OutDir)\chocolate-heretic.exe"
+ LinkIncremental="0"
IgnoreDefaultLibraryNames="msvcrtd"
GenerateDebugInformation="false"
+ GenerateMapFile="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
+ LinkTimeCodeGeneration="1"
+ DataExecutionPrevention="0"
+ TurnOffAssemblyGeneration="false"
TargetMachine="1"
/>
<Tool
--- a/msvc/hexen.vcproj
+++ b/msvc/hexen.vcproj
@@ -116,14 +116,17 @@
<Tool
Name="VCCLCompilerTool"
Optimization="2"
+ InlineFunctionExpansion="2"
EnableIntrinsicFunctions="true"
+ FavorSizeOrSpeed="1"
+ OmitFramePointers="true"
+ WholeProgramOptimization="true"
AdditionalIncludeDirectories=".;..\src;..\src\hexen;..\textscreen;..\pcsound;..\opl"
PreprocessorDefinitions="WIN32;_CRT_SECURE_NO_WARNINGS;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;PROGRAM_PREFIX="\"chocolate-\"""
- StringPooling="true"
- ExceptionHandling="0"
RuntimeLibrary="2"
EnableFunctionLevelLinking="true"
- WarningLevel="0"
+ UsePrecompiledHeader="0"
+ WarningLevel="3"
DebugInformationFormat="0"
CompileAs="1"
/>
@@ -140,11 +143,16 @@
Name="VCLinkerTool"
AdditionalDependencies="SDL.lib SDL_mixer.lib SDL_net.lib SDLmain.lib"
OutputFile="$(OutDir)\chocolate-hexen.exe"
+ LinkIncremental="0"
IgnoreDefaultLibraryNames="msvcrtd"
GenerateDebugInformation="false"
+ GenerateMapFile="true"
SubSystem="1"
OptimizeReferences="2"
EnableCOMDATFolding="2"
+ LinkTimeCodeGeneration="1"
+ DataExecutionPrevention="0"
+ TurnOffAssemblyGeneration="false"
TargetMachine="1"
/>
<Tool
--- a/src/.gitignore
+++ b/src/.gitignore
@@ -6,6 +6,11 @@
chocolate-heretic
chocolate-hexen
chocolate-server
+chocolate-strife
+chocolate-doom-setup
+chocolate-heretic-setup
+chocolate-hexen-setup
+chocolate-strife-setup
chocolate-setup
*.exe
*.desktop
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -218,10 +218,23 @@
manifest.xml
appdir = $(prefix)/share/applications
-app_DATA = @PROGRAM_PREFIX@doom.desktop
+app_DATA = \
+ @PROGRAM_PREFIX@doom.desktop \
+ @PROGRAM_PREFIX@heretic.desktop \
+ @PROGRAM_PREFIX@hexen.desktop \
+ @PROGRAM_PREFIX@strife.desktop
@PROGRAM_PREFIX@doom.desktop : doom.desktop
cp doom.desktop $@
+
+@PROGRAM_PREFIX@heretic.desktop : heretic.desktop
+ cp heretic.desktop $@
+
+@PROGRAM_PREFIX@hexen.desktop : hexen.desktop
+ cp hexen.desktop $@
+
+@PROGRAM_PREFIX@strife.desktop : strife.desktop
+ cp strife.desktop $@
screensaverdir = $(prefix)/share/applications/screensavers
screensaver_DATA = @PROGRAM_PREFIX@doom-screensaver.desktop
--- a/src/deh_io.c
+++ b/src/deh_io.c
@@ -137,6 +137,7 @@
W_ReleaseLumpNum(context->lumpnum);
}
+ free(context->filename);
Z_Free(context->readbuffer);
Z_Free(context);
}
--- a/src/deh_main.c
+++ b/src/deh_main.c
@@ -346,6 +346,12 @@
deh_context_t *context;
boolean long_strings, long_cheats;
+ if (!deh_initialized)
+ {
+ InitializeSections();
+ deh_initialized = true;
+ }
+
if (allow_long)
{
long_strings = deh_allow_long_strings;
--- a/src/doom-screensaver.desktop.in
+++ b/src/doom-screensaver.desktop.in
@@ -1,6 +1,5 @@
-
[Desktop Entry]
-Name=@PACKAGE_NAME@
+Name=@PACKAGE_SHORTNAME@ Doom
Comment=@PACKAGE_SHORTDESC@
TryExec=@PROGRAM_PREFIX@doom
Exec=@PROGRAM_PREFIX@doom
@@ -7,6 +6,5 @@
StartupNotify=false
Terminal=false
Type=Application
-OnlyShowIn=GNOME;
+OnlyShowIn=GNOME;MATE;
Categories=Screensaver;
-
--- a/src/doom.desktop.in
+++ b/src/doom.desktop.in
@@ -1,5 +1,5 @@
[Desktop Entry]
-Name=@PACKAGE_NAME@
+Name=@PACKAGE_SHORTNAME@ Doom
Exec=@PROGRAM_PREFIX@doom
Icon=@PROGRAM_PREFIX@doom
Type=Application
--- a/src/doom/p_enemy.c
+++ b/src/doom/p_enemy.c
@@ -257,11 +257,6 @@
fixed_t xspeed[8] = {FRACUNIT,47000,0,-47000,-FRACUNIT,-47000,0,47000};
fixed_t yspeed[8] = {0,47000,FRACUNIT,47000,0,-47000,-FRACUNIT,-47000};
-#define MAXSPECIALCROSS 8
-
-extern line_t* spechit[MAXSPECIALCROSS];
-extern int numspechit;
-
boolean P_Move (mobj_t* actor)
{
fixed_t tryx;
--- a/src/doom/p_local.h
+++ b/src/doom/p_local.h
@@ -208,6 +208,20 @@
extern line_t* ceilingline;
+// fraggle: I have increased the size of this buffer. In the original Doom,
+// overrunning past this limit caused other bits of memory to be overwritten,
+// affecting demo playback. However, in doing so, the limit was still
+// exceeded. So we have to support more than 8 specials.
+//
+// We keep the original limit, to detect what variables in memory were
+// overwritten (see SpechitOverrun())
+
+#define MAXSPECIALCROSS 20
+#define MAXSPECIALCROSS_ORIGINAL 8
+
+extern line_t* spechit[MAXSPECIALCROSS];
+extern int numspechit;
+
boolean P_CheckPosition (mobj_t *thing, fixed_t x, fixed_t y);
boolean P_TryMove (mobj_t* thing, fixed_t x, fixed_t y);
boolean P_TeleportMove (mobj_t* thing, fixed_t x, fixed_t y);
--- a/src/doom/p_map.c
+++ b/src/doom/p_map.c
@@ -82,17 +82,6 @@
// keep track of special lines as they are hit,
// but don't process them until the move is proven valid
-// fraggle: I have increased the size of this buffer. In the original Doom,
-// overrunning past this limit caused other bits of memory to be overwritten,
-// affecting demo playback. However, in doing so, the limit was still
-// exceeded. So we have to support more than 8 specials.
-//
-// We keep the original limit, to detect what variables in memory were
-// overwritten (see SpechitOverrun())
-
-#define MAXSPECIALCROSS 20
-#define MAXSPECIALCROSS_ORIGINAL 8
-
line_t* spechit[MAXSPECIALCROSS];
int numspechit;
--- /dev/null
+++ b/src/heretic.desktop.in
@@ -1,0 +1,7 @@
+[Desktop Entry]
+Name=@PACKAGE_SHORTNAME@ Heretic
+Exec=@PROGRAM_PREFIX@heretic
+Icon=@PROGRAM_PREFIX@doom
+Type=Application
+Comment=@PACKAGE_SHORTDESC@
+Categories=Game;ActionGame;
--- /dev/null
+++ b/src/hexen.desktop.in
@@ -1,0 +1,7 @@
+[Desktop Entry]
+Name=@PACKAGE_SHORTNAME@ Hexen
+Exec=@PROGRAM_PREFIX@hexen
+Icon=@PROGRAM_PREFIX@doom
+Type=Application
+Comment=@PACKAGE_SHORTDESC@
+Categories=Game;ActionGame;
--- a/src/setup/joystick.c
+++ b/src/setup/joystick.c
@@ -206,6 +206,26 @@
{NULL, 0},
};
+// Xbox 360 controller under Linux.
+static const joystick_config_t xbox360_controller_linux[] =
+{
+ {"joystick_x_axis", CREATE_HAT_AXIS(0, HAT_AXIS_HORIZONTAL)},
+ {"joystick_y_axis", CREATE_HAT_AXIS(0, HAT_AXIS_VERTICAL)},
+ // Ideally we'd like the trigger buttons to be strafe left/right
+ // But Linux presents each trigger button as its own axis, which
+ // we can't really work with. So we have to settle for a
+ // suboptimal setup.
+ {"joyb_fire", 2}, // X
+ {"joyb_speed", 0}, // A
+ {"joyb_jump", 3}, // Y
+ {"joyb_use", 1}, // B
+ {"joyb_strafeleft", 4}, // LB
+ {"joyb_straferight", 5}, // RB
+ {"joyb_menu_activate", 7}, // Start
+ {"joyb_prevweapon", 6}, // Back
+ {NULL, 0},
+};
+
// Logitech Dual Action (F310, F710). Thanks to Brad Harding for details.
static const joystick_config_t logitech_f310_controller[] =
{
@@ -247,6 +267,13 @@
"Controller (XBOX 360 For Windows)",
5, 10, 1,
xbox360_controller,
+ },
+
+ // Xbox 360 controller as it appears on Linux.
+ {
+ "Microsoft X-Box 360 pad",
+ 6, 11, 1,
+ xbox360_controller_linux,
},
{
--- a/src/setup/setup.desktop.in
+++ b/src/setup/setup.desktop.in
@@ -1,7 +1,7 @@
[Desktop Entry]
-Name=@PACKAGE_NAME@ Setup
-Exec=@PROGRAM_PREFIX@doom-setup
+Name=@PACKAGE_SHORTNAME@ Setup
+Exec=@PROGRAM_PREFIX@setup
Icon=@PROGRAM_PREFIX@setup
Type=Application
-Comment=Setup tool for @PACKAGE_NAME@
+Comment=Setup tool for @PACKAGE_SHORTNAME@
Categories=Settings
--- /dev/null
+++ b/src/strife.desktop.in
@@ -1,0 +1,7 @@
+[Desktop Entry]
+Name=@PACKAGE_SHORTNAME@ Strife
+Exec=@PROGRAM_PREFIX@strife
+Icon=@PROGRAM_PREFIX@doom
+Type=Application
+Comment=@PACKAGE_SHORTDESC@
+Categories=Game;ActionGame;