try to avoid a crash here, at the expense of it possibly not logging in for some people... please send log info if it happens to you.
This commit is contained in:
@@ -116,7 +116,16 @@ void ScreenSMOnlineLogin::HandleScreenMessage(const ScreenMessage SM)
|
|||||||
else if( SM == SM_SMOnlinePack )
|
else if( SM == SM_SMOnlinePack )
|
||||||
{
|
{
|
||||||
LOG->Trace("[ScreenSMOnlineLogin::HandleScreenMessage] SMOnlinePack");
|
LOG->Trace("[ScreenSMOnlineLogin::HandleScreenMessage] SMOnlinePack");
|
||||||
sLoginQuestion = YOU_ARE_LOGGING_ON_AS.GetValue() + "\n" + GAMESTATE->GetPlayerDisplayName((PlayerNumber) m_iPlayer) + "\n" + ENTER_YOUR_PASSWORD.GetValue();
|
if(!GAMESTATE->IsPlayerEnabled((PlayerNumber) m_iPlayer))
|
||||||
|
{
|
||||||
|
LOG->Warn("Invalid player number: %i", m_iPlayer);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// This can cause problems in certain situations -aj
|
||||||
|
sLoginQuestion = YOU_ARE_LOGGING_ON_AS.GetValue() + "\n"
|
||||||
|
+ GAMESTATE->GetPlayerDisplayName((PlayerNumber) m_iPlayer) + "\n" +
|
||||||
|
ENTER_YOUR_PASSWORD.GetValue();
|
||||||
int ResponseCode = NSMAN->m_SMOnlinePacket.Read1();
|
int ResponseCode = NSMAN->m_SMOnlinePacket.Read1();
|
||||||
if (ResponseCode == 0)
|
if (ResponseCode == 0)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user