Skip to content

Commit 4b85d18

Browse files
authored
Merge pull request #5118 from LmeSzinc/dev
Bug fix
2 parents 7a578ea + 327eb2f commit 4b85d18

4 files changed

Lines changed: 6 additions & 4 deletions

File tree

assets/jp/shop/SHOP_REFRESH.png

-5.09 KB
Loading

module/device/connection.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,8 @@ def is_bluestacks_air(self):
318318
# BlueStacks Air is the Mac version of BlueStacks
319319
if not IS_MACINTOSH:
320320
return False
321-
if not self.is_ldplayer_bluestacks_family:
321+
# 127.0.0.1:5555 + 10*n, assume 32 instances at max
322+
if not (5555 <= self.port <= 5875):
322323
return False
323324
# [bst.installed_images]: [Tiramisu64]
324325
# [bst.instance]: [Tiramisu64]

module/device/connection_attr.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ def port(self) -> int:
165165

166166
@cached_property
167167
def is_mumu12_family(self):
168-
# 127.0.0.1:16XXX
168+
# 127.0.0.1:16384 + 32*n, assume 32 instances at max
169169
return 16384 <= self.port <= 17408
170170

171171
@cached_property
@@ -177,7 +177,8 @@ def is_mumu_family(self):
177177
@cached_property
178178
def is_ldplayer_bluestacks_family(self):
179179
# Note that LDPlayer and BlueStacks have the same serial range
180-
return self.serial.startswith('emulator-') or 5555 <= self.port <= 5587
180+
# 127.0.0.1:5555 + 2*n, assume 32 instances at max
181+
return self.serial.startswith('emulator-') or 5555 <= self.port <= 5619
181182

182183
@cached_property
183184
def is_nox_family(self):

