diff --git a/src/game/CMakeLists.txt b/src/game/CMakeLists.txt index f338fb914..c3a83bb82 100644 --- a/src/game/CMakeLists.txt +++ b/src/game/CMakeLists.txt @@ -23,6 +23,8 @@ include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/vmap ${CMAKE_CURRENT_SOURCE_DIR}/AuctionHouseBot ${CMAKE_SOURCE_DIR}/dep/include/g3dlite + ${CMAKE_SOURCE_DIR}/dep/recastnavigation/Detour + ${CMAKE_SOURCE_DIR}/dep/recastnavigation/ ${CMAKE_SOURCE_DIR}/dep/include ${CMAKE_SOURCE_DIR}/src/shared ${CMAKE_SOURCE_DIR}/src/framework @@ -42,7 +44,7 @@ source_group("World/Handlers" ) source_group("Motion generators" - REGULAR_EXPRESSION Generator|MotionMaster + REGULAR_EXPRESSION MoveMap|MoveMapSharedDefines|Generator|MotionMaster ) source_group("Server" @@ -82,6 +84,7 @@ add_library(game STATIC target_link_libraries(game shared + detour ) if(UNIX) diff --git a/src/game/MoveMap.cpp b/src/game/MoveMap.cpp new file mode 100644 index 000000000..96a2ca8e2 --- /dev/null +++ b/src/game/MoveMap.cpp @@ -0,0 +1,24 @@ +/* + * Copyright (C) 2005-2012 MaNGOS + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#include "GridMap.h" +#include "Log.h" +#include "World.h" + +#include "MoveMap.h" +#include "MoveMapSharedDefines.h" diff --git a/src/game/MoveMap.h b/src/game/MoveMap.h new file mode 100644 index 000000000..a5cf93b2f --- /dev/null +++ b/src/game/MoveMap.h @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2005-2012 MaNGOS + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#ifndef _MOVE_MAP_H +#define _MOVE_MAP_H + +#include "Utilities/UnorderedMapSet.h" + +#include "../../dep/recastnavigation/Detour/Include/DetourAlloc.h" +#include "../../dep/recastnavigation/Detour/Include/DetourNavMesh.h" +#include "../../dep/recastnavigation/Detour/Include/DetourNavMeshQuery.h" + +#endif // _MOVE_MAP_H diff --git a/src/game/MoveMapSharedDefines.h b/src/game/MoveMapSharedDefines.h new file mode 100644 index 000000000..6d7388ce1 --- /dev/null +++ b/src/game/MoveMapSharedDefines.h @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2005-2012 MaNGOS + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#ifndef _MOVE_MAP_SHARED_DEFINES_H +#define _MOVE_MAP_SHARED_DEFINES_H + +#include "Platform/Define.h" +#include "../recastnavigation/Detour/Include/DetourNavMesh.h" + +#define MMAP_MAGIC 0x4d4d4150 // 'MMAP' +#define MMAP_VERSION 3 + +#endif // _MOVE_MAP_SHARED_DEFINES_H diff --git a/src/game/PathFinder.cpp b/src/game/PathFinder.cpp new file mode 100644 index 000000000..c69384ad0 --- /dev/null +++ b/src/game/PathFinder.cpp @@ -0,0 +1,25 @@ +/* + * Copyright (C) 2005-2012 MaNGOS + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#include "MoveMap.h" +#include "GridMap.h" +#include "Creature.h" +#include "PathFinder.h" +#include "Log.h" + +#include "../recastnavigation/Detour/Include/DetourCommon.h" diff --git a/src/game/PathFinder.h b/src/game/PathFinder.h new file mode 100644 index 000000000..b7c0310cf --- /dev/null +++ b/src/game/PathFinder.h @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2005-2012 MaNGOS + * + * 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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#ifndef MANGOS_PATH_FINDER_H +#define MANGOS_PATH_FINDER_H + +#include "MoveMapSharedDefines.h" +#include "../recastnavigation/Detour/Include/DetourNavMesh.h" +#include "../recastnavigation/Detour/Include/DetourNavMeshQuery.h" + +#include "movement/MoveSplineInitArgs.h" + +#endif diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index 76a5fd3cb..29ad89dd0 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "11906" + #define REVISION_NR "11907" #endif // __REVISION_NR_H__ diff --git a/win/VC100/game.vcxproj b/win/VC100/game.vcxproj index e35ee9e36..cb2f00693 100644 --- a/win/VC100/game.vcxproj +++ b/win/VC100/game.vcxproj @@ -431,6 +431,7 @@ + @@ -447,6 +448,7 @@ + Create pchdef.h @@ -593,6 +595,8 @@ + + @@ -612,6 +616,7 @@ + @@ -664,6 +669,9 @@ + + {72bdf975-4d4a-42c7-b2c4-f9ed90a2abb6} + {90297c34-f231-4df4-848e-a74bcc0e40ed} diff --git a/win/VC100/game.vcxproj.filters b/win/VC100/game.vcxproj.filters index 6a69b7a89..dd1cf6d67 100644 --- a/win/VC100/game.vcxproj.filters +++ b/win/VC100/game.vcxproj.filters @@ -457,6 +457,12 @@ Tool + + Motion generators + + + World/Handlers + Object @@ -892,9 +898,18 @@ Tool + + Motion generators + Object + + World/Handlers + + + World/Handlers + AhBot diff --git a/win/VC100/mangosd.vcxproj b/win/VC100/mangosd.vcxproj index 9e57bc989..9758febac 100644 --- a/win/VC100/mangosd.vcxproj +++ b/win/VC100/mangosd.vcxproj @@ -479,6 +479,9 @@ + + {72bdf975-4d4a-42c7-b2c4-f9ed90a2abb6} + {1dc6c4da-a028-41f3-877d-d5400c594f88} diff --git a/win/VC90/game.vcproj b/win/VC90/game.vcproj index 7942581ba..0d7db3220 100644 --- a/win/VC90/game.vcproj +++ b/win/VC90/game.vcproj @@ -874,6 +874,18 @@ RelativePath="..\..\src\game\MiscHandler.cpp" > + + + + + + @@ -1094,6 +1106,14 @@ RelativePath="..\..\src\game\MovementGenerator.h" > + + + + diff --git a/win/VC90/mangosd.vcproj b/win/VC90/mangosd.vcproj index 3b4900263..d1790096b 100644 --- a/win/VC90/mangosd.vcproj +++ b/win/VC90/mangosd.vcproj @@ -80,7 +80,7 @@