1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-04-27 14:57:44 +00:00

Merge pull request #558 from NotAdam/develop

warn instead of crash with missing navmeshes
This commit is contained in:
Mordred 2019-04-30 22:57:41 +02:00 committed by GitHub
commit 16288044a1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 3 deletions

View file

@ -1,6 +1,6 @@
#include "Logger.h"
#define SPDLOG_LEVEL_NAMES { "trace", "debug", "info", "warning", "error", "fatal", "off" }
#define SPDLOG_LEVEL_NAMES { "trace", "debug", "info", "warn", "error", "fatal", "off" }
#include <spdlog/spdlog.h>
#include <spdlog/async.h>

View file

@ -401,6 +401,9 @@ void Sapphire::Entity::BNpc::update( uint64_t tickCount )
auto pNaviProvider = m_pCurrentZone->getNaviProvider();
if( !pNaviProvider )
return;
switch( m_state )
{
case BNpcState::Dead:

View file

@ -138,8 +138,7 @@ bool Sapphire::Zone::init()
if( !m_pNaviProvider )
{
Logger::fatal( "No navmesh found for TerritoryType#{}", getTerritoryTypeId() );
throw std::runtime_error( "Missing navmesh file(s)." );
Logger::warn( "No navmesh found for TerritoryType#{}", getTerritoryTypeId() );
}
return true;