jbcaaa
|
3b8b1ef9db
|
Update PathExecutor.cs
|
2024-10-18 00:48:57 +08:00 |
|
jbcaaa
|
a4bb2eeca2
|
changed some value
|
2024-10-18 00:23:26 +08:00 |
|
jbcaaa
|
f222431784
|
[testing] madly modified move actions in autopathing
|
2024-10-17 21:15:58 +08:00 |
|
jbcaaa
|
561f1b8b72
|
Support using both key-mouse-record and auto-pathing in js scripts
|
2024-10-17 16:04:27 +08:00 |
|
辉鸭蛋
|
4859c4dc4a
|
add log & pathing opt
|
2024-10-16 01:31:44 +08:00 |
|
辉鸭蛋
|
c4a7823c83
|
fix js pathingScript
|
2024-10-13 22:58:42 +08:00 |
|
辉鸭蛋
|
50aac5cea0
|
auto pathing opt
|
2024-10-13 22:12:07 +08:00 |
|
辉鸭蛋
|
228d50bb5d
|
Revert "feat: 优化autopath MoveTo逻辑"
This reverts commit 504f853893.
|
2024-10-13 21:09:41 +08:00 |
|
gqzcl
|
504f853893
|
feat: 优化autopath MoveTo逻辑
|
2024-10-05 14:04:20 +08:00 |
|
辉鸭蛋
|
c15cb33c2c
|
rename variables and properties, refactor code, add new configuration options
重命名变量和属性,重构代码,添加新配置选项
主要更改:
* 将 `AutoFightConfig` 和 `AutoFightParam` 类中的字段和属性重命名,以提高名称的清晰度和一致性。
* 移除不必要的 `using` 语句,并调整顺序。
* 重构 `AutoFightTask` 和 `AutoFightHandler` 类中的条件判断和方法逻辑。
* 调整 `CameraRotateTask` 类中的参数值。
* 在 `PathExecutor` 类中添加 `_rotateTask` 字段,并修改相关方法调用。
* 在 `TaskSettingsPage.xaml` 中添加新的配置选项。
* 在 `HotKeyPageViewModel` 类中添加 `using` 语句,并修改热键回调逻辑。
* 修改 `TaskSettingsPageViewModel` 类中 `AutoFightParam` 的初始化。
|
2024-09-30 13:42:11 +08:00 |
|
辉鸭蛋
|
d9e5f2f1dd
|
add rotate task
在 `BgiYoloV8Predictor.cs` 文件中,添加了 `System.Diagnostics`、`System.Drawing.Imaging` 和 `System.IO` 的引用,并在 YOLOv8 识别结果返回前,添加了调试输出,使用 `JsonSerializer` 序列化识别结果并输出到调试窗口。
在 `AutoFightTask.cs` 文件中,添加了 `System.Collections.Generic` 和 `BetterGenshinImpact.GameTask.AutoPathing` 的引用,修改了 `combatScenes.BeforeTask` 方法的调用,使用新的取消令牌 `cts2`。在战斗操作的 `Task.Run` 中添加了 `try-catch` 块,以捕获并忽略异常。修改了战斗结束检测线程,使用 `async` 和 `await` 关键字,并在检测战斗结束时添加了 `try-catch` 块。修改了 `CheckFightFinish` 方法,改为异步方法 `CheckFightFinish`,并在检测战斗结束时添加了旋转视角的逻辑。
在 `PathExecutor.cs` 文件中,添加了关于 DPI 和分辨率影响转动速度的注释。
在 `TaskSettingsPageViewModel.cs` 文件中,在获取战斗策略后,创建了 `AutoFightParam` 对象,并设置了 `EndDetect` 和 `AutoPickAfterFight` 参数。修改了 `RunSoloTaskAsync` 方法的调用,传入了新的 `AutoFightParam` 对象。
在 `CameraRotateTask.cs` 文件中,添加了新的 `CameraRotateTask` 类,用于处理相机视角的旋转,实现了 `RotateToApproach` 方法,用于将视角旋转到接近目标角度,实现了 `WaitUntilRotatedTo` 异步方法,用于等待视角旋转到目标角度。
|
2024-09-30 00:10:08 +08:00 |
|
何杰泽
|
997059dd4b
|
添加fight action。战斗结束策略比较low。
|
2024-09-21 15:56:37 +08:00 |
|
辉鸭蛋
|
70b1ed88bb
|
auto pathing: add nahida_collect action
新增 Action 处理机制及相关类和方法
删除了 `PickHandler` 类及其相关的 `Obsolete` 特性。
在 `ActionEnum` 类中新增了两个静态只读字段:`NahidaCollect` 和 `PickAround`。
在 `PathExecutor` 类中引入了 `BetterGenshinImpact.GameTask.AutoPathing.Handler` 命名空间。
在 `PathExecutor` 类的 `MoveTo` 方法中,添加了一个调用 `AfterMoveToTarget` 方法的步骤,用于在到达点位后执行特定的动作。
在 `PathExecutor` 类中,修改了疑似卡死时的延迟时间,从 500 毫秒增加到 1500 毫秒。
在 `PathExecutor` 类中新增了 `AfterMoveToTarget` 方法,用于根据 `waypoint.Action` 执行相应的处理逻辑。
新增了 `ActionFactory` 类,用于根据 `handlerType` 获取相应的 `IActionHandler` 实例。
新增了 `IActionHandler` 接口,定义了 `RunAsync` 方法。
新增了 `NahidaCollectHandler` 类,实现了 `IActionHandler` 接口,用于执行纳西妲的收集操作。
新增了 `PickAroundHandler` 类,实现了 `IActionHandler` 接口,暂时未实现具体的拾取操作逻辑。
|
2024-09-19 00:36:14 +08:00 |
|
辉鸭蛋
|
5f9ca6b399
|
auto pathing: add force tp for tp point
|
2024-09-17 15:06:32 +08:00 |
|
辉鸭蛋
|
4cc4aa27f0
|
fix path recorder
|
2024-09-16 21:31:40 +08:00 |
|
辉鸭蛋
|
3e69e6c3ac
|
fix map pos not reset during feature match #619
|
2024-09-16 21:15:59 +08:00 |
|
辉鸭蛋
|
a06f0fcdb2
|
auto pathing: fix not releasing the mouse and keyboard when stopping tasks
更新日志和黑名单
移除 `PathExecutor.cs` 中的无用引用,重构 `Pathing` 方法,添加 `InitializePathing` 和 `ConvertWaypoints` 方法,提取传送点处理逻辑到 `HandleTeleportWaypoint` 方法。修改 `TpTask.cs` 中的日志格式为浮点数格式。将 `TaskRunner.cs` 中的 `FireAndForgetAsync` 方法重命名为 `RunThreadAsync`,并在 `ScriptService.cs` 中相应替换调用。为 `DpiHelper.cs` 中的 `ScaleY` 属性添加注释。更新 `pick_black_lists.json`,添加新的黑名单项 `"摆放巧像"`。在 `MapPathingViewModel.cs` 中添加 `_mapViewer` 字段,并在 `OnOpenMapViewer` 方法中使用。
|
2024-09-09 21:57:48 +08:00 |
|
辉鸭蛋
|
220d6a4f9b
|
fix multi thread ui bug & rotate with dpi
优化 DPI 处理和异步任务执行
在 `PathExecutor.cs` 中,添加了对 `BetterGenshinImpact.Helpers` 的引用,并引入了 `DpiHelper` 来调整 `_dpi` 变量。
在 `PathExecutor` 类中,添加了 `_dpi` 变量,并在 `Pathing` 方法中初始化 `_dpi` 为 `DpiHelper.ScaleY`。
修改了 `RotateTo` 方法的 `controlRatio` 参数类型,从 `int` 改为 `double`,并在调用 `Simulation.SendInput.Mouse.MoveMouseBy` 时乘以 `_dpi` 进行 DPI 缩放。
在 `TaskRunner.cs` 中,添加了 `FireAndForgetAsync` 方法,用于异步执行任务。
在 `ScriptService.cs` 中,添加了对 `BetterGenshinImpact.Helpers` 的引用。
修改了 `ScriptService` 类中调用 `TaskRunner` 的方式,从 `RunAsync` 改为 `FireAndForgetAsync`。
在 `ScriptControlViewModel.cs` 中,简化了调用 `_scriptService.RunMulti` 的方式,去掉了多余的 `Task.Run` 包装。
|
2024-09-09 00:44:24 +08:00 |
|
辉鸭蛋
|
4276957837
|
tp opt & F11 can cancel script task
优化日志记录和任务取消逻辑
在 `PathExecutor.cs` 中添加了 `using System.Diagnostics;` 语句。
注释掉了 `PathExecutor` 类中的部分日志信息。
将 `MoveTo` 和 `MoveCloseTo` 方法中的日志记录改为使用 `Debug.WriteLine`。
修改了 `MoveTo` 和 `MoveCloseTo` 方法中的循环条件,改为 `while (!cts.IsCancellationRequested)`。
将 `MoveTo` 方法中的超时时间从 30 秒改为 60 秒。
在 `TpTask.cs` 中增加了对配置项的最小值检查。
在 `MapAssets.cs` 中添加了新的地图坐标 `{ "纳塔", [8973.5, -1879.1] }`。
在 `HomePageViewModel.cs` 中添加了 `using BetterGenshinImpact.Core.Script;` 语句。
在 `HomePageViewModel` 类的 `Stop` 方法中,添加了取消独立任务的逻辑。
|
2024-09-08 19:44:34 +08:00 |
|
辉鸭蛋
|
a0691f1c19
|
auto pathing: add mapper viewer
|
2024-09-08 19:08:46 +08:00 |
|
辉鸭蛋
|
ca6994a720
|
auto pathing : first version
|
2024-09-08 15:16:02 +08:00 |
|
辉鸭蛋
|
cb09a369c2
|
auto pathing: fix jump and fly
|
2024-09-08 12:33:58 +08:00 |
|
辉鸭蛋
|
1fd5320df2
|
auto pathing: update
- 移除了不必要的 `using` 语句,添加了新的 `using` 语句。
- 将 `Waypoints` 属性重命名为 `Positions`。
- 更新了 `BuildFromFilePath` 方法中的 `JsonOptions` 引用。
- 将 `Waypoint` 类移到单独的文件中,并添加了相关属性和注释。
- 添加了 `SaveToFile` 方法,用于将 `PathingTask` 对象保存到文件。
- 更新了 `PathExecutor` 中的 `TaskControl` 引用,简化了代码。
- 更新了 `PathRecorder` 的属性和方法,使用私有字段 `_pathingTask`。
- 更新了 `MapPathingPage.xaml` 的命令绑定。
- 更新了 `HotKeyPageViewModel` 和 `MapPathingViewModel` 的逻辑。
- 添加了新的 `PathingTaskConfig` 类,用于配置路径任务。
|
2024-09-08 02:23:45 +08:00 |
|
辉鸭蛋
|
5818bcd7ed
|
refactor the path task-related code, using the new enum class
在 `PathingTask.cs`、`PathExecutor.cs` 和 `PathRecorder.cs` 中,删除了 `WaypointType`、`MoveType`、`ActionType` 和 `PathingTaskType` 枚举,并将其替换为 `Enum` 命名空间中的类。更新了 `PathingTaskInfo` 类的属性默认值和新增属性。在 `PathExecutor.cs` 中,使用 `.Code` 属性进行比较,并优化了 `prevPositions` 列表的索引。在 `HotKeyPageViewModel.cs` 中,重命名了变量并更新了回调函数。在 `ActionEnum.cs`、`MoveStatusType.cs`、`PathingTaskType.cs` 和 `WaypointType.cs` 中,定义了新的枚举类及其静态实例和相关方法。
|
2024-09-07 14:53:25 +08:00 |
|
辉鸭蛋
|
7c1febf307
|
add pathing ui
|
2024-09-01 20:15:47 +08:00 |
|
辉鸭蛋
|
5955f90c03
|
update pathing page
|
2024-09-01 02:10:13 +08:00 |
|
lwh9346
|
fb0c63f8a8
|
optimize fly mode and path recording
|
2024-08-19 11:14:37 +08:00 |
|
lwh9346
|
1610f1cd31
|
remove redundant screen capture
|
2024-08-18 22:47:23 +08:00 |
|
lwh9346
|
ab2d6c1de4
|
copy when transforming coordinate
|
2024-08-18 21:55:08 +08:00 |
|
lwh9346
|
8f64c0ca4e
|
remove unnecessary task run
|
2024-08-18 21:28:03 +08:00 |
|
lwh9346
|
9393b0cb24
|
test and make "move to" functional
|
2024-08-17 19:16:26 +08:00 |
|
ema
|
9b874d3747
|
small trial with using Toast instead of MessageBox
|
2024-08-16 00:43:32 +08:00 |
|
辉鸭蛋
|
6651ec7d9f
|
attempt to correct coordinates
|
2024-08-15 00:00:12 +08:00 |
|
lwh9346
|
8a5d1d5f64
|
add path executor
|
2024-08-14 15:08:37 +08:00 |
|
lwh9346
|
f82e35382c
|
add UNTESTED path executor
|
2024-08-14 10:17:16 +08:00 |
|
lwh9346
|
224fc9917a
|
add walk and swim to "move to" function
|
2024-08-14 01:39:27 +08:00 |
|
lwh9346
|
f61a7c32d4
|
add basic code for auto pathing
|
2024-08-14 00:36:57 +08:00 |
|