AbundantOre 0.16 (#2146)

This commit is contained in:
Jamis
2025-10-15 09:13:11 +08:00
committed by GitHub
parent 5562777e74
commit 987948737e
3 changed files with 16 additions and 2 deletions

View File

@@ -29,6 +29,10 @@
## ChangeLog
### 0.16
- 日志实时输出进度
### 0.15
- 子任务结束时如果坐标未变化则不写入记录

View File

@@ -466,6 +466,7 @@ async function main() {
}
const start_time = Date.now();
var last_log_progress_time = 0;
var accurate_yield = 0;
var estimated_yield = 0;
var cached_inventory_data = original_inventory;
@@ -526,6 +527,15 @@ async function main() {
finished = true;
break;
}
if (Date.now() - last_log_progress_time > 30000) {
last_log_progress_time = Date.now();
if (target_yield !== null) {
log.info("当前产出{estimate}{a}/{b}个", (estimated_yield === accurate_yield ? "" : "(预计)"), Math.round(estimated_yield), target_yield);
}
if (run_until_unix_time !== null) {
log.info("当前运行时间:{a}/{b}分钟", ((Date.now() - start_time) / 1000 / 60).toFixed(2), Math.round((run_until_unix_time - start_time) / 60 / 1000));
}
}
}
}
@@ -558,4 +568,4 @@ async function main() {
(async function() {
await main();
})();
})();

View File

@@ -2,7 +2,7 @@
"bgi_version": "0.50.0",
"manifest_version": 1,
"name": "矿产资源批发",
"version": "0.15",
"version": "0.16",
"description": "自动记录矿石刷新时间,优先选择效率最高的路线,支持按区域、种类、数量自动规划挖矿路线",
"authors": [
{