mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-05-02 00:47:45 +00:00
cap poly length for generated nav paths
This commit is contained in:
parent
edf682cc00
commit
c2356b9057
2 changed files with 23 additions and 25 deletions
|
@ -198,9 +198,6 @@ bool Sapphire::Entity::BNpc::moveTo( const FFXIVARR_POSITION3& pos )
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check if we have to recalculate
|
|
||||||
if( Util::getTimeMs() - m_naviLastUpdate > 500 )
|
|
||||||
{
|
|
||||||
auto pNaviMgr = m_pFw->get< World::Manager::NaviMgr >();
|
auto pNaviMgr = m_pFw->get< World::Manager::NaviMgr >();
|
||||||
auto pNaviProvider = pNaviMgr->getNaviProvider( m_pCurrentZone->getBgPath() );
|
auto pNaviProvider = pNaviMgr->getNaviProvider( m_pCurrentZone->getBgPath() );
|
||||||
|
|
||||||
|
@ -225,7 +222,8 @@ bool Sapphire::Entity::BNpc::moveTo( const FFXIVARR_POSITION3& pos )
|
||||||
{
|
{
|
||||||
Logger::debug( "No path found from x{0} y{1} z{2} to x{3} y{4} z{5} in {6}",
|
Logger::debug( "No path found from x{0} y{1} z{2} to x{3} y{4} z{5} in {6}",
|
||||||
getPos().x, getPos().y, getPos().z, pos.x, pos.y, pos.z, m_pCurrentZone->getInternalName() );
|
getPos().x, getPos().y, getPos().z, pos.x, pos.y, pos.z, m_pCurrentZone->getInternalName() );
|
||||||
}
|
|
||||||
|
hateListClear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
|
|
||||||
namespace Sapphire::World::Navi
|
namespace Sapphire::World::Navi
|
||||||
{
|
{
|
||||||
const int32_t MAX_POLYS = 256;
|
const int32_t MAX_POLYS = 8;
|
||||||
const int32_t MAX_SMOOTH = 2048;
|
const int32_t MAX_SMOOTH = 2048;
|
||||||
|
|
||||||
const int32_t NAVMESHSET_MAGIC = 'M' << 24 | 'S' << 16 | 'E' << 8 | 'T'; //'MSET'
|
const int32_t NAVMESHSET_MAGIC = 'M' << 24 | 'S' << 16 | 'E' << 8 | 'T'; //'MSET'
|
||||||
|
|
Loading…
Add table
Reference in a new issue