diff --git a/Source/mainmenu.cpp b/Source/mainmenu.cpp index eecde605e..af5503d83 100644 --- a/Source/mainmenu.cpp +++ b/Source/mainmenu.cpp @@ -47,6 +47,7 @@ int __stdcall mainmenu_select_hero_dialog( &gnDifficulty)) TermMsg("Unable to display SelHeroSing"); + if (dlgresult == 2) gbLoadGame = TRUE; else diff --git a/Stub/DiabloUI/credits.cpp b/Stub/DiabloUI/credits.cpp index 01184549a..5665fe69c 100644 --- a/Stub/DiabloUI/credits.cpp +++ b/Stub/DiabloUI/credits.cpp @@ -555,8 +555,8 @@ BOOL __stdcall UiCreditsDialog(int a1) SDL_Event event; while (!endMenu && lineCount > 0) { + CapFPS(); credts_Render(); - DrawMouse(); UiFadeIn(); while (SDL_PollEvent(&event)) { @@ -569,8 +569,6 @@ BOOL __stdcall UiCreditsDialog(int a1) exit(0); } } - - CapFPS(); } BlackPalette(); diff --git a/Stub/DiabloUI/mainmenu.cpp b/Stub/DiabloUI/mainmenu.cpp index 3fbd5893e..b41fd3493 100644 --- a/Stub/DiabloUI/mainmenu.cpp +++ b/Stub/DiabloUI/mainmenu.cpp @@ -66,6 +66,7 @@ BOOL __stdcall UiMainMenuDialog(char *name, int *pdwResult, void(__stdcall *fnSo bool endMenu = false; while (!endMenu) { + CapFPS(); mainmenu_Render(name); DrawMouse(); UiFadeIn(); @@ -165,8 +166,6 @@ BOOL __stdcall UiMainMenuDialog(char *name, int *pdwResult, void(__stdcall *fnSo break; } } - - CapFPS(); } BlackPalette(); diff --git a/Stub/DiabloUI/selconn.cpp b/Stub/DiabloUI/selconn.cpp index 748705702..fcd3bb52d 100644 --- a/Stub/DiabloUI/selconn.cpp +++ b/Stub/DiabloUI/selconn.cpp @@ -66,6 +66,7 @@ int __stdcall UiSelectProvider(int a1, _SNETPROGRAMDATA *client_info, _SNETPLAYE bool endMenu = false; while (!endMenu) { + CapFPS(); selconn_Render(); DrawMouse(); UiFadeIn(); @@ -124,8 +125,6 @@ int __stdcall UiSelectProvider(int a1, _SNETPROGRAMDATA *client_info, _SNETPLAYE exit(0); } } - - CapFPS(); } BlackPalette(); diff --git a/Stub/DiabloUI/selhero.cpp b/Stub/DiabloUI/selhero.cpp index add163e0c..a4c365212 100644 --- a/Stub/DiabloUI/selhero.cpp +++ b/Stub/DiabloUI/selhero.cpp @@ -224,6 +224,8 @@ BOOL __stdcall UiSelHeroSingDialog( bool endMenu = false; while (!endMenu) { + CapFPS(); + switch (submenu) { case SINGLEPLAYER_LOAD: selhero_Render(); @@ -340,8 +342,6 @@ BOOL __stdcall UiSelHeroSingDialog( exit(0); } } - - CapFPS(); } BlackPalette(); @@ -396,6 +396,8 @@ BOOL __stdcall UiSelHeroMultDialog( int endMenu = false; while (endMenu == false) { + CapFPS(); + switch (submenu) { case MULTIPLAYER_LOBBY: selhero_Render_GameType(HeroChosen, 1); @@ -562,8 +564,6 @@ BOOL __stdcall UiSelHeroMultDialog( exit(0); } } - - CapFPS(); } BlackPalette(); diff --git a/Stub/DiabloUI/title.cpp b/Stub/DiabloUI/title.cpp index d4a987d63..7a64690a8 100644 --- a/Stub/DiabloUI/title.cpp +++ b/Stub/DiabloUI/title.cpp @@ -28,6 +28,7 @@ BOOL __stdcall UiTitleDialog(int a1) SDL_Event event; while (!endMenu && SDL_GetTicks() < timeOut) { + CapFPS(); title_Render(); UiFadeIn(); @@ -41,8 +42,6 @@ BOOL __stdcall UiTitleDialog(int a1) exit(0); } } - - CapFPS(); } BlackPalette();