Prepare for precompiled headers

stable-5.2
Nicolas Hake 2009-10-20 05:39:24 +02:00
parent 7b2d506869
commit f0fdf5e992
46 changed files with 414 additions and 285 deletions

View File

@ -8,6 +8,13 @@ separate_arguments(OC_CXX_FLAGS)
set(OC_CXX_FLAGS_DEBUG ${CMAKE_CXX_FLAGS_DEBUG})
separate_arguments(OC_CXX_FLAGS_DEBUG)
############################################################################
# List target source files. Don't directly create a target since we condi-
# tionally add more sources depending on configuration options later.
############################################################################
# OC_CLONK_SOURCES: Sources for OpenClonk that are needed by every build.
# OC_SYSTEM_SOURCES: Sources for OpenClonk that are only needed by specific
# configurations.
set(OC_CLONK_SOURCES
src/C4Application.cpp
src/C4Application.h
@ -379,10 +386,6 @@ mark_as_advanced(OC_CLONK_SOURCES)
mark_as_advanced(OC_SYSTEM_SOURCES)
if(WIN32)
list(APPEND OC_CLONK_SOURCES
src/res/engine.rc
src/res/resource.h
)
list(APPEND OC_SYSTEM_SOURCES
src/platform/StdWindow.cpp
src/platform/StdJoystick.cpp
@ -433,11 +436,6 @@ if(USE_GTK)
)
endif()
add_executable(clonk WIN32 MACOSX_BUNDLE
${OC_SYSTEM_SOURCES}
${OC_CLONK_SOURCES}
)
source_group("Unsorted" .*)
source_group("Library\\Platform abstraction" src/platform/.*)
source_group("Library\\Utility" src/lib/.*)
@ -454,24 +452,6 @@ source_group("Config" src/config/.*)
source_group("Control" src/control/.*)
source_group("Editing" src/editor/.*)
add_executable(c4group
src/c4group/c4group_ng.cpp
src/c4group/C4Group.cpp
src/lib/C4InputValidation.cpp
src/config/C4SecurityCertificates.cpp
src/c4group/C4Update.cpp
src/lib/Standard.cpp
src/c4group/CStdFile.cpp
src/lib/StdMarkup.cpp
src/lib/StdBuf.cpp
src/lib/StdCompiler.cpp
src/platform/StdFile.cpp
src/platform/StdRegistry.cpp
src/lib/StdResStr2.cpp
src/platform/StdConfig.cpp
src/zlib/gzio.c
)
include_directories(
${CMAKE_CURRENT_BINARY_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/src
@ -493,8 +473,9 @@ include_directories(
${CMAKE_CURRENT_SOURCE_DIR}/src/script
)
set_property(TARGET clonk APPEND PROPERTY COMPILE_DEFINITIONS C4ENGINE GLEW_STATIC)
set_property(DIRECTORY APPEND PROPERTY COMPILE_DEFINITIONS_DEBUG _DEBUG)
############################################################################
# Check for required system headers
############################################################################
include(CheckIncludeFileCXX)
CHECK_INCLUDE_FILE_CXX(direct.h HAVE_DIRECT_H)
CHECK_INCLUDE_FILE_CXX(io.h HAVE_IO_H)
@ -528,41 +509,9 @@ endif()
include(CheckFunctionExists)
CHECK_FUNCTION_EXISTS(vasprintf HAVE_VASPRINTF)
# User selectable options
option(USE_GL "Enable OpenGL support" ON)
if(APPLE)
SET(INITIAL_USE_SDL_MAINLOOP_VALUE ON)
else()
SET(INITIAL_USE_SDL_MAINLOOP_VALUE OFF)
endif()
option(USE_SDL_MAINLOOP "Use SDL to create windows etc." ${INITIAL_USE_SDL_MAINLOOP_VALUE})
if(WIN32)
option(USE_DIRECTX "Enable DirectX support" ON)
option(USE_FMOD "Enable FMOD support" ON)
if(EXISTS $ENV{DXSDK_DIR})
include_directories(SYSTEM $ENV{DXSDK_DIR}/Include)
if(${FIND_LIBRARY_USE_LIB64_PATHS})
list(APPEND CMAKE_LIBRARY_PATH $ENV{DXSDK_DIR}/Lib/x64)
else()
list(APPEND CMAKE_LIBRARY_PATH $ENV{DXSDK_DIR}/Lib/x86)
endif()
endif()
else()
SET(USE_DIRECTX OFF)
SET(USE_FMOD OFF)
endif()
if(UNIX)
option(USE_X11 "Use X11 to create windows etc." ON)
option(USE_GTK "Use GTK for the developer mode" ON)
else()
SET(USE_X11 OFF)
SET(USE_GTK OFF)
endif()
if(NOT USE_GL AND NOT USE_DIRECTX)
message(STATUS "No graphics display enabled; building dedicated server")
SET(USE_CONSOLE ON CACHE INTERNAL "Build dedicated server")
endif()
############################################################################
# Locate necessary libraries
############################################################################
# Find win32 SDK, since a lot of users don't have the include path in their environment
if(WIN32)
get_filename_component(WINSDK_ROOT "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows;CurrentInstallFolder]" ABSOLUTE CACHE)
@ -600,7 +549,147 @@ endmacro(FINDLIB)
# isilkor 09-05-29: Don't use FindOpenSSL, because that wants to link to ssleay
FINDLIB(OPENSSL_LIBRARIES NAMES crypto libeay32)
# Optional libraries
############################################################################
# User selectable options
############################################################################
option(USE_GL "Enable OpenGL support" ON)
if(APPLE)
SET(INITIAL_USE_SDL_MAINLOOP_VALUE ON)
else()
SET(INITIAL_USE_SDL_MAINLOOP_VALUE OFF)
endif()
option(USE_SDL_MAINLOOP "Use SDL to create windows etc." ${INITIAL_USE_SDL_MAINLOOP_VALUE})
if(WIN32)
option(USE_DIRECTX "Enable DirectX support" ON)
option(USE_FMOD "Enable FMOD support" ON)
if(EXISTS $ENV{DXSDK_DIR})
include_directories(SYSTEM $ENV{DXSDK_DIR}/Include)
if(${FIND_LIBRARY_USE_LIB64_PATHS})
list(APPEND CMAKE_LIBRARY_PATH $ENV{DXSDK_DIR}/Lib/x64)
else()
list(APPEND CMAKE_LIBRARY_PATH $ENV{DXSDK_DIR}/Lib/x86)
endif()
endif()
else()
SET(USE_DIRECTX OFF)
SET(USE_FMOD OFF)
endif()
if(UNIX)
option(USE_X11 "Use X11 to create windows etc." ON)
option(USE_GTK "Use GTK for the developer mode" ON)
else()
SET(USE_X11 OFF)
SET(USE_GTK OFF)
endif()
if(NOT USE_GL AND NOT USE_DIRECTX)
message(STATUS "No graphics display enabled; building dedicated server")
SET(USE_CONSOLE ON CACHE INTERNAL "Build dedicated server")
endif()
############################################################################
# Check for compiler quirks and features
############################################################################
include(CheckCXXCompilerFlag)
if(CMAKE_COMPILER_IS_GNUCXX)
CHECK_CXX_COMPILER_FLAG("-std=gnu++0x" USE_GCC_STD_0X)
if(USE_GCC_STD_0X)
list(APPEND OC_CXX_FLAGS "-std=gnu++0x")
endif()
endif()
# ck 09-09-20: CMAKE_REQUIRED_FLAGS requires a string, not a list.
include(CheckCXXSourceCompiles)
foreach(FLAG ${OC_CXX_FLAGS})
set(OC_REQUIRED_FLAGS "${OC_REQUIRED_FLAGS} ${FLAG}")
endforeach()
set(CMAKE_REQUIRED_FLAGS ${OC_REQUIRED_FLAGS})
CHECK_CXX_SOURCE_COMPILES("void f(struct D&&); int main() { return 0; }" HAVE_RVALUE_REF)
if(MSVC_VERSION GREATER 1499)
# Activate minimal rebuild
list(APPEND OC_CXX_FLAGS_DEBUG /Gm)
if (NOT FIND_LIBRARY_USE_LIB64_PATHS)
# Activate edit-and-continue
list(REMOVE_ITEM OC_CXX_FLAGS_DEBUG /Zi)
list(APPEND OC_CXX_FLAGS_DEBUG /ZI /Gy)
endif()
endif()
if(MSVC_VERSION)
# Suppress warnings about "non-secure" functions
add_definitions(-D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS)
endif()
############################################################################
# Precompiled header support, part 1 (pre-target)
############################################################################
if(HAVE_PRECOMPILED_HEADERS)
endif()
############################################################################
# Generate output files
############################################################################
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h)
add_definitions(-DHAVE_CONFIG_H)
add_executable(clonk WIN32 MACOSX_BUNDLE
${OC_SYSTEM_SOURCES}
${OC_CLONK_SOURCES}
)
add_executable(c4group
src/c4group/c4group_ng.cpp
src/c4group/C4Group.cpp
src/lib/C4InputValidation.cpp
src/config/C4SecurityCertificates.cpp
src/c4group/C4Update.cpp
src/lib/Standard.cpp
src/c4group/CStdFile.cpp
src/lib/StdMarkup.cpp
src/lib/StdBuf.cpp
src/lib/StdCompiler.cpp
src/platform/StdFile.cpp
src/platform/StdRegistry.cpp
src/lib/StdResStr2.cpp
src/platform/StdConfig.cpp
src/zlib/gzio.c
)
target_link_libraries(clonk
${FREETYPE_LIBRARIES}
${ZLIB_LIBRARIES}
${PNG_LIBRARIES}
${JPEG_LIBRARIES}
${OPENSSL_LIBRARIES}
)
target_link_libraries(c4group
${ZLIB_LIBRARIES}
${OPENSSL_LIBRARIES}
)
set_property(TARGET clonk APPEND PROPERTY COMPILE_DEFINITIONS C4ENGINE GLEW_STATIC)
set_property(DIRECTORY APPEND PROPERTY COMPILE_DEFINITIONS_DEBUG _DEBUG)
############################################################################
# Precompiled header support, part 2 (post-target)
############################################################################
if(HAVE_PRECOMPILED_HEADERS)
endif()
############################################################################
# Assemble compiler flags
############################################################################
if(OC_CXX_FLAGS)
list(REMOVE_DUPLICATES OC_CXX_FLAGS)
endif()
set(CMAKE_CXX_FLAGS "" CACHE STRING "C++ compiler flags" FORCE)
foreach(FLAG ${OC_CXX_FLAGS})
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${FLAG}" CACHE STRING "C++ compiler flags" FORCE)
endforeach()
list(REMOVE_DUPLICATES OC_CXX_FLAGS_DEBUG)
set(CMAKE_CXX_FLAGS_DEBUG "" CACHE STRING "Flags used by the compiler during debug builds." FORCE)
foreach(FLAG ${OC_CXX_FLAGS_DEBUG})
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${FLAG}" CACHE STRING "Flags used by the compiler during debug builds." FORCE)
endforeach()
############################################################################
# Locate optional libraries (if so desired)
############################################################################
if(USE_GL)
include(FindOpenGL)
FINDLIB(GLEW_LIBRARIES NAMES GLEW glew32 glew32s)
@ -675,57 +764,3 @@ if(SDL_FOUND)
)
endif()
target_link_libraries(clonk
${FREETYPE_LIBRARIES}
${ZLIB_LIBRARIES}
${PNG_LIBRARIES}
${JPEG_LIBRARIES}
${OPENSSL_LIBRARIES}
)
target_link_libraries(c4group
${ZLIB_LIBRARIES}
${OPENSSL_LIBRARIES}
)
include(CheckCXXCompilerFlag)
if(CMAKE_COMPILER_IS_GNUCXX)
CHECK_CXX_COMPILER_FLAG("-std=gnu++0x" USE_GCC_STD_0X)
if(USE_GCC_STD_0X)
list(APPEND OC_CXX_FLAGS "-std=gnu++0x")
endif()
endif()
# ck 09-09-20: CMAKE_REQUIRED_FLAGS requires a string, not a list.
include(CheckCXXSourceCompiles)
foreach(FLAG ${OC_CXX_FLAGS})
set(OC_REQUIRED_FLAGS "${OC_REQUIRED_FLAGS} ${FLAG}")
endforeach()
set(CMAKE_REQUIRED_FLAGS ${OC_REQUIRED_FLAGS})
CHECK_CXX_SOURCE_COMPILES("void f(struct D&&); int main() { return 0; }" HAVE_RVALUE_REF)
if(MSVC_VERSION GREATER 1499)
# Activate minimal rebuild
list(APPEND OC_CXX_FLAGS_DEBUG /Gm)
if (NOT FIND_LIBRARY_USE_LIB64_PATHS)
# Activate edit-and-continue
list(REMOVE_ITEM OC_CXX_FLAGS_DEBUG /Zi)
list(APPEND OC_CXX_FLAGS_DEBUG /ZI /Gy)
endif()
endif()
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h)
add_definitions(-DHAVE_CONFIG_H)
add_definitions(-D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS)
if(OC_CXX_FLAGS)
list(REMOVE_DUPLICATES OC_CXX_FLAGS)
endif()
set(CMAKE_CXX_FLAGS "" CACHE STRING "C++ compiler flags" FORCE)
foreach(FLAG ${OC_CXX_FLAGS})
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${FLAG}" CACHE STRING "C++ compiler flags" FORCE)
endforeach()
list(REMOVE_DUPLICATES OC_CXX_FLAGS_DEBUG)
set(CMAKE_CXX_FLAGS_DEBUG "" CACHE STRING "Flags used by the compiler during debug builds." FORCE)
foreach(FLAG ${OC_CXX_FLAGS_DEBUG})
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${FLAG}" CACHE STRING "Flags used by the compiler during debug builds." FORCE)
endforeach()

