Bigharry1991
New Member
- Joined
- Jun 29, 2009
- Messages
- 17
- Reaction score
- 1
Well I compiled Rev 3777
updated
sprintf(buffer, "%d", g_game.getPlayersOnline());
to
sprintf(buffer, "%d", Connection::connectionCount);
output->put<uint32_t>(g_game.getPlayersOnline());
to
output->put<uint32_t>(Connection::connectionCount);
I also compiled using --enable-server-diag
so basically my code is
if(requestedInfo & REQUEST_PLAYERS_INFO)
{
output->put<char>(0x20);
output->put<uint32_t>(Connection::connectionCount);
output->put<uint32_t>(g_config.getNumber(ConfigManager::MAX_PLAYERS));
output->put<uint32_t>(g_game.getPlayersRecord());
but yet its showing 2 people for every 1 person
like so
Players Active:2
Players AFK:-1
But there is only 1 person online (thats on the website)
But on otservlist it also says 2 people are online.
so i took the server off there to be safe until i know whats up with it
updated
sprintf(buffer, "%d", g_game.getPlayersOnline());
to
sprintf(buffer, "%d", Connection::connectionCount);
output->put<uint32_t>(g_game.getPlayersOnline());
to
output->put<uint32_t>(Connection::connectionCount);
I also compiled using --enable-server-diag
so basically my code is
if(requestedInfo & REQUEST_PLAYERS_INFO)
{
output->put<char>(0x20);
output->put<uint32_t>(Connection::connectionCount);
output->put<uint32_t>(g_config.getNumber(ConfigManager::MAX_PLAYERS));
output->put<uint32_t>(g_game.getPlayersRecord());
but yet its showing 2 people for every 1 person
like so
Players Active:2
Players AFK:-1
But there is only 1 person online (thats on the website)
But on otservlist it also says 2 people are online.
so i took the server off there to be safe until i know whats up with it