- Fixed assertion when clicking on "Multiplayer Game" in Main Menu Screen

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@5882 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
Wanne
2013-02-28 09:56:57 +00:00
parent a018e77323
commit 2de29e73fa
+5 -6
View File
@@ -351,19 +351,18 @@ void ExitMainMenu( )
CreateDestroyMainMenuButtons( FALSE );
for( iCounter2 = 1; iCounter2 < MAX_ELEMENT; iCounter2++ )
{
{
if (gMainMenulayout[iCounter2].Visible == 1)
{
// WANNE: This is a dirty fix. I don't know when that was introduced, but when clicking on "Multiplayer Game", the game crashes when trying to call DeleteVideoSurfaceFromIndex()
if (is_networked && iCounter2 == 1)
continue;
// DeleteVideoObjectFromIndex( gMainMenulayout[iCounter2].uiIndex );
DeleteVideoSurfaceFromIndex( gMainMenulayout[iCounter2].uiIndex );
}
}
gMsgBox.uiExitScreen = MAINMENU_SCREEN;
}