View File

@ -182,3 +182,6 @@
/* Define to 1 if rvalue references are supported */
#cmakedefine HAVE_RVALUE_REF 1
/* Define to 1 if you have support for precompiled headers */
#cmakedefine HAVE_PRECOMPILED_HEADERS 1

View File

@ -1,2 +1,19 @@
/*
* OpenClonk, http://www.openclonk.org
*
* Copyright (C) 2009 The OpenClonk Project
*
* Portions might be copyrighted by other authors who have contributed
* to OpenClonk.
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
* See isc_license.txt for full license and disclaimer.
*
* "Clonk" is a registered trademark of Matthes Bender.
* See clonk_trademark_license.txt for full license.
*/
#include "C4Include.h"

View File

@ -44,16 +44,6 @@
#define C4_OS "unknown";
#endif
#ifndef HAVE_CONFIG_H
// different debugrec options
//#define DEBUGREC
// define directive STAT here to activate statistics
#undef STAT
#endif // HAVE_CONFIG_H
#ifdef DEBUGREC
#define DEBUGREC_SCRIPT
#define DEBUGREC_START_FRAME 0
@ -78,11 +68,195 @@
#include "../res/resource.h"
#endif // _WIN32
// Probably not working
#if defined(HAVE_MIDI_H) && !defined(USE_FMOD)
#define USE_WINDOWS_MIDI
#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
#define NOMINMAX
#include <windows.h>
#include <mmsystem.h>
#endif
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <time.h>
#include <map>
#include <vector>
#include <algorithm>
#include <assert.h>
#include <stdarg.h>
#ifdef HAVE_PRECOMPILED_HEADERS
#include "C4Application.h"
#include "C4FullScreen.h"
#include "C4Game.h"
#include "C4GraphicsSystem.h"
#include "C4Prototypes.h"
#include "C4Version.h"
#include "config/C4Config.h"
#include "config/C4ConfigShareware.h"
#include "config/C4Constants.h"
#include "config/C4SecurityCertificates.h"
#include "control/C4Control.h"
#include "control/C4GameControl.h"
#include "control/C4GameParameters.h"
#include "control/C4GameSave.h"
#include "control/C4PlayerInfo.h"
#include "control/C4Record.h"
#include "control/C4RoundResults.h"
#include "control/C4Teams.h"
#include "editor/C4Console.h"
#include "editor/C4DevmodeDlg.h"
#include "editor/C4EditCursor.h"
#include "editor/C4ObjectListDlg.h"
#include "editor/C4PropertyDlg.h"
#include "editor/C4ToolsDlg.h"
#include "game/C4GameVersion.h"
#include "game/C4Physics.h"
#include "game/landscape/C4Landscape.h"
#include "game/landscape/C4MapCreatorS2.h"
#include "game/landscape/C4Map.h"
#include "game/landscape/C4MassMover.h"
#include "game/landscape/C4Material.h"
#include "game/landscape/C4MaterialList.h"
#include "game/landscape/C4Particles.h"
#include "game/landscape/C4PathFinder.h"
#include "game/landscape/C4PXS.h"
#include "game/landscape/C4Region.h"
#include "game/landscape/C4Scenario.h"
#include "game/landscape/C4Sky.h"
#include "game/landscape/C4SolidMask.h"
#include "game/landscape/C4Texture.h"
#include "game/landscape/C4Weather.h"
#include "game/object/C4Command.h"
#include "game/object/C4DefGraphics.h"
#include "game/object/C4Def.h"
#include "game/object/C4GameObjects.h"
#include "game/object/C4Id.h"
#include "game/object/C4IDList.h"
#include "game/object/C4InfoCore.h"
#include "game/object/C4ObjectCom.h"
#include "game/object/C4Object.h"
#include "game/object/C4ObjectInfo.h"
#include "game/object/C4ObjectInfoList.h"
#include "game/object/C4ObjectList.h"
#include "game/object/C4ObjectMenu.h"
#include "game/object/C4Sector.h"
#include "game/object/C4Shape.h"
#include "game/player/C4Player.h"
#include "game/player/C4PlayerList.h"
#include "game/player/C4RankSystem.h"
#include "game/script/C4Effects.h"
#include "game/script/C4FindObject.h"
#include "game/script/C4Script.h"
#include "game/script/C4TransferZone.h"
#include "gui/C4ChatDlg.h"
#include "gui/C4DownloadDlg.h"
#include "gui/C4FileSelDlg.h"
#include "gui/C4Folder.h"
#include "gui/C4GameDialogs.h"
#include "gui/C4GameLobby.h"
#include "gui/C4GameMessage.h"
#include "gui/C4GameOptions.h"
#include "gui/C4GameOverDlg.h"
#include "gui/C4Gui.h"
#include "gui/C4KeyboardInput.h"
#include "gui/C4LoaderScreen.h"
#include "gui/C4MainMenu.h"
#include "gui/C4Menu.h"
#include "gui/C4MessageBoard.h"
#include "gui/C4MessageInput.h"
#include "gui/C4MouseControl.h"
#include "gui/C4PlayerInfoListBox.h"
#include "gui/C4Scoreboard.h"
#include "gui/C4StartupAboutDlg.h"
#include "gui/C4Startup.h"
#include "gui/C4StartupMainDlg.h"
#include "gui/C4StartupNetDlg.h"
#include "gui/C4StartupOptionsDlg.h"
#include "gui/C4StartupPlrSelDlg.h"
#include "gui/C4StartupScenSelDlg.h"
#include "gui/C4UpdateDlg.h"
#include "gui/C4UpperBoard.h"
#include "gui/C4UserMessages.h"
#include "gui/C4Viewport.h"
#include "lib/C4InputValidation.h"
#include "lib/C4LogBuf.h"
#include "lib/C4Log.h"
#include "lib/C4NameList.h"
#include "lib/C4Random.h"
#include "lib/C4Rect.h"
#include "lib/C4RTF.H"
#include "lib/C4Stat.h"
#include "lib/Fixed.h"
#include "lib/PathFinder.h"
#include "lib/Standard.h"
#include "lib/StdAdaptors.h"
#include "lib/StdBase64.h"
#include "lib/StdBuf.h"
#include "lib/StdColors.h"
#include "lib/StdCompiler.h"
#include "lib/StdMarkup.h"
#include "lib/StdResStr2.h"
#include "lib/StdResStr.h"
#include "lib/texture/C4FacetEx.h"
#include "lib/texture/C4Facet.h"
#include "lib/texture/C4GraphicsResource.h"
#include "lib/texture/C4SurfaceFile.h"
#include "lib/texture/C4Surface.h"
#include "lib/texture/StdPNG.h"
#include "network/C4Client.h"
#include "network/C4GameControlNetwork.h"
#include "network/C4InteractiveThread.h"
#include "network/C4League.h"
#include "network/C4NetIO.h"
#include "network/C4Network2Client.h"
#include "network/C4Network2Dialogs.h"
#include "network/C4Network2Discover.h"
#include "network/C4Network2.h"
#include "network/C4Network2IO.h"
#include "network/C4Network2IRC.h"
#include "network/C4Network2Players.h"
#include "network/C4Network2Reference.h"
#include "network/C4Network2Res.h"
#include "network/C4Network2Stats.h"
#include "network/C4PacketBase.h"
#include "platform/Bitmap256.h"
#include "platform/C4FileClasses.h"
#include "platform/C4FileMonitor.h"
#include "platform/C4Fonts.h"
#include "platform/C4GamePadCon.h"
#include "platform/C4MusicFile.h"
#include "platform/C4MusicSystem.h"
#include "platform/C4SoundSystem.h"
#include "platform/C4Video.h"
#include "platform/C4VideoPlayback.h"
#include "platform/Midi.h"
#include "platform/StdConfig.h"
#include "platform/StdD3D.h"
#include "platform/StdD3DShader.h"
#include "platform/StdDDraw2.h"
#include "platform/StdFacet.h"
#include "platform/StdFile.h"
#include "platform/StdFont.h"
#include "platform/StdGL.h"
#include "platform/StdNoGfx.h"
#include "platform/StdRegistry.h"
#include "platform/StdScheduler.h"
#include "platform/StdSurface2.h"
#include "platform/StdSurface8.h"
#include "platform/StdSync.h"
#include "platform/StdVideo.h"
#include "platform/StdWindow.h"
#include "script/C4AList.h"
#include "script/C4Aul.h"
#include "script/C4PropList.h"
#include "script/C4ScriptHost.h"
#include "script/C4StringTable.h"
#include "script/C4Value.h"
#include "script/C4ValueList.h"
#include "script/C4ValueMap.h"
#include "zlib/zutil.h"
#else // HAVE_PRECOMPILED_HEADERS
// Only include some standard headers
#include <Standard.h>
#include <CStdFile.h>
#include <Fixed.h>
@ -101,152 +275,6 @@
#include "C4Id.h"
#include "C4Prototypes.h"
#ifdef _WIN32
#include <mmsystem.h>
#endif
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
#include <time.h>
#include <map>
#include <vector>
#include <algorithm>
#include <assert.h>
#include <stdarg.h>
//#define BIG_C4INCLUDE
#if defined(BIG_C4INCLUDE) && defined(C4ENGINE)
#include "C4AList.h"
#include "C4Application.h"
#include "C4Aul.h"
#include "C4ChatDlg.h"
#include "C4Client.h"
#include "C4Command.h"
#include "C4ComponentHost.h"
#include "C4Components.h"
#include "C4Config.h"
#include "C4Console.h"
#include "C4Control.h"
#include "C4DefGraphics.h"
#include "C4Def.h"
#include "C4DevmodeDlg.h"
#include "C4EditCursor.h"
#include "C4Effects.h"
#include "C4Extra.h"
#include "C4FacetEx.h"
#include "C4Facet.h"
#include "C4FileClasses.h"
#include "C4FileSelDlg.h"
#include "C4FindObject.h"
#include "C4Fonts.h"
#include "C4FullScreen.h"
#include "C4GameControl.h"
#include "C4GameControlNetwork.h"
#include "C4GameDialogs.h"
#include "C4Game.h"
#include "C4GameLobby.h"
#include "C4GameMessage.h"
#include "C4GameObjects.h"
#include "C4GameOptions.h"
#include "C4GameOverDlg.h"
#include "C4GamePadCon.h"
#include "C4GameSave.h"
#include "C4GraphicsResource.h"
#include "C4GraphicsSystem.h"
#include "C4Group.h"
#include "C4GroupSet.h"
#include "C4Gui.h"
#include "C4IDList.h"
#include "C4InfoCore.h"
#include "C4InputValidation.h"
#include "C4KeyboardInput.h"
#include "C4Landscape.h"
#include "C4LangStringTable.h"
#include "C4Language.h"
#ifndef NONETWORK
# include "C4League.h"
#endif
#include "C4LoaderScreen.h"
#include "C4LogBuf.h"
#include "C4Log.h"
#include "C4MapCreatorS2.h"
#include "C4Map.h"
#include "C4MassMover.h"
#include "C4Material.h"
#include "C4MaterialList.h"
#include "C4Menu.h"
#include "C4MessageBoard.h"
#include "C4MessageInput.h"
#include "C4MouseControl.h"
#include "C4MusicFile.h"
#include "C4MusicSystem.h"
#include "C4NameList.h"
#include "C4NetIO.h"
#include "C4Network2Client.h"
#include "C4Network2Dialogs.h"
#include "C4Network2Discover.h"
#include "C4Network2.h"
#include "C4Network2IO.h"
#include "C4Network2Players.h"
#include "C4Network2Res.h"
#include "C4Network2Stats.h"
#include "C4ObjectCom.h"
#include "C4Object.h"
#include "C4ObjectInfo.h"
#include "C4ObjectInfoList.h"
#include "C4ObjectList.h"
#include "C4ObjectMenu.h"
#include "C4PacketBase.h"
#include "C4Particles.h"
#include "C4PathFinder.h"
#include "C4Physics.h"
#include "C4Player.h"
#include "C4PlayerInfo.h"
#include "C4PlayerInfoListBox.h"
#include "C4PlayerList.h"
#include "C4PropertyDlg.h"
#include "C4PXS.h"
#include "C4Random.h"
#include "C4RankSystem.h"
#include "C4Record.h"
#include "C4Region.h"
#include "C4RoundResults.h"
#include "C4RTF.H"
#include "C4Scenario.h"
#include "C4Scoreboard.h"
#include "C4Script.h"
#include "C4ScriptHost.h"
#include "C4Sector.h"
#include "C4Shape.h"
#include "C4Sky.h"
#include "C4SolidMask.h"
#include "C4SoundSystem.h"
#include "C4Startup.h"
#include "C4StartupMainDlg.h"
#include "C4StartupNetDlg.h"
#include "C4StartupOptionsDlg.h"
#include "C4StartupAboutDlg.h"
#include "C4StartupPlrSelDlg.h"
#include "C4StartupScenSelDlg.h"
#include "C4Stat.h"
#include "C4StringTable.h"
#include "C4SurfaceFile.h"
#include "C4Surface.h"
#include "C4Teams.h"
#include "C4Texture.h"
#include "C4ToolsDlg.h"
#include "C4TransferZone.h"
#include "C4Update.h"
#include "C4UpperBoard.h"
#include "C4UserMessages.h"
#include "C4Value.h"
#include "C4ValueList.h"
#include "C4ValueMap.h"
#include "C4Video.h"
#include "C4Viewport.h"
#include "C4Weather.h"
#endif
#endif // HAVE_PRECOMPILED_HEADERS
#endif // INC_C4Include

