Skip to content
This repository has been archived by the owner on Dec 27, 2024. It is now read-only.

Commit

Permalink
feat(single-mode): change race algorithm
Browse files Browse the repository at this point in the history
  • Loading branch information
NateScarlet committed Jun 16, 2021
1 parent 56032df commit 6373dae
Show file tree
Hide file tree
Showing 5 changed files with 261 additions and 83 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@
- [x] 遇到新事件选项请求人工处理,后续相同事件使用相同选择
- [x] 自动参加比赛
- [x] 预估比赛结果,如果不能仅靠属性拿冠军则暂停请求人工确认
- [x] 根据属性和适性自动选择比赛跑法(非长距离或者低等级赛事倾向逃)
- [x] 自动选择比赛跑法
- [x] 基于属性和适性
- [ ] 基于对手跑法选择跑法(倾向人数少的跑法)
- [ ] 支持友人卡(在实现前可以带友人卡,就是外出时需要自己手动选)

## 使用方法
Expand Down
6 changes: 3 additions & 3 deletions auto_derby/jobs/nurturing.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# -*- coding=UTF-8 -*-
# pyright: strict
from __future__ import annotations
from auto_derby import mathtools

import logging
import time
from typing import List, Optional

from auto_derby import mathtools

from .. import action, template, templates, window
from ..single_mode import Context, Training, choice, race


LOGGER = logging.getLogger(__name__)


Expand All @@ -34,7 +34,7 @@ def _current_race(ctx: Context) -> race.Race:

def _choose_race(ctx: Context, race1: race.Race) -> None:
rp = action.resize_proxy()
action.wheel(rp.vector2((100, 500), 466), 1)
action.wheel(rp.vector2((100, 500), 466), 10)
action.click(rp.vector2((100, 500), 466))

if _current_race(ctx) == race1:
Expand Down
Loading

0 comments on commit 6373dae

Please sign in to comment.