From 7db4fae884923a40d59258fa18adfe7ce2518430 Mon Sep 17 00:00:00 2001 From: LmeSzinc <37934724+LmeSzinc@users.noreply.github.com> Date: Mon, 6 Feb 2023 09:19:52 +0800 Subject: [PATCH 1/2] Add: [TW] The Enigma and the Shark Rerun --- campaign/Readme.md | 3 ++- module/config/argument/args.json | 32 ++++++++++++++++---------------- module/config/i18n/en-US.json | 2 +- module/config/i18n/ja-JP.json | 2 +- module/config/i18n/zh-CN.json | 2 +- module/config/i18n/zh-TW.json | 2 +- 6 files changed, 22 insertions(+), 21 deletions(-) diff --git a/campaign/Readme.md b/campaign/Readme.md index 6f44306cf..5afcce065 100644 --- a/campaign/Readme.md +++ b/campaign/Readme.md @@ -127,4 +127,5 @@ To add a new event, add a new row in here, and run `python -m module.config.conf | 20230105 | event 20210225 cn | Khorovod of Dawn's Rime | 复刻破晓冰华 | Khorovod of Dawn's Rime Rerun | 暁射す氷華の嵐(復刻) | - | | 20230105 | event 20210610 tw | The Way Home in the Night | - | - | - | 復刻夜幕下的歸途 | | 20230118 | raid 20230118 | Winter Pathfinder | 冬日的寻路人 | Winter Pathfinder | 冬の案内人 | - | -| 20220127 | raid 20220127 | - | - | - | - | 演習神秘事件調查 | +| 20230118 | raid 20220127 | - | - | - | - | 演習神秘事件調查 | +| 20230202 | event 20200806 cn | The Enigma and the Shark | - | - | - | 復刻最重要的寶物 | diff --git a/module/config/argument/args.json b/module/config/argument/args.json index c34d4e2a0..6ad3cc265 100644 --- a/module/config/argument/args.json +++ b/module/config/argument/args.json @@ -1575,6 +1575,7 @@ "value": "campaign_main", "option": [ "campaign_main", + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -1609,7 +1610,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -1631,7 +1631,7 @@ "event_20200227_cn" ], "display": "hide", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" @@ -2015,6 +2015,7 @@ "type": "select", "value": "campaign_main", "option": [ + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -2049,7 +2050,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -2071,7 +2071,7 @@ "event_20200227_cn" ], "display": "disabled", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" @@ -2446,6 +2446,7 @@ "type": "select", "value": "campaign_main", "option": [ + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -2480,7 +2481,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -2502,7 +2502,7 @@ "event_20200227_cn" ], "display": "disabled", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" @@ -2888,6 +2888,7 @@ "type": "select", "value": "campaign_main", "option": [ + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -2922,7 +2923,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -2944,7 +2944,7 @@ "event_20200227_cn" ], "display": "disabled", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" @@ -3336,6 +3336,7 @@ "type": "select", "value": "campaign_main", "option": [ + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -3370,7 +3371,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -3392,7 +3392,7 @@ "event_20200227_cn" ], "display": "disabled", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" @@ -3784,6 +3784,7 @@ "type": "select", "value": "campaign_main", "option": [ + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -3818,7 +3819,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -3840,7 +3840,7 @@ "event_20200227_cn" ], "display": "disabled", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" @@ -4232,6 +4232,7 @@ "type": "select", "value": "campaign_main", "option": [ + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -4266,7 +4267,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -4288,7 +4288,7 @@ "event_20200227_cn" ], "display": "disabled", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" @@ -4670,6 +4670,7 @@ "type": "select", "value": "campaign_main", "option": [ + "event_20200806_cn", "event_20210610_tw", "event_20210225_cn", "event_20211229_cn", @@ -4704,7 +4705,6 @@ "event_20211028_tw", "event_20210722_cn", "event_20210819_cn", - "event_20200806_cn", "event_20200723_cn", "event_20210624_cn", "event_20210624_tw", @@ -4726,7 +4726,7 @@ "event_20200227_cn" ], "display": "disabled", - "tw": "event_20210610_tw", + "tw": "event_20200806_cn", "cn": "event_20210225_cn", "en": "event_20210225_cn", "jp": "event_20210225_cn" diff --git a/module/config/i18n/en-US.json b/module/config/i18n/en-US.json index 2e593490b..518c65ccc 100644 --- a/module/config/i18n/en-US.json +++ b/module/config/i18n/en-US.json @@ -614,6 +614,7 @@ "name": "Event Name", "help": "Automatically selects to the latest event", "campaign_main": "campaign_main", + "event_20200806_cn": "The Enigma and the Shark Rerun", "raid_20220127": "Mystery Investigation", "raid_20230118": "Winter Pathfinder", "event_20210610_tw": "復刻夜幕下的歸途", @@ -654,7 +655,6 @@ "event_20211028_tw": "復刻光與影的鳶尾之華", "event_20210722_cn": "Azur Anthem", "event_20210819_cn": "Microlayer Medley Rerun", - "event_20200806_cn": "The Enigma and the Shark Rerun", "event_20200723_cn": "Aurora Noctis", "event_20210624_cn": "Swirling Cherry Blossoms Rerun", "event_20210624_tw": "穹頂下的聖詠曲", diff --git a/module/config/i18n/ja-JP.json b/module/config/i18n/ja-JP.json index b015c099b..64235b4bf 100644 --- a/module/config/i18n/ja-JP.json +++ b/module/config/i18n/ja-JP.json @@ -614,6 +614,7 @@ "name": "Campaign.Event.name", "help": "Campaign.Event.help", "campaign_main": "campaign_main", + "event_20200806_cn": "鉄血鮫とエニグマ(復刻)", "raid_20220127": "秘密事件調査", "raid_20230118": "冬の案内人", "event_20210610_tw": "復刻夜幕下的歸途", @@ -654,7 +655,6 @@ "event_20211028_tw": "復刻光與影的鳶尾之華", "event_20210722_cn": "海に響くアイドルの歌", "event_20210819_cn": "闇靄払う銀翼(復刻)", - "event_20200806_cn": "鉄血鮫とエニグマ(復刻)", "event_20200723_cn": "極夜照らす幻光", "event_20210624_cn": "翳りし満ちる影の華(復刻)", "event_20210624_tw": "穹頂下的聖詠曲", diff --git a/module/config/i18n/zh-CN.json b/module/config/i18n/zh-CN.json index afdc6aa31..4d350cc4c 100644 --- a/module/config/i18n/zh-CN.json +++ b/module/config/i18n/zh-CN.json @@ -614,6 +614,7 @@ "name": "活动名称", "help": "自动选择至最新的活动", "campaign_main": "主线图", + "event_20200806_cn": "复刻最重要的宝物", "raid_20220127": "演习神秘事件调查", "raid_20230118": "冬日的寻路人", "event_20210610_tw": "復刻夜幕下的歸途", @@ -654,7 +655,6 @@ "event_20211028_tw": "復刻光與影的鳶尾之華", "event_20210722_cn": "响彻碧海的偶像歌", "event_20210819_cn": "复刻微层混合", - "event_20200806_cn": "复刻最重要的宝物", "event_20200723_cn": "永夜幻光", "event_20210624_cn": "复刻浮樱影华", "event_20210624_tw": "穹頂下的聖詠曲", diff --git a/module/config/i18n/zh-TW.json b/module/config/i18n/zh-TW.json index a91aa7597..a01cd4c40 100644 --- a/module/config/i18n/zh-TW.json +++ b/module/config/i18n/zh-TW.json @@ -614,6 +614,7 @@ "name": "活動名稱", "help": "自動選擇至最新的活動圖", "campaign_main": "主線圖", + "event_20200806_cn": "復刻最重要的寶物", "raid_20220127": "演習神秘事件調查", "raid_20230118": "Winter Pathfinder", "event_20210610_tw": "復刻夜幕下的歸途", @@ -654,7 +655,6 @@ "event_20211028_tw": "復刻光與影的鳶尾之華", "event_20210722_cn": "響徹碧海的偶像歌", "event_20210819_cn": "Microlayer Medley Rerun", - "event_20200806_cn": "最重要的寶物", "event_20200723_cn": "永夜幻光", "event_20210624_cn": "Swirling Cherry Blossoms Rerun", "event_20210624_tw": "穹頂下的聖詠曲", From b45149e28373f211bfab5f5864a050c7cff3cda7 Mon Sep 17 00:00:00 2001 From: Azusa Nakano Date: Wed, 8 Feb 2023 14:28:23 +1100 Subject: [PATCH 2/2] Add support for Bluestacks 5 Pie64 instances Fix #2188 by matching either Nougat64 or Pie64 at the same time. Note that this creates a problem such that when first Nougat64 and Pie64 co-exists, the engine would fail to match Pie64. --- module/device/connection_attr.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/module/device/connection_attr.py b/module/device/connection_attr.py index 33ed41e4e..850e83e97 100644 --- a/module/device/connection_attr.py +++ b/module/device/connection_attr.py @@ -179,9 +179,9 @@ class ConnectionAttr: logger.info("Reading Realtime adb port") if serial == "bluestacks5-hyperv": - parameter_name = r"bst\.instance\.Nougat64\.status\.adb_port" + parameter_name = r"bst\.instance\.(Nougat64|Pie64)\.status\.adb_port" else: - parameter_name = rf"bst\.instance\.Nougat64_{serial[19:]}\.status.adb_port" + parameter_name = rf"bst\.instance\.(Nougat64|Pie64)_{serial[19:]}\.status.adb_port" try: with OpenKey(HKEY_LOCAL_MACHINE, r"SOFTWARE\BlueStacks_nxt") as key: @@ -203,7 +203,7 @@ class ConnectionAttr: if port is None: logger.warning(f"Did not match the result: {serial}.") raise RequestHumanTakeover - port = port.group(1) + port = port.group(2) logger.info(f"Match to dynamic port: {port}") return f"127.0.0.1:{port}"