View File

@ -21,6 +21,7 @@
/* A handy wrapper class to gzio files */
#include "C4Include.h"
#include <Standard.h>
#include <StdFile.h>
#include <CStdFile.h>

View File

@ -18,6 +18,8 @@
/* Certificate used to verify registration keys. */
#include "C4Include.h"
const char* Cert_Reg_XOR_Base64 =
"R0deRkkuNHZ/fEgwLjxnfjUicitmdx9eR0deYSklOHJcWCswKghQdDI6ZB12Y2s5IQUpIgwaEn93\n"
"Yy02KT9yQBQyWhJxSHM5KA09PSYtKGV3WTo1Jj8LQDc6aC44ZGMiIy8EMScPHGdCaD9HEypJdj0p\n"

View File

@ -47,6 +47,7 @@
class C4GroupSet;
class C4GamePadOpener;
class C4Viewport;
class C4Def;
// consts (load those from a def file some time)
// font colors - alpha is font alpha, which is inversed opaque
@ -1939,7 +1940,7 @@ namespace C4GUI {
private:
int iRefCount;
bool SetFacetByAction(class C4Def *pOfDef, class C4TargetFacet &rfctTarget, const char *szFacetName);
bool SetFacetByAction(C4Def *pOfDef, class C4TargetFacet &rfctTarget, const char *szFacetName);
public:
C4ID idSourceDef;

View File

@ -25,7 +25,6 @@
#include <C4Include.h>
#include <C4Gui.h>
#ifndef BIG_C4INCLUDE
#include <C4FullScreen.h>
#include <C4LoaderScreen.h>
#include <C4Application.h>
@ -35,7 +34,6 @@
#include <C4MouseControl.h>
#include <C4GraphicsResource.h>
#include <C4Game.h>
#endif
#include <StdGL.h>
#include <StdRegistry.h>

View File

@ -28,6 +28,7 @@
#include "C4Shape.h"
#include "C4Gui.h"
#include "C4IDList.h"
#include "C4Region.h"
class C4Viewport;

View File

@ -18,6 +18,7 @@
*/
// user input validation functions
#include "C4Include.h"
#include <Standard.h>
#include <C4InputValidation.h>
#include <C4Log.h>

View File

@ -17,6 +17,7 @@
*/
// a buffer holding a log history
#include "C4Include.h"
#include "Standard.h"
#include "C4LogBuf.h"

View File

@ -20,6 +20,7 @@
/* A static list of strings and integer values, i.e. for material amounts */
#include "C4Include.h"
#include <Standard.h>
#include <C4NameList.h>

View File

@ -19,6 +19,7 @@
*/
// RTF file parsing functionality
#include "C4Include.h"
#include "Standard.h"
#include "C4RTF.H"

View File

@ -18,6 +18,7 @@
/* Buffered fast and network-safe random */
#include "C4Include.h"
#include <Standard.h>
#include "C4Prototypes.h"
#include <C4Random.h>

View File

@ -21,6 +21,7 @@
/* Basic classes for rectangles and vertex outlines */
#include "C4Include.h"
#include "Standard.h"
#include "C4Rect.h"
#include "C4FacetEx.h"

View File

@ -18,6 +18,7 @@
*/
// statistics
#include "C4Include.h"
#include <Standard.h>
#include <C4Stat.h>

View File

@ -17,6 +17,7 @@
*/
// fixed numbers - sine functions
#include "C4Include.h"
#include <Standard.h>
#include <Fixed.h>

View File

@ -18,6 +18,7 @@
/* Finds the shortest free path through any pixel environment */
#include "C4Include.h"
#include <Standard.h>
#include <PathFinder.h>

View File

@ -21,6 +21,9 @@
/* I am rather proud of this class. If you are going to use it,
please give me the credits. */
#ifndef INC_PathFinder
#define INC_PathFinder
class CPathFinder;
class CPathFinderRay
@ -84,5 +87,4 @@ class CPathFinder
void Run();
};
#endif

