New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
养成出现选项时,在终端选择时出错 #85
Comments
你的single_mode_choices.json 格式不对 |
是文件格式的问题吗 |
没有找到匹配的项 |
https://github.com/NateScarlet/auto-derby#%E9%97%AE%E9%A2%98%E5%8F%8D%E9%A6%88 在 launcher.log 里面找你的数据路径 然后把 single_mode_choices.json 发上来
|
# -*- coding=UTF-8 -*-
# pyright: strict
import json import cv2 LOGGER = logging.getLogger(name) class g: def reload() -> None: def _save() -> None: def get(event_screen: Image) -> int:
|
你确定你的.json 是个python 脚本? |
launcher.log 发一下 |
Windows PowerShell 脚本开始 已启动脚本,输出文件为 C:\Users\WisdomDevil\Desktop\auto-derby-master\launcher.log Job : nurturing command: Windows PowerShell 脚本结束 |
json格式的只找到了single_mode_races |
因为 single_mode_choices 是自动创建的 你把single_mode_races 还原 然后指定一个别的路径或者用默认路径 |
在哪里指定呢? |
启动器上面不是有选择 python 下面那个 |
这个明显是你手动改了 默认设置就是好的 然后你现在问我在哪改…… |
抱歉......我还原一下 |
还原了还是不行 |
single mode choices的默认路径就是C:\Users\WisdomDevil\Desktop\auto-derby-master\single_mode_races.json |
默认路径是你把它清空之后的路径 启动器会记住你的设置 |
你手动打字改成 single_mode_choices.json 也行 |
可以了! |
Choose event option(1/2/3/4/5):3
ERROR [12:55:28]:main:119: unexpected exception
Traceback (most recent call last):
File "C:\Users\WisdomDevil\Desktop\auto-derby-master\auto_derby_main_.py", line 115, in
main()
File "C:\Users\WisdomDevil\Desktop\auto-derby-master\auto_derby_main_.py", line 87, in main
job()
File "C:\Users\WisdomDevil\Desktop\auto-derby-master\auto_derby\jobs\nurturing.py", line 326, in nurturing
_handle_option()
File "C:\Users\WisdomDevil\Desktop\auto-derby-master\auto_derby\jobs\nurturing.py", line 241, in _handle_option
ans = choice.get(template.screenshot())
File "C:\Users\WisdomDevil\Desktop\auto-derby-master\auto_derby\single_mode\choice.py", line 80, in get
g.choices[event_id] = int(ans)
TypeError: list indices must be integers or slices, not str
以上为错误信息
The text was updated successfully, but these errors were encountered: