LmeSzinc / StarRailCopilot

崩坏:星穹铁道脚本 | Honkai: Star Rail auto bot (简体中文/繁體中文/English/Español)
GNU General Public License v3.0
3.17k stars 158 forks source link

在选择服务器界面启动调度器后无法正常进入游戏 #214

Open aaahai00 opened 11 months ago

aaahai00 commented 11 months ago

在提问之前...

描述你的问题

Screenshot_20231208-004148在这张截图的页面时启动调度器,src会正常点击继续,但是稍后便会报错停止(具体时间是到出现进入游戏界面之前几秒)

如何复现

在选择服务器界面启动调度器 (后期测试:发现实际上和哪个界面里启动无关,只是因为游戏不是src启动的所以没有使用正常的打开游戏进程而已)

预期行为

正常进入游戏,或直接重启游戏而不是直接报错

相关 Logs

═══════════════════════════════════════════════════════════════════════════════════════════════════════════════════════
                                                         START                                                         
═══════════════════════════════════════════════════════════════════════════════════════════════════════════════════════
2023-12-08 00:32:37.993 | INFO | Start scheduler loop: 134                                                             
2023-12-08 00:32:37.996 | INFO | [Lang] cn                                                                             
2023-12-08 00:32:38.001 | INFO | Bind task ['Alas', 'Alas']                                                            
2023-12-08 00:32:38.002 | INFO | No task pending                                                                       
2023-12-08 00:32:38.004 | INFO | [Task] Restart (Enable, 2023-12-08 04:00:00)                                          
2023-12-08 00:32:38.005 | INFO | Bind task ['Alas', 'Restart']                                                         
2023-12-08 00:32:38.007 | INFO | Wait until 2023-12-08 04:00:00 for task `Restart`                                     
2023-12-08 00:32:38.008 | INFO | Goto main page during wait                                                            
═══════════════════════════════════════════════════════ DEVICE ════════════════════════════════════════════════════════
2023-12-08 00:32:39.334 | INFO | DEVICE                                                                                
2023-12-08 00:32:39.346 | INFO | [AdbBinary] D:\StarRailCopilot\toolkit\Lib\site-packages\adbutils\binaries\adb.exe    
2023-12-08 00:32:39.348 | INFO | [AdbClient] AdbClient(127.0.0.1, 5037)                                                
2023-12-08 00:32:39.349 | INFO | <<< DETECT DEVICE >>>                                                                 
2023-12-08 00:32:39.350 | INFO | Here are the available devices, copy to Alas.Emulator.Serial to use it or set         
Alas.Emulator.Serial="auto"                                                                                            
2023-12-08 00:32:39.351 | INFO | 127.0.0.1:5555                                                                        
2023-12-08 00:32:39.353 | INFO | emulator-5554                                                                         
2023-12-08 00:32:39.356 | INFO | already connected to 127.0.0.1:5555                                                   
2023-12-08 00:32:39.357 | INFO | [AdbDevice] AdbDevice(serial=127.0.0.1:5555)                                          
2023-12-08 00:32:39.357 | INFO | [Server] CN-Official                                                                  
2023-12-08 00:32:39.358 | INFO | [PackageName] com.miHoYo.hkrpg                                                        
2023-12-08 00:32:39.359 | INFO | [Lang] cn                                                                             
2023-12-08 00:32:39.398 | INFO | [u2.Device] Device(atx_agent_url=http://127.0.0.1:6473)                               
2023-12-08 00:32:39.431 | INFO | [Device Orientation] 1 (HOME key on the right)                                        
2023-12-08 00:32:39.433 | INFO | [Screen_size] 1280x720                                                                
2023-12-08 00:32:39.434 | INFO | <<< SCRCPY SERVER START >>>                                                           
2023-12-08 00:32:39.437 | INFO | Create server stream                                                                  
2023-12-08 00:32:39.851 | INFO | b'[server] INFO: Device: Xiaomi 2203121C (Android 9)\n'                               
2023-12-08 00:32:39.853 | INFO | Create video socket                                                                   
2023-12-08 00:32:39.960 | INFO | Create control socket                                                                 
2023-12-08 00:32:39.962 | INFO | Fetch device info                                                                     
2023-12-08 00:32:39.963 | INFO | [Scrcpy Device] 2203121C                                                              
2023-12-08 00:32:39.964 | INFO | [Scrcpy Resolution] (1280, 720)                                                       
2023-12-08 00:32:39.964 | INFO | Start video stream loop thread                                                        
2023-12-08 00:32:39.966 | INFO | Scrcpy server is up                                                                   
2023-12-08 00:32:40.184 | INFO | [Screen_size] 1280x720                                                                
2023-12-08 00:32:40.432 | INFO | [Package_name] com.miHoYo.hkrpg                                                       
2023-12-08 00:32:40.435 | INFO | App is already running, goto main page                                                
2023-12-08 00:32:40.436 | INFO | <<< UI ENSURE >>>                                                                     
2023-12-08 00:32:40.437 | INFO | UI get current page                                                                   
2023-12-08 00:32:40.626 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:40.721 | INFO | Click ( 813,  425) @ LOGIN_CONFIRM                                                    
2023-12-08 00:32:40.722 | INFO | <<< MAATOUCH INIT >>>                                                                 
2023-12-08 00:32:40.852 | INFO | ^ 10 1280 720 255                                                                     
2023-12-08 00:32:40.853 | INFO | $ 255                                                                                 
2023-12-08 00:32:40.854 | INFO | MaaTouch stream connected                                                             
2023-12-08 00:32:40.856 | INFO | max_contact: 10; max_x: 1280; max_y: 720; max_pressure: 255                           
2023-12-08 00:32:40.982 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.020 | INFO | [Package_name] com.miHoYo.hkrpg                                                       
2023-12-08 00:32:41.033 | INFO | [Device Orientation] 1 (HOME key on the right)                                        
2023-12-08 00:32:41.080 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.178 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.278 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.375 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.493 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.583 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.688 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.791 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.878 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:41.979 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.083 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.177 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.276 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.387 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.485 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.581 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.675 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.775 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:42.881 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.023 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.092 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.185 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.293 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.390 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.480 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.592 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.688 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.791 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.896 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:43.995 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.093 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.195 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.296 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.398 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.499 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.603 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.705 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.787 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:44.893 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.053 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.162 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.196 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.295 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.457 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.557 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.661 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.761 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.861 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:45.959 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:46.067 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:46.161 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:46.261 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:46.365 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:46.462 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:46.564 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.150 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.221 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.311 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.404 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.545 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.641 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.745 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.844 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:47.945 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.045 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.145 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.246 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.348 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.441 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.496 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.658 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.730 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.778 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.928 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:48.983 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.108 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.209 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.313 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.412 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.513 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.625 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.717 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.816 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.918 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:49.992 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.095 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.298 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.381 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.497 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.589 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.681 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.817 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.881 | INFO | Unknown ui page                                                                       
2023-12-08 00:32:50.989 | WARNING | Unknown ui page                                                                    
2023-12-08 00:32:50.990 | INFO | [EMULATOR__SCREENSHOT_METHOD] scrcpy                                                  
2023-12-08 00:32:50.991 | INFO | [EMULATOR__CONTROL_METHOD] MaaTouch                                                   
2023-12-08 00:32:50.991 | INFO | [Lang] cn                                                                             
2023-12-08 00:32:50.993 | WARNING | Starting from current page is not supported                                        
2023-12-08 00:32:50.993 | WARNING | Supported page: ['page_main', 'page_menu', 'page_character', 'page_team',          
'page_item', 'page_guide', 'page_gacha', 'page_battle_pass', 'page_event', 'page_map', 'page_world', 'page_tutorial',  
'page_mission', 'page_message', 'page_camera', 'page_synthesize', 'page_assignment', 'page_forgotten_hall',            
'page_rogue']                                                                                                          
2023-12-08 00:32:50.994 | WARNING | Supported page: Any page with a "HOME" button on the upper-right                   
2023-12-08 00:32:50.995 | CRITICAL | Please switch to a supported page before starting SRC                             
2023-12-08 00:32:50.997 | INFO | Game server may be under maintenance or network may be broken, check server status now
2023-12-08 00:32:50.998 | CRITICAL | Game page unknown                                                                 
2023-12-08 00:32:51.001 | WARNING | Saving error: ./log/error/1701966771001

截图

2023-12-08_00-32-50-989119 (程序截图)

还有别的吗?

这问题也许并不局限于打开游戏,可能只要是src无法识别的页面就会引发该错误,但直接报错不应该,这种情况就直接关闭游戏,再重新打开游戏就好了,而不是直接报错(除非多次启动无法排除问题) 我理解适配其他页面费时费力且没有必要,所以直接重启游戏就好了

aaahai00 commented 11 months ago

补充说明:其实大概跟在哪里启动无关,只要游戏本身不是由src启动的(除非手动进入游戏)不然过一会就会引发报错(虽然他仍然会帮你点,就很怪)

PacaPop commented 11 months ago

Both me and my GF have the same issue. SRC doesn't automatically tap on the screen neither in the server selection UI nor when the train is entering and you have to tap again to enter the game.

aaahai00 commented 11 months ago

Both me and my GF have the same issue. SRC doesn't automatically tap on the screen neither in the server selection UI nor when the train is entering and you have to tap again to enter the game.

Is this the case even if the game process is started by src? (I only need to shut down the game process and start src to avoid this problem) (Content is machine translated)