View File

@ -21,6 +21,7 @@
/* All kinds of valuable helpers */
#include "C4Include.h"
#include <Standard.h>
#if defined(HAVE_PTHREAD) && defined(C4ENGINE)
// c4group is single-threaded

View File

@ -17,6 +17,7 @@
*/
/* Base64 encoding / decoding */
#include "C4Include.h"
#include "Standard.h"
#include "StdBase64.h"

View File

@ -17,6 +17,7 @@
* "Clonk" is a registered trademark of Matthes Bender.
* See clonk_trademark_license.txt for full license.
*/
#include "C4Include.h"
#include <Standard.h>
#include <StdBuf.h>
#include <StdCompiler.h>

View File

@ -18,6 +18,7 @@
* "Clonk" is a registered trademark of Matthes Bender.
* See clonk_trademark_license.txt for full license.
*/
#include "C4Include.h"
#include "StdCompiler.h"
#include <stdio.h>

View File

@ -17,6 +17,7 @@
*/
// markup tags for fonts
#include "C4Include.h"
#include <StdMarkup.h>
#include <StdDDraw2.h>

View File

@ -19,6 +19,7 @@
/* Load strings from a primitive memory string table */
#include "C4Include.h"
#include <Standard.h>
#include <StdResStr2.h>
#include <StdBuf.h>

