CJ source code

Lithtech Jupiter engine

Post Reply
User avatar
URA
More Advanced Member
More Advanced Member
Posts: 55
Joined: Sat Jan 28, 2006 10:19 pm
Contact:

CJ source code

Post by URA » Tue Oct 17, 2006 4:19 am

Every time I run CJ with custom dll's and try to join a server the game crashes (just before the server details pop up window).
As a work-a-round, I commented out part of CScreenJoin::PreState_QueryDetails (near the end)

Code: Select all

bool CScreenJoin::PreState_QueryDetails()
{
	TServerEntryMap::const_iterator iter = m_cServerMap.find(m_sSelectedServerAddress);
	if( iter == m_cServerMap.end( ))
  return false;
	std::string const& sPrivateAddress = iter->first;
	const ServerEntry &serverEntry = iter->second;

	if (stricmp(serverEntry.m_sVersion.c_str(), g_pVersionMgr->GetNetVersion()) != 0)
	{
  SetDetailErrorMessage(LoadTempString(IDS_SERVER_DETAIL_VERSION));
  return false;
	}

	// Convert the address string into ip and port.
	char szIP[16];
	uint32 nColon = serverEntry.m_sPublicAddress.rfind( ":", serverEntry.m_sPublicAddress.length( ) - 1);
	if( nColon == std::string::npos || nColon > ARRAY_LEN( szIP ))
  return false;
	strncpy( szIP, serverEntry.m_sPublicAddress.c_str( ), nColon );
	szIP[nColon] = 0;
	if( !serverEntry.m_sPublicAddress.c_str( )[nColon+1] )
  return false;
	uint16 nPort = min( atoi( serverEntry.m_sPublicAddress.c_str( ) + nColon + 1 ), 65535 );

	// Request the details for this server.
	IGameSpyBrowser* pGameSpyBrowser = ( serverEntry.m_bDemoServer ) ? 
  g_pClientMultiplayerMgr->GetDemoServerBrowser( ) : 
  g_pClientMultiplayerMgr->GetRetailServerBrowser( );

/*
**	if( !pGameSpyBrowser->RequestServerDetails( szIP, nPort, ServerInfoCallback, this ))
**	{
**  SetDetailErrorMessage(LoadTempString(IDS_SERVER_NORESPONSE));
**  return false;
**	}
*/

	return true;
}
Now I can join the server but as a side effect the server details pop up window is now empty.
Complied with MSVC++ 7.1.3088 and .NET Framework 1.1.4322 SP1
Anyone have a clue on how to fix this? I don't :headbang:

User avatar
Spawn
Admin
Admin
Posts: 1310
Joined: Sun Jul 25, 2004 12:50 am
Location: Norway
Contact:

Post by Spawn » Sat Nov 04, 2006 10:37 pm

I really wish I could help :huh:

Hope you figured out something though :)
Image

User avatar
URA
More Advanced Member
More Advanced Member
Posts: 55
Joined: Sat Jan 28, 2006 10:19 pm
Contact:

Post by URA » Fri Nov 10, 2006 12:22 am

Thanks, but I haven't figured out much ;)
Still my #1 bug :lol:

Post Reply
jedwabna poszewka 50x60