diff --git a/doomsday/plugins/common/include/common.h b/doomsday/plugins/common/include/common.h new file mode 100644 index 0000000000..e5b7436225 --- /dev/null +++ b/doomsday/plugins/common/include/common.h @@ -0,0 +1,39 @@ +/**\file + *\section License + * License: GPL + * Online License Link: http://www.gnu.org/licenses/gpl.html + * + *\author Copyright © 2011 Jaakko Keränen + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, + * Boston, MA 02110-1301 USA + */ + +#ifndef __COMMON_GAME_INCLUDES__ +#define __COMMON_GAME_INCLUDES__ + +#if __JDOOM__ +# include "jdoom.h" +#elif __JDOOM64__ +# include "jdoom64.h" +#elif __JHERETIC__ +# include "jheretic.h" +#elif __JHEXEN__ +# include "jhexen.h" +#elif __JSTRIFE__ +# include "jstrife.h" +#endif + +#endif // __COMMON_GAME_INCLUDES__ diff --git a/doomsday/plugins/common/include/d_netsv.h b/doomsday/plugins/common/include/d_netsv.h index b304082c59..6bedbe1a2e 100644 --- a/doomsday/plugins/common/include/d_netsv.h +++ b/doomsday/plugins/common/include/d_netsv.h @@ -25,17 +25,7 @@ #ifndef __D_NETSV_H__ #define __D_NETSV_H__ -#if __JDOOM__ -# include "jdoom.h" -#elif __JDOOM64__ -# include "jdoom64.h" -#elif __JHERETIC__ -# include "jheretic.h" -#elif __JHEXEN__ -# include "jhexen.h" -#elif __JSTRIFE__ -# include "jstrife.h" -#endif +#include "common.h" extern char cyclingMaps, mapCycleNoExit; extern int netSvAllowCheats; diff --git a/doomsday/plugins/common/include/g_common.h b/doomsday/plugins/common/include/g_common.h index dc9c0704f9..379f1fba95 100644 --- a/doomsday/plugins/common/include/g_common.h +++ b/doomsday/plugins/common/include/g_common.h @@ -31,18 +31,7 @@ #include "dd_share.h" #include "g_controls.h" - -#if __JDOOM__ -# include "jdoom.h" -#elif __JDOOM64__ -# include "jdoom64.h" -#elif __JHERETIC__ -# include "jheretic.h" -#elif __JHEXEN__ -# include "jhexen.h" -#elif __JSTRIFE__ -# include "jstrife.h" -#endif +#include "common.h" #define OBSOLETE CVF_HIDE|CVF_NO_ARCHIVE diff --git a/doomsday/plugins/common/src/am_map.c b/doomsday/plugins/common/src/am_map.c index 2efaf1cc9b..3e4b6c8b4b 100644 --- a/doomsday/plugins/common/src/am_map.c +++ b/doomsday/plugins/common/src/am_map.c @@ -34,18 +34,7 @@ #include #include -#if __JDOOM__ -# include "jdoom.h" -#elif __JDOOM64__ -# include "jdoom64.h" -#elif __JHERETIC__ -# include "jheretic.h" -#elif __JHEXEN__ -# include "jhexen.h" -#elif __JSTRIFE__ -# include "jstrife.h" -#endif - +#include "common.h" #include "p_mapsetup.h" #include "hu_stuff.h" #include "hu_menu.h" diff --git a/doomsday/plugins/common/src/d_net.c b/doomsday/plugins/common/src/d_net.c index df725516e9..84e4eadd89 100644 --- a/doomsday/plugins/common/src/d_net.c +++ b/doomsday/plugins/common/src/d_net.c @@ -32,18 +32,7 @@ // HEADER FILES ------------------------------------------------------------ -#if __JDOOM__ -# include "jdoom.h" -#elif __JDOOM64__ -# include "jdoom64.h" -#elif __JHERETIC__ -# include "jheretic.h" -#elif __JHEXEN__ -# include "jhexen.h" -#elif __JSTRIFE__ -# include "jstrife.h" -#endif - +#include "common.h" #include "g_common.h" #include "d_net.h" #include "p_player.h" diff --git a/doomsday/plugins/common/src/d_netcl.c b/doomsday/plugins/common/src/d_netcl.c index 9481da0489..b603d101cd 100644 --- a/doomsday/plugins/common/src/d_netcl.c +++ b/doomsday/plugins/common/src/d_netcl.c @@ -32,16 +32,7 @@ #include #include -#if __JDOOM__ -# include "jdoom.h" -#elif __JDOOM64__ -# include "jdoom64.h" -#elif __JHERETIC__ -# include "jheretic.h" -#elif __JHEXEN__ -# include "jhexen.h" -#endif - +#include "common.h" #include "am_map.h" #include "p_saveg.h" #include "d_net.h" diff --git a/doomsday/plugins/common/src/d_netsv.c b/doomsday/plugins/common/src/d_netsv.c index a91404f7a6..a6ab65828f 100644 --- a/doomsday/plugins/common/src/d_netsv.c +++ b/doomsday/plugins/common/src/d_netsv.c @@ -33,16 +33,7 @@ #include #include -#if __JDOOM__ -# include "jdoom.h" -#elif __JDOOM64__ -# include "jdoom64.h" -#elif __JHERETIC__ -# include "jheretic.h" -#elif __JHEXEN__ -# include "jhexen.h" -#endif - +#include "common.h" #include "d_net.h" #include "p_svtexarc.h" #include "p_player.h" diff --git a/doomsday/plugins/common/src/dmu_lib.c b/doomsday/plugins/common/src/dmu_lib.c index fb18a58866..bd5c45c688 100644 --- a/doomsday/plugins/common/src/dmu_lib.c +++ b/doomsday/plugins/common/src/dmu_lib.c @@ -31,18 +31,7 @@ #include #include -#if __JDOOM__ -# include "jdoom.h" -#elif __JDOOM64__ -# include "jdoom64.h" -#elif __JHERETIC__ -# include "jheretic.h" -#elif __JHEXEN__ -# include "jhexen.h" -#elif __JSTRIFE__ -# include "jstrife.h" -#endif - +#include "common.h" #include "dmu_lib.h" // MACROS ------------------------------------------------------------------