From ab6c2d0d56275a6e99f8fc05299af997f75b1b96 Mon Sep 17 00:00:00 2001 From: Tom Pratt Date: Fri, 24 Apr 2026 13:18:36 +0200 Subject: [PATCH] Dont try to load temporary save states when launching netplay An orientation change can trigger this code path immediately when a game starts. e.g. dolphin is portrait when launching the game but settings force gameplay to landscape. We want to avoid this and continue to the netplay launch code below. If the user backgrounds dolphin during netplay and then resumes after the process has died it will actually resume from the save state in single player mode, not sure if thats good or bad but fine for now. Netplay doesnt handle rotation very well, seems to go more and more out of sync the more rotations. --- .../org/dolphinemu/dolphinemu/fragments/EmulationFragment.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/fragments/EmulationFragment.kt b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/fragments/EmulationFragment.kt index 61a5493950..49331d8a4c 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/fragments/EmulationFragment.kt +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/fragments/EmulationFragment.kt @@ -208,7 +208,10 @@ class EmulationFragment : Fragment(), SurfaceHolder.Callback { if (NativeLibrary.IsUninitialized()) { NativeLibrary.SetIsBooting() val emulationThread = Thread({ - if (loadPreviousTemporaryState) { + // Don't load temporary saves when launching Netplay, this path can trigger + // when a game starts due to orientation changes caused by a mismatch in menu + // vs emulation activity orientations. + if (loadPreviousTemporaryState && !Netplay.isLaunching) { Log.debug("[EmulationFragment] Starting emulation thread from previous state.") val paths = requireNotNull(gamePaths) { "Cannot start emulation without any game paths"