From 9f031a67594162a53b07acbfbc65faf8c4938e99 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 17 Jun 2012 04:00:31 +0300 Subject: [PATCH] Optimize headers --- src/activeobject.h | 2 +- src/ban.h | 1 - src/camera.h | 2 +- src/chat.h | 2 +- src/client.h | 2 +- src/clientmap.h | 2 +- src/clientobject.h | 2 +- src/clientsimpleobject.h | 2 +- src/clouds.h | 2 +- src/collision.h | 2 +- src/connection.h | 2 +- src/content_cso.h | 2 +- src/content_mapnode.cpp | 2 +- src/debug.cpp | 1 + src/debug.h | 1 + src/environment.h | 2 +- src/farmesh.h | 2 +- src/game.cpp | 2 +- src/game.h | 2 +- src/genericobject.h | 2 +- src/gettime.h | 2 +- src/guiChatConsole.h | 2 +- src/guiConfirmMenu.h | 2 +- src/guiCreateWorld.h | 2 +- src/guiDeathScreen.h | 2 +- src/guiInventoryMenu.h | 2 +- src/guiKeyChangeMenu.h | 2 +- src/guiMainMenu.h | 2 +- src/guiMessageMenu.h | 2 +- src/guiPasswordChange.h | 2 +- src/guiPauseMenu.h | 2 +- src/guiTextInputMenu.h | 2 +- src/inventory.h | 2 +- src/irr_aabb3d.h | 30 ++++++++++++++++ src/irr_v2d.h | 34 ++++++++++++++++++ src/irr_v3d.h | 32 +++++++++++++++++ src/irrlichttypes.h | 21 ++--------- src/irrlichttypes_bloated.h | 35 +++++++++++++++++++ ...rrlicht.h => irrlichttypes_extrabloated.h} | 6 ++-- src/itemdef.h | 2 +- src/itemgroup.h | 2 +- src/keycode.h | 3 +- src/light.h | 2 +- src/main.cpp | 2 +- src/map.h | 2 +- src/mapblock.h | 4 ++- src/mapblock_mesh.h | 2 +- src/mapgen.h | 2 +- src/mapnode.cpp | 2 +- src/mapnode.h | 1 + src/mapsector.h | 6 +--- src/mesh.h | 2 +- src/modalMenu.h | 2 +- src/mods.h | 1 + src/nameidmapping.h | 2 +- src/nodedef.h | 2 +- src/nodemetadata.h | 2 +- src/nodetimer.h | 2 +- src/object_properties.h | 2 +- src/player.h | 2 +- src/porting.h | 3 +- src/profiler.h | 2 +- src/quicktune.h | 1 - src/scriptapi.h | 2 +- src/serialization.h | 2 +- src/server.h | 2 +- src/servercommand.h | 2 +- src/serverobject.h | 2 +- src/settings.h | 2 +- src/sky.h | 2 +- src/sound.h | 2 +- src/staticobject.h | 2 +- src/test.cpp | 2 +- src/tile.h | 6 +++- src/tool.h | 2 +- src/util/directiontables.h | 1 + src/util/numeric.h | 4 +++ src/util/pointedthing.h | 1 + src/util/pointer.h | 1 + src/util/serialize.h | 2 ++ src/voxel.h | 2 ++ 81 files changed, 221 insertions(+), 92 deletions(-) create mode 100644 src/irr_aabb3d.h create mode 100644 src/irr_v2d.h create mode 100644 src/irr_v3d.h create mode 100644 src/irrlichttypes_bloated.h rename src/{common_irrlicht.h => irrlichttypes_extrabloated.h} (90%) diff --git a/src/activeobject.h b/src/activeobject.h index 6c8203490..1108a19de 100644 --- a/src/activeobject.h +++ b/src/activeobject.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef ACTIVEOBJECT_HEADER #define ACTIVEOBJECT_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #define ACTIVEOBJECT_TYPE_INVALID 0 diff --git a/src/ban.h b/src/ban.h index 5a8532f14..f5b9c4440 100644 --- a/src/ban.h +++ b/src/ban.h @@ -24,7 +24,6 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include #include -#include "common_irrlicht.h" #include "exceptions.h" class BanManager diff --git a/src/camera.h b/src/camera.h index 763c4fd8c..642b8d2d0 100644 --- a/src/camera.h +++ b/src/camera.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CAMERA_HEADER #define CAMERA_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "inventory.h" #include "mesh.h" #include "tile.h" diff --git a/src/chat.h b/src/chat.h index 3a376aad2..49de52985 100644 --- a/src/chat.h +++ b/src/chat.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CHAT_HEADER #define CHAT_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_bloated.h" #include // Chat console related classes, only used by the client diff --git a/src/client.h b/src/client.h index 6b797e627..18a0009a8 100644 --- a/src/client.h +++ b/src/client.h @@ -22,7 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "connection.h" #include "environment.h" -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "jmutex.h" #include #include diff --git a/src/clientmap.h b/src/clientmap.h index 30d79cf88..29ebed159 100644 --- a/src/clientmap.h +++ b/src/clientmap.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CLIENTMAP_HEADER #define CLIENTMAP_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "map.h" struct MapDrawControl diff --git a/src/clientobject.h b/src/clientobject.h index 0d3ee3d30..8b0b57147 100644 --- a/src/clientobject.h +++ b/src/clientobject.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CLIENTOBJECT_HEADER #define CLIENTOBJECT_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "activeobject.h" /* diff --git a/src/clientsimpleobject.h b/src/clientsimpleobject.h index 21e42b4cb..9dd8cc472 100644 --- a/src/clientsimpleobject.h +++ b/src/clientsimpleobject.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CLIENTSIMPLEOBJECT_HEADER #define CLIENTSIMPLEOBJECT_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" class ClientEnvironment; class ClientSimpleObject diff --git a/src/clouds.h b/src/clouds.h index d377fcd7b..a7cde42bc 100644 --- a/src/clouds.h +++ b/src/clouds.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CLOUDS_HEADER #define CLOUDS_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include class Clouds : public scene::ISceneNode diff --git a/src/collision.h b/src/collision.h index 2cb55eb67..a4eca0dd8 100644 --- a/src/collision.h +++ b/src/collision.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef COLLISION_HEADER #define COLLISION_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_bloated.h" class Map; class IGameDef; diff --git a/src/connection.h b/src/connection.h index e03c7983f..f88e813a3 100644 --- a/src/connection.h +++ b/src/connection.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CONNECTION_HEADER #define CONNECTION_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include "socket.h" #include "exceptions.h" #include "constants.h" diff --git a/src/content_cso.h b/src/content_cso.h index 1a373731a..0b467f6c4 100644 --- a/src/content_cso.h +++ b/src/content_cso.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef CONTENT_CSO_HEADER #define CONTENT_CSO_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "clientsimpleobject.h" ClientSimpleObject* createSmokePuff(scene::ISceneManager *smgr, diff --git a/src/content_mapnode.cpp b/src/content_mapnode.cpp index 6604b36a2..410aaa911 100644 --- a/src/content_mapnode.cpp +++ b/src/content_mapnode.cpp @@ -19,7 +19,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "content_mapnode.h" -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include "mapnode.h" #include "nodedef.h" #include "nameidmapping.h" diff --git a/src/debug.cpp b/src/debug.cpp index d0d2e047b..8b25cc22d 100644 --- a/src/debug.cpp +++ b/src/debug.cpp @@ -21,6 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "debug.h" #include #include +#include /* Debug output diff --git a/src/debug.h b/src/debug.h index 7a3c60144..3e8066f4d 100644 --- a/src/debug.h +++ b/src/debug.h @@ -25,6 +25,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include #include "irrlichttypes.h" +#include #include "threads.h" #include "gettime.h" #include "exceptions.h" diff --git a/src/environment.h b/src/environment.h index 710b62ee0..0e4b85e06 100644 --- a/src/environment.h +++ b/src/environment.h @@ -31,7 +31,7 @@ with this program; if not, write to the Free Software Foundation, Inc., */ #include -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "player.h" #include "map.h" #include diff --git a/src/farmesh.h b/src/farmesh.h index b3a8dde20..2eaf7d486 100644 --- a/src/farmesh.h +++ b/src/farmesh.h @@ -25,7 +25,7 @@ with this program; if not, write to the Free Software Foundation, Inc., distance according to map seed */ -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #define FARMESH_MATERIAL_COUNT 2 diff --git a/src/game.cpp b/src/game.cpp index 83e853b93..c8defd82d 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -18,7 +18,7 @@ with this program; if not, write to the Free Software Foundation, Inc., */ #include "game.h" -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include #include #include diff --git a/src/game.h b/src/game.h index 3c127539a..b74a7a8da 100644 --- a/src/game.h +++ b/src/game.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GAME_HEADER #define GAME_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include #include "keycode.h" diff --git a/src/genericobject.h b/src/genericobject.h index b3dd002c8..81563c19b 100644 --- a/src/genericobject.h +++ b/src/genericobject.h @@ -21,7 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #define GENERICOBJECT_HEADER #include -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #define GENERIC_CMD_SET_PROPERTIES 0 diff --git a/src/gettime.h b/src/gettime.h index 23376be3f..b5cb830cc 100644 --- a/src/gettime.h +++ b/src/gettime.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GETTIME_HEADER #define GETTIME_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes.h" /* Get a millisecond counter value. diff --git a/src/guiChatConsole.h b/src/guiChatConsole.h index 9e76a116e..033a26244 100644 --- a/src/guiChatConsole.h +++ b/src/guiChatConsole.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUICHATCONSOLE_HEADER #define GUICHATCONSOLE_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "chat.h" class Client; diff --git a/src/guiConfirmMenu.h b/src/guiConfirmMenu.h index 0007290b1..b9fb2cd53 100644 --- a/src/guiConfirmMenu.h +++ b/src/guiConfirmMenu.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUICONFIRMMENU_HEADER #define GUICONFIRMMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include diff --git a/src/guiCreateWorld.h b/src/guiCreateWorld.h index 6de8cdd4e..492fcf565 100644 --- a/src/guiCreateWorld.h +++ b/src/guiCreateWorld.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUICREATEWORLD_HEADER #define GUICREATEWORLD_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include #include "subgame.h" diff --git a/src/guiDeathScreen.h b/src/guiDeathScreen.h index 36adab617..3c0307634 100644 --- a/src/guiDeathScreen.h +++ b/src/guiDeathScreen.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUIMESSAGEMENU_HEADER #define GUIMESSAGEMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include diff --git a/src/guiInventoryMenu.h b/src/guiInventoryMenu.h index c49a34582..5613db356 100644 --- a/src/guiInventoryMenu.h +++ b/src/guiInventoryMenu.h @@ -21,7 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUIINVENTORYMENU_HEADER #define GUIINVENTORYMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "inventory.h" #include "inventorymanager.h" #include "modalMenu.h" diff --git a/src/guiKeyChangeMenu.h b/src/guiKeyChangeMenu.h index 442c0882a..7c71b297d 100644 --- a/src/guiKeyChangeMenu.h +++ b/src/guiKeyChangeMenu.h @@ -22,7 +22,7 @@ #ifndef GUIKEYCHANGEMENU_HEADER #define GUIKEYCHANGEMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include "client.h" #include "gettext.h" diff --git a/src/guiMainMenu.h b/src/guiMainMenu.h index f6452f834..fa3d83c45 100644 --- a/src/guiMainMenu.h +++ b/src/guiMainMenu.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUIMAINMENU_HEADER #define GUIMAINMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include #include diff --git a/src/guiMessageMenu.h b/src/guiMessageMenu.h index 1be69c3b7..af2fc44a5 100644 --- a/src/guiMessageMenu.h +++ b/src/guiMessageMenu.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUIMESSAGEMENU_HEADER #define GUIMESSAGEMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include diff --git a/src/guiPasswordChange.h b/src/guiPasswordChange.h index 3104840c5..f5f767b5e 100644 --- a/src/guiPasswordChange.h +++ b/src/guiPasswordChange.h @@ -19,7 +19,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. #ifndef GUIPASSWORDCHANGE_HEADER #define GUIPASSWORDCHANGE_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include "client.h" #include diff --git a/src/guiPauseMenu.h b/src/guiPauseMenu.h index 389d042f0..e28159a93 100644 --- a/src/guiPauseMenu.h +++ b/src/guiPauseMenu.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUIPAUSEMENU_HEADER #define GUIPAUSEMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" class IGameCallback diff --git a/src/guiTextInputMenu.h b/src/guiTextInputMenu.h index 2e2aff0f6..76417894b 100644 --- a/src/guiTextInputMenu.h +++ b/src/guiTextInputMenu.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef GUITEXTINPUTMENU_HEADER #define GUITEXTINPUTMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "modalMenu.h" #include diff --git a/src/inventory.h b/src/inventory.h index 48ee20e83..a3c598256 100644 --- a/src/inventory.h +++ b/src/inventory.h @@ -24,7 +24,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include #include -#include "common_irrlicht.h" +#include "irrlichttypes_bloated.h" #include "debug.h" #include "itemdef.h" diff --git a/src/irr_aabb3d.h b/src/irr_aabb3d.h new file mode 100644 index 000000000..3f04198ad --- /dev/null +++ b/src/irr_aabb3d.h @@ -0,0 +1,30 @@ +/* +Minetest-c55 +Copyright (C) 2010-2012 celeron55, Perttu Ahola + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation; either version 2.1 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 Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License along +with this program; if not, write to the Free Software Foundation, Inc., +51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +*/ + +#ifndef IRR_AABB3D_HEADER +#define IRR_AABB3D_HEADER + +#include "irrlichttypes.h" + +#include + +typedef core::aabbox3d aabb3f; + +#endif + diff --git a/src/irr_v2d.h b/src/irr_v2d.h new file mode 100644 index 000000000..0710684ce --- /dev/null +++ b/src/irr_v2d.h @@ -0,0 +1,34 @@ +/* +Minetest-c55 +Copyright (C) 2010-2012 celeron55, Perttu Ahola + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation; either version 2.1 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 Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License along +with this program; if not, write to the Free Software Foundation, Inc., +51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +*/ + +#ifndef IRR_V2D_HEADER +#define IRR_V2D_HEADER + +#include "irrlichttypes.h" + +#include + +typedef core::vector2d v2f; +typedef core::vector2d v2s16; +typedef core::vector2d v2s32; +typedef core::vector2d v2u32; +typedef core::vector2d v2f32; + +#endif + diff --git a/src/irr_v3d.h b/src/irr_v3d.h new file mode 100644 index 000000000..21051f93c --- /dev/null +++ b/src/irr_v3d.h @@ -0,0 +1,32 @@ +/* +Minetest-c55 +Copyright (C) 2010-2012 celeron55, Perttu Ahola + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation; either version 2.1 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 Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License along +with this program; if not, write to the Free Software Foundation, Inc., +51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +*/ + +#ifndef IRR_V3D_HEADER +#define IRR_V3D_HEADER + +#include "irrlichttypes.h" + +#include + +typedef core::vector3df v3f; +typedef core::vector3d v3s16; +typedef core::vector3d v3s32; + +#endif + diff --git a/src/irrlichttypes.h b/src/irrlichttypes.h index 8f3eb1464..82177299e 100644 --- a/src/irrlichttypes.h +++ b/src/irrlichttypes.h @@ -1,6 +1,6 @@ /* Minetest-c55 -Copyright (C) 2010-2011 celeron55, Perttu Ahola +Copyright (C) 2010-2012 celeron55, Perttu Ahola This program is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by @@ -21,25 +21,8 @@ with this program; if not, write to the Free Software Foundation, Inc., #define IRRLICHTTYPES_HEADER #include -#include -#include -#include -#include -#include -#include -#include -using namespace irr; -typedef core::vector3df v3f; -typedef core::vector3d v3s16; -typedef core::vector3d v3s32; - -typedef core::vector2d v2f; -typedef core::vector2d v2s16; -typedef core::vector2d v2s32; -typedef core::vector2d v2u32; -typedef core::vector2d v2f32; -typedef core::aabbox3d aabb3f; +using namespace irr; #ifdef _MSC_VER // Windows diff --git a/src/irrlichttypes_bloated.h b/src/irrlichttypes_bloated.h new file mode 100644 index 000000000..528ee1f47 --- /dev/null +++ b/src/irrlichttypes_bloated.h @@ -0,0 +1,35 @@ +/* +Minetest-c55 +Copyright (C) 2010-2012 celeron55, Perttu Ahola + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU Lesser General Public License as published by +the Free Software Foundation; either version 2.1 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 Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public License along +with this program; if not, write to the Free Software Foundation, Inc., +51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +*/ + +#ifndef IRRLICHTTYPES_BLOATED_HEADER +#define IRRLICHTTYPES_BLOATED_HEADER + +#include "irrlichttypes.h" + +#include "irr_v2d.h" +#include "irr_v3d.h" +#include "irr_aabb3d.h" + +#include +#include +#include +#include + +#endif + diff --git a/src/common_irrlicht.h b/src/irrlichttypes_extrabloated.h similarity index 90% rename from src/common_irrlicht.h rename to src/irrlichttypes_extrabloated.h index 0f9338c89..f85fb6318 100644 --- a/src/common_irrlicht.h +++ b/src/irrlichttypes_extrabloated.h @@ -17,13 +17,13 @@ with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#ifndef COMMON_IRRLICHT_HEADER -#define COMMON_IRRLICHT_HEADER +#ifndef IRRLICHTTYPES_EXTRABLOATED_HEADER +#define IRRLICHTTYPES_EXTRABLOATED_HEADER #define endSceneX(d){d->draw2DLine(v2s32(0,0),v2s32(1,0),\ video::SColor(255,30,30,30));d->endScene();} -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #ifndef SERVER #include diff --git a/src/itemdef.h b/src/itemdef.h index ac3a5ab87..d1ac52bb8 100644 --- a/src/itemdef.h +++ b/src/itemdef.h @@ -21,7 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef ITEMDEF_HEADER #define ITEMDEF_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include #include #include diff --git a/src/itemgroup.h b/src/itemgroup.h index bec03a3c9..c6c36dcc4 100644 --- a/src/itemgroup.h +++ b/src/itemgroup.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef ITEMGROUP_HEADER #define ITEMGROUP_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include #include diff --git a/src/keycode.h b/src/keycode.h index cb3a7fbc0..4105d43b8 100644 --- a/src/keycode.h +++ b/src/keycode.h @@ -20,7 +20,8 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef KEYCODE_HEADER #define KEYCODE_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes.h" +#include #include /* A key press, consisting of either an Irrlicht keycode diff --git a/src/light.h b/src/light.h index 8c397e1d4..218af348e 100644 --- a/src/light.h +++ b/src/light.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef LIGHT_HEADER #define LIGHT_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes.h" #include "debug.h" /* diff --git a/src/main.cpp b/src/main.cpp index 3352b866c..092a7b03f 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -47,7 +47,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include #include -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "debug.h" #include "test.h" #include "server.h" diff --git a/src/map.h b/src/map.h index f51d57569..b25c26957 100644 --- a/src/map.h +++ b/src/map.h @@ -26,7 +26,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include "mapnode.h" #include "constants.h" #include "voxel.h" diff --git a/src/mapblock.h b/src/mapblock.h index 81e950255..08fd2c754 100644 --- a/src/mapblock.h +++ b/src/mapblock.h @@ -24,7 +24,9 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include #include "debug.h" -#include "common_irrlicht.h" +#include "irrlichttypes.h" +#include "irr_v3d.h" +#include "irr_aabb3d.h" #include "mapnode.h" #include "exceptions.h" #include "serialization.h" diff --git a/src/mapblock_mesh.h b/src/mapblock_mesh.h index d5733120b..82268efd2 100644 --- a/src/mapblock_mesh.h +++ b/src/mapblock_mesh.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef MAPBLOCK_MESH_HEADER #define MAPBLOCK_MESH_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "tile.h" #include "voxel.h" #include diff --git a/src/mapgen.h b/src/mapgen.h index 1d4ef136d..e2f20ecaf 100644 --- a/src/mapgen.h +++ b/src/mapgen.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef MAPGEN_HEADER #define MAPGEN_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "util/container.h" // UniqueQueue struct BlockMakeData; diff --git a/src/mapnode.cpp b/src/mapnode.cpp index 2cffd3e44..4de84dd1d 100644 --- a/src/mapnode.cpp +++ b/src/mapnode.cpp @@ -17,7 +17,7 @@ with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "mapnode.h" #include "porting.h" #include "main.h" // For g_settings diff --git a/src/mapnode.h b/src/mapnode.h index 37826dcde..32e46b63f 100644 --- a/src/mapnode.h +++ b/src/mapnode.h @@ -21,6 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #define MAPNODE_HEADER #include "irrlichttypes.h" +#include "irr_v3d.h" #include "light.h" class INodeDefManager; diff --git a/src/mapsector.h b/src/mapsector.h index 9fede7bd7..74539ab24 100644 --- a/src/mapsector.h +++ b/src/mapsector.h @@ -17,15 +17,11 @@ with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -/* -(c) 2010 Perttu Ahola -*/ - #ifndef MAPSECTOR_HEADER #define MAPSECTOR_HEADER #include -#include "common_irrlicht.h" +#include "irrlichttypes_bloated.h" #include "exceptions.h" #include diff --git a/src/mesh.h b/src/mesh.h index 02299b665..5e1efcd52 100644 --- a/src/mesh.h +++ b/src/mesh.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef MESH_HEADER #define MESH_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include /* diff --git a/src/modalMenu.h b/src/modalMenu.h index 2c20a29b2..04372167b 100644 --- a/src/modalMenu.h +++ b/src/modalMenu.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef MODALMENU_HEADER #define MODALMENU_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" class GUIModalMenu; diff --git a/src/mods.h b/src/mods.h index 1985e4de4..d55dd6c92 100644 --- a/src/mods.h +++ b/src/mods.h @@ -21,6 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #define MODS_HEADER #include "irrlichttypes.h" +#include #include #include #include diff --git a/src/nameidmapping.h b/src/nameidmapping.h index 834ade961..90d8dbed8 100644 --- a/src/nameidmapping.h +++ b/src/nameidmapping.h @@ -24,7 +24,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include #include -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" class NameIdMapping { diff --git a/src/nodedef.h b/src/nodedef.h index 2f2bfe46e..fcd06be71 100644 --- a/src/nodedef.h +++ b/src/nodedef.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef NODEDEF_HEADER #define NODEDEF_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #include #include diff --git a/src/nodemetadata.h b/src/nodemetadata.h index de74e14ee..24779a1ea 100644 --- a/src/nodemetadata.h +++ b/src/nodemetadata.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef NODEMETADATA_HEADER #define NODEMETADATA_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #include #include diff --git a/src/nodetimer.h b/src/nodetimer.h index b9598673c..deb77f10e 100644 --- a/src/nodetimer.h +++ b/src/nodetimer.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef NODETIMER_HEADER #define NODETIMER_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #include diff --git a/src/object_properties.h b/src/object_properties.h index 3218387d3..3f44771e9 100644 --- a/src/object_properties.h +++ b/src/object_properties.h @@ -21,7 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #define OBJECT_PROPERTIES_HEADER #include -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include struct ObjectProperties diff --git a/src/player.h b/src/player.h index 3b5497721..c3ccc960d 100644 --- a/src/player.h +++ b/src/player.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef PLAYER_HEADER #define PLAYER_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include "inventory.h" #include "constants.h" // BS diff --git a/src/porting.h b/src/porting.h index b9534a9c1..2f9d43aca 100644 --- a/src/porting.h +++ b/src/porting.h @@ -25,8 +25,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #define PORTING_HEADER #include -// Included for u32 and such -#include "common_irrlicht.h" +#include "irrlichttypes.h" // u32 #include "debug.h" #include "constants.h" diff --git a/src/profiler.h b/src/profiler.h index dce7d57e2..b1e6abe58 100644 --- a/src/profiler.h +++ b/src/profiler.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef PROFILER_HEADER #define PROFILER_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_bloated.h" #include #include #include diff --git a/src/quicktune.h b/src/quicktune.h index 5531ccc26..a733ccda4 100644 --- a/src/quicktune.h +++ b/src/quicktune.h @@ -49,7 +49,6 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef QUICKTUNE_HEADER #define QUICKTUNE_HEADER -#include "irrlichttypes.h" #include #include #include diff --git a/src/scriptapi.h b/src/scriptapi.h index 59daa3aa0..12a1172a7 100644 --- a/src/scriptapi.h +++ b/src/scriptapi.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef SCRIPTAPI_HEADER #define SCRIPTAPI_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #include "mapnode.h" #include diff --git a/src/serialization.h b/src/serialization.h index 24648c1fc..70b3ee74d 100644 --- a/src/serialization.h +++ b/src/serialization.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef SERIALIZATION_HEADER #define SERIALIZATION_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes.h" #include "exceptions.h" #include #include "util/pointer.h" diff --git a/src/server.h b/src/server.h index 18c223ec7..4d93ae6f3 100644 --- a/src/server.h +++ b/src/server.h @@ -22,7 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "connection.h" #include "environment.h" -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #include "porting.h" #include "map.h" diff --git a/src/servercommand.h b/src/servercommand.h index a3cf750da..c0f78a9f2 100644 --- a/src/servercommand.h +++ b/src/servercommand.h @@ -21,7 +21,7 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. #include #include -#include "common_irrlicht.h" +#include "irrlichttypes.h" #include "player.h" #include "server.h" diff --git a/src/serverobject.h b/src/serverobject.h index 0130ca1bf..6acd0dfee 100644 --- a/src/serverobject.h +++ b/src/serverobject.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef SERVEROBJECT_HEADER #define SERVEROBJECT_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include "activeobject.h" #include "inventorymanager.h" #include "itemgroup.h" diff --git a/src/settings.h b/src/settings.h index 16bac8eec..1ab6fcc6b 100644 --- a/src/settings.h +++ b/src/settings.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef SETTINGS_HEADER #define SETTINGS_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #include #include diff --git a/src/sky.h b/src/sky.h index 2bd3b05f6..65170dad5 100644 --- a/src/sky.h +++ b/src/sky.h @@ -17,7 +17,7 @@ with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include #ifndef SKY_HEADER diff --git a/src/sound.h b/src/sound.h index ddce34dc8..d74acd550 100644 --- a/src/sound.h +++ b/src/sound.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef SOUND_HEADER #define SOUND_HEADER -#include "irrlichttypes.h" +#include "irrlichttypes_bloated.h" #include #include diff --git a/src/staticobject.h b/src/staticobject.h index a55471b7f..87ba111ec 100644 --- a/src/staticobject.h +++ b/src/staticobject.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef STATICOBJECT_HEADER #define STATICOBJECT_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes_bloated.h" #include #include #include "util/serialize.h" diff --git a/src/test.cpp b/src/test.cpp index 63aa09c0b..3dc6814b1 100644 --- a/src/test.cpp +++ b/src/test.cpp @@ -18,7 +18,7 @@ with this program; if not, write to the Free Software Foundation, Inc., */ #include "test.h" -#include "common_irrlicht.h" +#include "irrlichttypes_extrabloated.h" #include "debug.h" #include "map.h" #include "player.h" diff --git a/src/tile.h b/src/tile.h index a6609a3a6..8c1f42e07 100644 --- a/src/tile.h +++ b/src/tile.h @@ -20,7 +20,11 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef TILE_HEADER #define TILE_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes.h" +#include "irr_v2d.h" +#include "irr_v3d.h" +#include +#include #include "threads.h" #include diff --git a/src/tool.h b/src/tool.h index 35a8c2ad6..18c09dca3 100644 --- a/src/tool.h +++ b/src/tool.h @@ -20,7 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef TOOL_HEADER #define TOOL_HEADER -#include "common_irrlicht.h" +#include "irrlichttypes.h" #include #include #include diff --git a/src/util/directiontables.h b/src/util/directiontables.h index c02b3d124..5bebd2fdb 100644 --- a/src/util/directiontables.h +++ b/src/util/directiontables.h @@ -21,6 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #define UTIL_DIRECTIONTABLES_HEADER #include "../irrlichttypes.h" +#include "../irr_v3d.h" extern const v3s16 g_6dirs[6]; diff --git a/src/util/numeric.h b/src/util/numeric.h index 0ce21b7e3..5ed4d0e99 100644 --- a/src/util/numeric.h +++ b/src/util/numeric.h @@ -21,6 +21,10 @@ with this program; if not, write to the Free Software Foundation, Inc., #define UTIL_NUMERIC_HEADER #include "../irrlichttypes.h" +#include "../irr_v2d.h" +#include "../irr_v3d.h" +#include "../irr_aabb3d.h" +#include // Calculate the borders of a "d-radius" cube void getFacePositions(core::list &list, u16 d); diff --git a/src/util/pointedthing.h b/src/util/pointedthing.h index 82d66dfa8..e61e2f4f3 100644 --- a/src/util/pointedthing.h +++ b/src/util/pointedthing.h @@ -21,6 +21,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #define UTIL_POINTEDTHING_HEADER #include "../irrlichttypes.h" +#include "../irr_v3d.h" #include #include diff --git a/src/util/pointer.h b/src/util/pointer.h index 02f11c2ea..766cc2328 100644 --- a/src/util/pointer.h +++ b/src/util/pointer.h @@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "../irrlichttypes.h" #include "../debug.h" // For assert() +#include template class SharedPtr diff --git a/src/util/serialize.h b/src/util/serialize.h index e229a00be..50a002c10 100644 --- a/src/util/serialize.h +++ b/src/util/serialize.h @@ -21,6 +21,8 @@ with this program; if not, write to the Free Software Foundation, Inc., #define UTIL_SERIALIZE_HEADER #include "../irrlichttypes.h" +#include "../irr_v2d.h" +#include "../irr_v3d.h" #include #include #include "../exceptions.h" diff --git a/src/voxel.h b/src/voxel.h index 483b4d2a0..e7155dfac 100644 --- a/src/voxel.h +++ b/src/voxel.h @@ -21,6 +21,8 @@ with this program; if not, write to the Free Software Foundation, Inc., #define VOXEL_HEADER #include "irrlichttypes.h" +#include "irr_v3d.h" +#include #include #include "debug.h" #include "mapnode.h" -- 2.25.1