Opt: [ALAS] Skip trying nemu_ipc on MuMu Global

This commit is contained in:
LmeSzinc 2024-09-15 02:22:39 +08:00
parent 4da677a084
commit 543dd27e0e

View File

@ -469,6 +469,9 @@ class NemuIpc(Platform):
""" """
# Try existing settings first # Try existing settings first
if self.config.EmulatorInfo_path: if self.config.EmulatorInfo_path:
if 'MuMuPlayerGlobal' in self.config.EmulatorInfo_path:
logger.info(f'nemu_ipc is not available on MuMuPlayerGlobal, {self.config.EmulatorInfo_path}')
raise RequestHumanTakeover
folder = os.path.abspath(os.path.join(self.config.EmulatorInfo_path, '../../')) folder = os.path.abspath(os.path.join(self.config.EmulatorInfo_path, '../../'))
index = NemuIpcImpl.serial_to_id(self.serial) index = NemuIpcImpl.serial_to_id(self.serial)
if index is not None: if index is not None:
@ -488,6 +491,9 @@ class NemuIpc(Platform):
if self.emulator_instance is None: if self.emulator_instance is None:
logger.error('Unable to use NemuIpc because emulator instance not found') logger.error('Unable to use NemuIpc because emulator instance not found')
raise RequestHumanTakeover raise RequestHumanTakeover
if 'MuMuPlayerGlobal' in self.emulator_instance.path:
logger.info(f'nemu_ipc is not available on MuMuPlayerGlobal, {self.emulator_instance.path}')
raise RequestHumanTakeover
try: try:
return NemuIpcImpl( return NemuIpcImpl(
nemu_folder=self.emulator_instance.emulator.abspath('../'), nemu_folder=self.emulator_instance.emulator.abspath('../'),