View File

@ -18,6 +18,7 @@
*/
// png file reading functionality
#include "C4Include.h"
#include <StdPNG.h>
CPNGFile *pCurrPng=NULL; // global crap for file-reading callback

View File

@ -19,6 +19,7 @@
/* A structure for handling 256-color bitmap files */
#include "C4Include.h"
#include <Standard.h>
#include <Bitmap256.h>

View File

@ -18,6 +18,7 @@
/* Play midis using mci */
#include "C4Include.h"
#include <Standard.h>
#ifdef HAVE_MIDI_H

View File

@ -15,6 +15,7 @@
* "Clonk" is a registered trademark of Matthes Bender.
* See clonk_trademark_license.txt for full license.
*/
#include "C4Include.h"
#include <Standard.h>
#ifdef WITH_GLIB

View File

@ -18,6 +18,7 @@
/* Auto-registering data structures */
#include "C4Include.h"
#include <Standard.h>
#include <StdRegistry.h>
#include <StdConfig.h>

View File

@ -22,6 +22,7 @@
/* Direct3D implementation of NewGfx */
#include "C4Include.h"
#include <Standard.h>
#include <StdD3D.h>

View File

@ -16,6 +16,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
/* Direct3D shader used for FoW-modulated blitting */
#include "C4Include.h"
#include <Standard.h>
#ifdef USE_DIRECTX

