1
0
mirror of https://github.com/sui-feng-cb/AzurLaneAutoScript1.git synced 2026-07-19 13:03:54 +08:00

Fix MuMu Pro emulator-* serial detection on macOS (#5821)

This commit is contained in:
Benny
2026-07-18 00:46:55 +08:00
committed by GitHub
parent b053630e48
commit 372d94c821

View File

@@ -338,7 +338,10 @@ class Connection(ConnectionAttr):
if not IS_MACINTOSH:
return False
if not self.is_mumu_family:
return False
if not self.serial.startswith('emulator-'):
return False
if 'MACPRO' not in self.nemud_player_engine.upper():
return False
logger.attr('is_mumu_pro', True)
return True
@@ -366,7 +369,7 @@ class Connection(ConnectionAttr):
return res
def check_mumu_app_keep_alive(self):
if not self.is_mumu_family:
if not (self.is_mumu_family or self.is_mumu_pro):
return False
res = self.nemud_app_keep_alive
@@ -401,15 +404,14 @@ class Connection(ConnectionAttr):
which has nemud.app_keep_alive and always be a vertical device
MuMu PRO on mac has the same feature
"""
if self.is_mumu_pro:
return True
if not self.is_mumu_family:
return False
if self.is_mumu_over_version_400:
return True
if self.nemud_app_keep_alive != '':
return True
if IS_MACINTOSH:
if 'MACPRO' in self.nemud_player_engine:
return True
return False
@cached_property