1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-05-05 02:07:46 +00:00

WiP Fix houses not being loaded after restart

This commit is contained in:
Mordred 2023-01-25 17:11:23 +01:00
parent fb425c3213
commit e7bc21a1f2
2 changed files with 6 additions and 6 deletions

View file

@ -80,8 +80,8 @@ bool HousingMgr::init()
Logger::info( "HousingMgr: Caching housing land init data" );
//LAND_SEL_ALL
// 18 wards per territory, 4 territories
m_landCache.reserve( 18 * 4 );
// 12 wards per territory, 2 territories
m_landCache.reserve( 12 * 2 );
initLandCache();
@ -115,7 +115,7 @@ bool HousingMgr::loadEstateInventories()
{
Logger::info( "HousingMgr: Loading inventories for estates" );
/* auto& db = Common::Service< Db::DbWorkerPool< Db::ZoneDbConnection > >::ref();
auto& db = Common::Service< Db::DbWorkerPool< Db::ZoneDbConnection > >::ref();
auto stmt = db.getPreparedStatement( Db::LAND_INV_SEL_ALL );
auto res = db.query( stmt );
@ -166,7 +166,7 @@ bool HousingMgr::loadEstateInventories()
itemCount++;
}
Logger::debug( "HousingMgr: Loaded {0} inventory items", itemCount );*/
Logger::debug( "HousingMgr: Loaded {0} inventory items", itemCount );
return true;
}

View file

@ -138,8 +138,8 @@ bool Sapphire::HousingZone::init()
m_landPtrMap[ entry.m_landId ] = land;
// TODO: Fixme
// if( entry.m_houseId > 0 )
// registerEstateEntranceEObj( entry.m_landId );
if( entry.m_houseId > 0 )
registerEstateEntranceEObj( entry.m_landId );
updateYardObjects( land->getLandIdent() );
}