View File

@ -20,6 +20,7 @@
*/
/* NewGfx interfaces */
#include "C4Include.h"
#include <Standard.h>
#include <StdFacet.h>
#include <StdDDraw2.h>

View File

@ -22,6 +22,7 @@
/* Lots of file helpers */
#include "C4Include.h"
#include <Standard.h>
#include <StdFile.h>
#include <StdBuf.h>

View File

@ -21,6 +21,7 @@
// text drawing facility for CStdDDraw
#include "C4Include.h"
#include <Standard.h>
#include <StdBuf.h>
#include <StdDDraw2.h>

View File

@ -22,6 +22,7 @@
/* OpenGL implementation of NewGfx */
#include "C4Include.h"
#include <Standard.h>
#include <StdGL.h>
#include <StdSurface2.h>

View File

@ -20,6 +20,7 @@
/* OpenGL implementation of NewGfx, the context */
#include "C4Include.h"
#include <Standard.h>
#include <StdGL.h>
#include <StdSurface2.h>

View File

@ -20,6 +20,7 @@
/* Simple joystick handling with DirectInput 1 */
#include "C4Include.h"
#include <Standard.h>
#include <StdJoystick.h>

View File

@ -19,6 +19,10 @@
/* Simple joystick handling with DirectInput 1 */
#ifndef INC_StdJoystick
#define INC_StdJoystick
#include "C4Include.h"
#include <Standard.h>
#include <windows.h>
#include <mmsystem.h>
@ -52,3 +56,5 @@ class CStdGamePad
uint32_t GetButtons(); // returns bitmask of pressed buttons for last retrieved info
AxisPos GetAxisPos(int idAxis); // return axis extension - mid for error or center position
};
#endif