module/shop/assets.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
SHOP_OCR_OIL = Button(area={'cn': (700, 23, 785, 47), 'en': (863, 24, 955, 46), 'jp': (700, 23, 785, 47), 'tw': (700, 23, 785, 47)}, color={'cn': (150, 185, 194), 'en': (150, 183, 189), 'jp': (150, 185, 194), 'tw': (150, 185, 194)}, button={'cn': (700, 23, 785, 47), 'en': (863, 24, 955, 46), 'jp': (700, 23, 785, 47), 'tw': (700, 23, 785, 47)}, file={'cn': './assets/cn/shop/SHOP_OCR_OIL.png', 'en': './assets/en/shop/SHOP_OCR_OIL.png', 'jp': './assets/cn/shop/SHOP_OCR_OIL.png', 'tw': './assets/cn/shop/SHOP_OCR_OIL.png'})
3333
SHOP_OCR_OIL_CHECK = Button(area={'cn': (666, 30, 682, 43), 'en': (834, 25, 854, 45), 'jp': (666, 30, 682, 43), 'tw': (666, 30, 682, 43)}, color={'cn': (73, 73, 73), 'en': (71, 75, 75), 'jp': (73, 73, 73), 'tw': (73, 73, 73)}, button={'cn': (666, 30, 682, 43), 'en': (834, 25, 854, 45), 'jp': (666, 30, 682, 43), 'tw': (666, 30, 682, 43)}, file={'cn': './assets/cn/shop/SHOP_OCR_OIL_CHECK.png', 'en': './assets/en/shop/SHOP_OCR_OIL_CHECK.png', 'jp': './assets/cn/shop/SHOP_OCR_OIL_CHECK.png', 'tw': './assets/cn/shop/SHOP_OCR_OIL_CHECK.png'})
3434
SHOP_PROTOTYPE_SWIPE_END = Button(area={'cn': (1135, 660, 1215, 678), 'en': (1101, 658, 1215, 676), 'jp': (1097, 660, 1199, 678), 'tw': (1135, 660, 1215, 678)}, color={'cn': (136, 137, 139), 'en': (111, 112, 115), 'jp': (86, 87, 91), 'tw': (136, 137, 139)}, button={'cn': (1135, 660, 1215, 678), 'en': (1101, 658, 1215, 676), 'jp': (1097, 660, 1199, 678), 'tw': (1135, 660, 1215, 678)}, file={'cn': './assets/cn/shop/SHOP_PROTOTYPE_SWIPE_END.png', 'en': './assets/en/shop/SHOP_PROTOTYPE_SWIPE_END.png', 'jp': './assets/jp/shop/SHOP_PROTOTYPE_SWIPE_END.png', 'tw': './assets/cn/shop/SHOP_PROTOTYPE_SWIPE_END.png'})
35-
SHOP_REFRESH = Button(area={'cn': (950, 660, 1003, 684), 'en': (950, 660, 1003, 684), 'jp': (1161, 162, 1270, 206), 'tw': (1161, 162, 1270, 206)}, color={'cn': (73, 164, 221), 'en': (73, 164, 221), 'jp': (178, 142, 84), 'tw': (179, 143, 88)}, button={'cn': (950, 660, 1003, 684), 'en': (950, 660, 1003, 684), 'jp': (1161, 162, 1270, 206), 'tw': (1161, 162, 1270, 206)}, file={'cn': './assets/cn/shop/SHOP_REFRESH.png', 'en': './assets/en/shop/SHOP_REFRESH.png', 'jp': './assets/jp/shop/SHOP_REFRESH.png', 'tw': './assets/tw/shop/SHOP_REFRESH.png'})
35+
SHOP_REFRESH = Button(area={'cn': (950, 660, 1003, 684), 'en': (950, 660, 1003, 684), 'jp': (950, 660, 1003, 684), 'tw': (1161, 162, 1270, 206)}, color={'cn': (73, 164, 221), 'en': (73, 164, 221), 'jp': (73, 164, 221), 'tw': (179, 143, 88)}, button={'cn': (950, 660, 1003, 684), 'en': (950, 660, 1003, 684), 'jp': (950, 660, 1003, 684), 'tw': (1161, 162, 1270, 206)}, file={'cn': './assets/cn/shop/SHOP_REFRESH.png', 'en': './assets/en/shop/SHOP_REFRESH.png', 'jp': './assets/jp/shop/SHOP_REFRESH.png', 'tw': './assets/tw/shop/SHOP_REFRESH.png'})
3636
SHOP_SELECT_PR1 = Button(area={'cn': (182, 212, 308, 339), 'en': (182, 212, 308, 339), 'jp': (182, 212, 308, 339), 'tw': (182, 212, 308, 339)}, color={'cn': (157, 158, 143), 'en': (157, 158, 143), 'jp': (157, 158, 143), 'tw': (157, 158, 143)}, button={'cn': (182, 212, 308, 339), 'en': (182, 212, 308, 339), 'jp': (182, 212, 308, 339), 'tw': (182, 212, 308, 339)}, file={'cn': './assets/cn/shop/SHOP_SELECT_PR1.png', 'en': './assets/en/shop/SHOP_SELECT_PR1.png', 'jp': './assets/jp/shop/SHOP_SELECT_PR1.png', 'tw': './assets/tw/shop/SHOP_SELECT_PR1.png'})
3737
SHOP_SELECT_PR2 = Button(area={'cn': (182, 212, 310, 340), 'en': (182, 212, 310, 340), 'jp': (182, 212, 310, 340), 'tw': (182, 212, 310, 340)}, color={'cn': (160, 159, 145), 'en': (160, 159, 145), 'jp': (160, 159, 145), 'tw': (160, 159, 145)}, button={'cn': (182, 212, 310, 340), 'en': (182, 212, 310, 340), 'jp': (182, 212, 310, 340), 'tw': (182, 212, 310, 340)}, file={'cn': './assets/cn/shop/SHOP_SELECT_PR2.png', 'en': './assets/en/shop/SHOP_SELECT_PR2.png', 'jp': './assets/jp/shop/SHOP_SELECT_PR2.png', 'tw': './assets/tw/shop/SHOP_SELECT_PR2.png'})
3838
SHOP_SELECT_PR3 = Button(area={'cn': (180, 212, 309, 340), 'en': (180, 212, 309, 340), 'jp': (180, 212, 309, 340), 'tw': (180, 212, 309, 340)}, color={'cn': (156, 156, 142), 'en': (156, 156, 142), 'jp': (156, 156, 142), 'tw': (156, 156, 142)}, button={'cn': (180, 212, 309, 340), 'en': (180, 212, 309, 340), 'jp': (180, 212, 309, 340), 'tw': (180, 212, 309, 340)}, file={'cn': './assets/cn/shop/SHOP_SELECT_PR3.png', 'en': './assets/en/shop/SHOP_SELECT_PR3.png', 'jp': './assets/jp/shop/SHOP_SELECT_PR3.png', 'tw': './assets/tw/shop/SHOP_SELECT_PR3.png'})

0 commit comments

Comments
 (0)