1
Fork 0
mirror of https://github.com/SapphireServer/Sapphire.git synced 2025-04-28 15:17:46 +00:00

no payers anymore

This commit is contained in:
AriAvery 2018-11-23 11:04:19 +01:00
parent 1a7a296e30
commit 5b29c328a8
2 changed files with 5 additions and 5 deletions

View file

@ -367,9 +367,9 @@ bool Core::ServerMgr::isRunning() const
std::string Core::ServerMgr::getPlayerNameFromDb( uint32_t playerId ) std::string Core::ServerMgr::getPlayerNameFromDb( uint32_t playerId )
{ {
auto it = m_payerNameMapById.find( playerId ); auto it = m_playerNameMapById.find( playerId );
if( it != m_payerNameMapById.end() ) if( it != m_playerNameMapById.end() )
return ( it->second ); return ( it->second );
auto pDb = g_fw.get< Db::DbWorkerPool< Db::ZoneDbConnection > >(); auto pDb = g_fw.get< Db::DbWorkerPool< Db::ZoneDbConnection > >();
@ -380,7 +380,7 @@ std::string Core::ServerMgr::getPlayerNameFromDb( uint32_t playerId )
std::string playerName = res->getString( 1 ); std::string playerName = res->getString( 1 );
m_payerNameMapById[ playerId ] = playerName; m_playerNameMapById[ playerId ] = playerName;
return playerName; return playerName;
} }
@ -390,7 +390,7 @@ void Core::ServerMgr::updatePlayerName( uint32_t playerId, const std::string & p
auto pDb = g_fw.get< Db::DbWorkerPool< Db::ZoneDbConnection > >(); auto pDb = g_fw.get< Db::DbWorkerPool< Db::ZoneDbConnection > >();
pDb->execute( "UPDATE charainfo SET name = '" + playerNewName + "' WHERE name = " + std::to_string( playerId ) ); pDb->execute( "UPDATE charainfo SET name = '" + playerNewName + "' WHERE name = " + std::to_string( playerId ) );
m_payerNameMapById[ playerId ] = playerNewName; m_playerNameMapById[ playerId ] = playerNewName;
} }
void Core::ServerMgr::loadBNpcTemplates() void Core::ServerMgr::loadBNpcTemplates()

View file

@ -60,7 +60,7 @@ private:
std::map< uint32_t, SessionPtr > m_sessionMapById; std::map< uint32_t, SessionPtr > m_sessionMapById;
std::map< std::string, SessionPtr > m_sessionMapByName; std::map< std::string, SessionPtr > m_sessionMapByName;
std::map< uint32_t, std::string > m_payerNameMapById; std::map< uint32_t, std::string > m_playerNameMapById;
std::map< uint32_t, uint32_t > m_zones; std::map< uint32_t, uint32_t > m_zones;
std::map< std::string, Entity::BNpcTemplatePtr > m_bNpcTemplateMap; std::map< std::string, Entity::BNpcTemplatePtr > m_bNpcTemplateMap;