View File

@ -16,6 +16,7 @@
* "Clonk" is a registered trademark of Matthes Bender.
* See clonk_trademark_license.txt for full license.
*/
#include "C4Include.h"
#include <Standard.h>
#include <StdNoGfx.h>

View File

@ -20,6 +20,7 @@
/* Some wrappers for easier access to the Windows registry */
#include "C4Include.h"
#include <Standard.h>
#include <StdRegistry.h>

View File

@ -18,6 +18,7 @@
* "Clonk" is a registered trademark of Matthes Bender.
* See clonk_trademark_license.txt for full license.
*/
#include "C4Include.h"
#include "StdScheduler.h"
#include <stdio.h>

View File

@ -21,6 +21,7 @@
*/
// a wrapper class to DirectDraw surfaces
#include "C4Include.h"
#include <Standard.h>
#include <StdFile.h>
#include <CStdFile.h>

View File

@ -18,6 +18,7 @@
*/
// a wrapper class to DirectDraw surfaces
#include "C4Include.h"
#include <Standard.h>
#include <StdSurface8.h>
#include <Bitmap256.h>

View File

@ -20,6 +20,7 @@
/* Some functions to help with saving AVI files using Video for Windows */
#include "C4Include.h"
#ifdef _WIN32
#include <Standard.h>

View File

@ -21,6 +21,7 @@
/* A wrapper class to OS dependent event and window interfaces, WIN32 version */
#include "C4Include.h"
#include <Standard.h>
#include <StdRegistry.h>
#ifdef USE_GL
@ -241,7 +242,7 @@ CStdApp::~CStdApp()
{
}
char *LoadResStr(const char *id);
const char *LoadResStr(const char *id);
bool CStdApp::Init(HINSTANCE hInst, int nCmdShow, char *szCmdLine) {
// Set instance vars