1 #ifndef OPENMW_COMPONENTS_DETOURNAVIGATOR_NAVIGATORSTUB_H 2 #define OPENMW_COMPONENTS_DETOURNAVIGATOR_NAVIGATORSTUB_H 3 4 #include "navigator.hpp" 5 6 namespace Loading 7 { 8 class Listener; 9 } 10 11 namespace DetourNavigator 12 { 13 class NavigatorStub final : public Navigator 14 { 15 public: 16 NavigatorStub() = default; 17 addAgent(const osg::Vec3f &)18 void addAgent(const osg::Vec3f& /*agentHalfExtents*/) override {} 19 removeAgent(const osg::Vec3f &)20 void removeAgent(const osg::Vec3f& /*agentHalfExtents*/) override {} 21 addObject(const ObjectId,const osg::ref_ptr<const osg::Object> &,const btHeightfieldTerrainShape &,const btTransform &)22 bool addObject(const ObjectId /*id*/, const osg::ref_ptr<const osg::Object>& /*holder*/, 23 const btHeightfieldTerrainShape& /*shape*/, const btTransform& /*transform*/) override 24 { 25 return false; 26 } 27 addObject(const ObjectId,const ObjectShapes &,const btTransform &)28 bool addObject(const ObjectId /*id*/, const ObjectShapes& /*shapes*/, const btTransform& /*transform*/) override 29 { 30 return false; 31 } 32 addObject(const ObjectId,const DoorShapes &,const btTransform &)33 bool addObject(const ObjectId /*id*/, const DoorShapes& /*shapes*/, const btTransform& /*transform*/) override 34 { 35 return false; 36 } 37 updateObject(const ObjectId,const ObjectShapes &,const btTransform &)38 bool updateObject(const ObjectId /*id*/, const ObjectShapes& /*shapes*/, const btTransform& /*transform*/) override 39 { 40 return false; 41 } 42 updateObject(const ObjectId,const DoorShapes &,const btTransform &)43 bool updateObject(const ObjectId /*id*/, const DoorShapes& /*shapes*/, const btTransform& /*transform*/) override 44 { 45 return false; 46 } 47 removeObject(const ObjectId)48 bool removeObject(const ObjectId /*id*/) override 49 { 50 return false; 51 } 52 addWater(const osg::Vec2i &,const int,const btScalar,const btTransform &)53 bool addWater(const osg::Vec2i& /*cellPosition*/, const int /*cellSize*/, const btScalar /*level*/, 54 const btTransform& /*transform*/) override 55 { 56 return false; 57 } 58 removeWater(const osg::Vec2i &)59 bool removeWater(const osg::Vec2i& /*cellPosition*/) override 60 { 61 return false; 62 } 63 addPathgrid(const ESM::Cell &,const ESM::Pathgrid &)64 void addPathgrid(const ESM::Cell& /*cell*/, const ESM::Pathgrid& /*pathgrid*/) override {} 65 removePathgrid(const ESM::Pathgrid &)66 void removePathgrid(const ESM::Pathgrid& /*pathgrid*/) override {} 67 update(const osg::Vec3f &)68 void update(const osg::Vec3f& /*playerPosition*/) override {} 69 updatePlayerPosition(const osg::Vec3f &)70 void updatePlayerPosition(const osg::Vec3f& /*playerPosition*/) override {}; 71 setUpdatesEnabled(bool)72 void setUpdatesEnabled(bool /*enabled*/) override {} 73 wait(Loading::Listener &,WaitConditionType)74 void wait(Loading::Listener& /*listener*/, WaitConditionType /*waitConditionType*/) override {} 75 getNavMesh(const osg::Vec3f &) const76 SharedNavMeshCacheItem getNavMesh(const osg::Vec3f& /*agentHalfExtents*/) const override 77 { 78 return mEmptyNavMeshCacheItem; 79 } 80 getNavMeshes() const81 std::map<osg::Vec3f, SharedNavMeshCacheItem> getNavMeshes() const override 82 { 83 return std::map<osg::Vec3f, SharedNavMeshCacheItem>(); 84 } 85 getSettings() const86 const Settings& getSettings() const override 87 { 88 return mDefaultSettings; 89 } 90 reportStats(unsigned int,osg::Stats &) const91 void reportStats(unsigned int /*frameNumber*/, osg::Stats& /*stats*/) const override {} 92 getRecastMeshTiles()93 RecastMeshTiles getRecastMeshTiles() override 94 { 95 return {}; 96 } 97 getMaxNavmeshAreaRealRadius() const98 float getMaxNavmeshAreaRealRadius() const override 99 { 100 return std::numeric_limits<float>::max(); 101 } 102 103 private: 104 Settings mDefaultSettings {}; 105 SharedNavMeshCacheItem mEmptyNavMeshCacheItem; 106 }; 107 } 108 109 #endif 110