Compare commits

..

7 Commits

Author SHA1 Message Date
MisakaAldrich
bd001fde7f update repo.json
Some checks failed
Build repo.json / build (18.x) (push) Has been cancelled
Build repo.json / upload (push) Has been cancelled
2025-07-29 14:14:01 +00:00
起个名字好难的喵
a0bfe339ea JS脚本: 自动伐木路径追踪版新增伪造日志,预计用时 (#1438) 2025-07-29 22:13:42 +08:00
MisakaAldrich
2c65bf97de update repo.json 2025-07-29 04:12:51 +00:00
Jamis
91b1202abd 螃蟹 04-纳塔-安绕之野-2只.json (#1437) 2025-07-29 12:12:00 +08:00
MisakaAldrich
301f490a36 update repo.json 2025-07-29 04:11:23 +00:00
mno
39baae8149 js:锄地一条龙和自动狗粮 (#1436)
### 1.7.1(2025.07.29)
1.修复了不卡时间,并尽可能跑A模式不可用的问题
### 1.2.4(2025.07.29)
1.修复了关键词无法对怪物名称生效的问题
2025-07-29 12:11:08 +08:00
LCMs
b504c16aa4 修复邀请函购买逻辑 (#1435) 2025-07-29 12:10:54 +08:00
11 changed files with 130 additions and 32 deletions

View File

@@ -1,5 +1,5 @@
{
"time": "20250728235917",
"time": "20250729221400",
"url": "https://github.com/babalae/bettergi-scripts-list/archive/refs/heads/main.zip",
"file": "repo.json",
"indexes": [
@@ -66788,7 +66788,7 @@
{
"name": "04-纳塔-安绕之野-2只.json",
"type": "file",
"hash": "cd6b61714cbf3db243a146e68313e3ff9e2c375e",
"hash": "461f0a59b811d756a5f112ec7c37fefccbf76d8d",
"version": "1.0",
"author": "芝士贝果",
"authors": [
@@ -66802,7 +66802,7 @@
"食材与炼金",
"螃蟹"
],
"lastUpdated": "2025-07-28 17:29:23"
"lastUpdated": "2025-07-29 12:12:00"
},
{
"name": "05-纳塔-镜壁山-5只.json",
@@ -71707,8 +71707,8 @@
{
"name": "AutoArtifactsPro",
"type": "directory",
"hash": "5b4312d6b14c37c0009c3ae9fe23471ee40ed16c",
"version": "1.7.0",
"hash": "9ad592abdb548e9961b219b58ebfd0dbaab21a9d",
"version": "1.7.1",
"author": "mno",
"authors": [
{
@@ -71729,7 +71729,7 @@
"好感",
"狗粮"
],
"lastUpdated": "2025-07-28 17:29:42"
"lastUpdated": "2025-07-29 12:11:08"
},
{
"name": "AutoArtifactsSalvageOrDestroy1-4star",
@@ -71985,8 +71985,8 @@
{
"name": "AutoHoeingOneDragon",
"type": "directory",
"hash": "8ba20c6f1a53b2652362b7e750b77947d30167fc",
"version": "1.2.3",
"hash": "7e5256c68774165aeeaddd31445b3d5c24f4473d",
"version": "1.2.4",
"author": "mno",
"authors": [
{
@@ -71994,9 +71994,9 @@
"link": "https://github.com/Bedrockx"
}
],
"description": "锄地一条龙~|~一站式解决自动化锄地支持只拾取狗粮请阅读README.md后使用",
"description": "锄地一条龙~|~一站式解决自动化锄地,支持只拾取狗粮,请仔细阅读README.md后使用",
"tags": [],
"lastUpdated": "2025-07-28 17:29:42"
"lastUpdated": "2025-07-29 12:11:08"
},
{
"name": "AutoLeyLineOutcrop",
@@ -72173,8 +72173,8 @@
{
"name": "AutoWoodcutting-Pathing",
"type": "directory",
"hash": "46f86ac9b1a38316eabba0e6f867d55bcf54fd36",
"version": "1.1.0",
"hash": "d430eef19f4db88465141a2d888005ffded117b9",
"version": "1.1.2",
"author": "Tim",
"authors": [
{
@@ -72192,7 +72192,7 @@
"地图追踪",
"王树瑞佑"
],
"lastUpdated": "2025-07-28 23:58:59"
"lastUpdated": "2025-07-29 22:13:42"
},
{
"name": "AutoYuanQin",

View File

@@ -171,6 +171,8 @@ https://www.kdocs.cn/wo/sl/v13uXscL
## 更新日志
### 1.7.12025.07.29
1.修复了不卡时间并尽可能跑A模式不可用的问题
### 1.7.02025.07.28
1.增加模式不卡时间并尽可能跑A比前一天晚间隔时间以上就跑A并设为默认选项
2.增加通知收益的选项

View File

@@ -272,6 +272,11 @@ let enemyType = "无";
runRouteA = false;
}
if (operationType === "不卡时间尽可能跑A") {
// 根据当前时间与上次运行时间给布尔变量 runRouteA 赋值
runRouteA = endTime <= timeNow;
}
// 检查 lastRunRoute 是否为 "B"
if (lastRunRoute === "B" && operationType !== "不卡时间ab交替运行") {
// 如果 lastRunRoute 为 "B",则将 endTime 改为当天的开始时间
@@ -287,11 +292,6 @@ let enemyType = "无";
// 根据当前时间与 1970-01-01T20:00:00.000Z 的天数差的奇偶性给布尔变量 runRouteA 赋值
runRouteA = Math.floor((now - epochTime) / (24 * 60 * 60 * 1000)) % 2 === 0;
}
if (operationType === "不卡时间ab交替运行") {
// 根据当前时间与上次运行时间给布尔变量 runRouteA 赋值
runRouteA = endTime <= timeNow;
}
}
//切换至好感队

View File

@@ -1,7 +1,7 @@
{
"manifest_version": 1,
"name": "自动狗粮重制版",
"version": "1.7.0",
"version": "1.7.1",
"tags": [
"好感",
"狗粮"

View File

@@ -74,6 +74,8 @@
---
### 更新日志
### 1.2.42025.07.29
1.修复了关键词无法对怪物名称生效的问题
### 1.2.32025.07.28
1.优化了定时终止的逻辑,会按下一条路线的预计时间来计算,避免某条线路过长
2.添加了按效率降序运行的选项,用于在时间有限且不确定时优先运行效率较高的路线

View File

@@ -158,8 +158,9 @@ async function processPathings() {
// 解析 description 获取预计用时和怪物信息
const routeInfo = parseDescription(description);
// 初始化 pathing 对象的属性
pathing.t = routeInfo.time; // 预计用时初始化为60秒如果 description 中有值则覆盖
//pathing 对象的属性
pathing.t = routeInfo.time; // description 中有值则覆盖
pathing.monsterInfo = routeInfo.monsterInfo;
if (!settings.disableSelfOptimization && pathing.records) {
//如果用户没有禁用自动优化,则参考运行记录更改预期用时
const history = pathing.records.filter(v => v > 0);

View File

@@ -1,8 +1,8 @@
{
"manifest_version": 1,
"name": "锄地一条龙",
"version": "1.2.3",
"description": "一站式解决自动化锄地支持只拾取狗粮请阅读README.md后使用",
"version": "1.2.4",
"description": "一站式解决自动化锄地,支持只拾取狗粮,请仔细阅读README.md后使用",
"authors": [
{
"name": "mno",

View File

@@ -82,7 +82,9 @@
if (pathing.fileName.length > 1 && pathing.fileName[0].includes('大循环')) {
try {
log.info(`正在执行 ${pathingName} 大循环路径`);
await fakeLog(`${pathing.fileName}`, false, true, 0);
await pathingScript.runFile(filePath);
await fakeLog(`${pathing.fileName}`, false, false, 0);
await sleep(1);
log.info(`完成 ${pathingName} 大循环路径, 获得${woodCountToStr(woodCount)}`);
woodCount.forEach((value, key) => { woodNumberMap.set(key, woodNumberMap.get(key) - value) });
@@ -108,23 +110,27 @@
}
await sleep(1);
try {
const currentWoodStartTime = Date.now();
for (let i = 0; i < runTimes; i++) {
log.info(`正在执行 ${pathingName}${i + 1}/${runTimes} 次循环`);
for (let k = j; k < pathing.fileName.length; k++) {
filePath = filePathPre + pathing.fileName[k] + filePathSuf;
await fakeLog(`${pathing.fileName}`, false, true, 0);
await pathingScript.runFile(filePath);
await fakeLog(`${pathing.fileName}`, false, false, 0);
await sleep(1);
}
const jsTimeTaken = logTimeTaken(startTime);
const estimatedCompletion = calculateEstimatedCompletion(currentWoodStartTime, i + 1, runTimes);
log.info(`${pathingName}${i + 1}/${runTimes} 次循环执行完成`);
logTimeTaken(startTime);
log.info(`${pathingName} 预计完成时间: ${estimatedCompletion}, ${jsTimeTaken}`)
}
log.info(`完成 ${pathingName} 循环路径, 获得${woodCountToStr(woodCount, runTimes)}`);
logTimeTaken(startTime);
const jsTimeTaken = logTimeTaken(startTime);
log.info(`完成 ${pathingName} 循环路径, 获得${woodCountToStr(woodCount, runTimes)}, ${jsTimeTaken}`);
woodCount.forEach((value, key) => {
woodNumberMap.set(key, woodNumberMap.get(key) - value * runTimes);
});
log.info(`${pathingName} 伐木完成将执行下一个`);
logTimeTaken(startTime);
log.info(`${pathingName} 伐木完成, 将执行下一个`);
logRemainingItems();
} catch (error) {
log.error(`在砍伐 ${pathingName} 时发生错误: ${error}`);
@@ -248,7 +254,94 @@
const minutes = Math.floor(totalTimeInSeconds / 60);
const seconds = totalTimeInSeconds % 60;
const formattedTime = `${minutes}${seconds.toFixed(0).padStart(2, '0')}`;
log.info(`当前运行总时长${formattedTime}`);
return `当前运行总时长: ${formattedTime}`;
}
function calculateEstimatedCompletion(startTime, current, total) {
if (current === 0) return "计算中...";
const elapsedTime = Date.now() - startTime;
const timePerTask = elapsedTime / current;
const remainingTasks = total - current;
const remainingTime = timePerTask * remainingTasks;
const completionDate = new Date(Date.now() + remainingTime);
return `${completionDate.toLocaleTimeString()}, 约 ${Math.round(remainingTime / 60000)} 分钟`;
}
async function fakeLog(name, isJs, isStart, duration) {
await sleep(10);
const currentTime = Date.now();
// 参数检查
if (typeof name !== 'string') {
log.error("参数 'name' 必须是字符串类型!");
return;
}
if (typeof isJs !== 'boolean') {
log.error("参数 'isJs' 必须是布尔型!");
return;
}
if (typeof isStart !== 'boolean') {
log.error("参数 'isStart' 必须是布尔型!");
return;
}
if (typeof currentTime !== 'number' || !Number.isInteger(currentTime)) {
log.error("参数 'currentTime' 必须是整数!");
return;
}
if (typeof duration !== 'number' || !Number.isInteger(duration)) {
log.error("参数 'duration' 必须是整数!");
return;
}
// 将 currentTime 转换为 Date 对象并格式化为 HH:mm:ss.sss
const date = new Date(currentTime);
const hours = String(date.getHours()).padStart(2, '0');
const minutes = String(date.getMinutes()).padStart(2, '0');
const seconds = String(date.getSeconds()).padStart(2, '0');
const milliseconds = String(date.getMilliseconds()).padStart(3, '0');
const formattedTime = `${hours}:${minutes}:${seconds}.${milliseconds}`;
// 将 duration 转换为分钟和秒,并保留三位小数
const durationInSeconds = duration / 1000; // 转换为秒
const durationMinutes = Math.floor(durationInSeconds / 60);
const durationSeconds = (durationInSeconds % 60).toFixed(3); // 保留三位小数
// 使用四个独立的 if 语句处理四种情况
if (isJs && isStart) {
// 处理 isJs = true 且 isStart = true 的情况
const logMessage = `正在伪造js开始的日志记录\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`------------------------------\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`→ 开始执行JS脚本: "${name}"`;
log.debug(logMessage);
}
if (isJs && !isStart) {
// 处理 isJs = true 且 isStart = false 的情况
const logMessage = `正在伪造js结束的日志记录\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`→ 脚本执行结束: "${name}", 耗时: ${durationMinutes}${durationSeconds}\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`------------------------------`;
log.debug(logMessage);
}
if (!isJs && isStart) {
// 处理 isJs = false 且 isStart = true 的情况
const logMessage = `正在伪造地图追踪开始的日志记录\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`------------------------------\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`→ 开始执行地图追踪任务: "${name}"`;
log.debug(logMessage);
}
if (!isJs && !isStart) {
// 处理 isJs = false 且 isStart = false 的情况
const logMessage = `正在伪造地图追踪结束的日志记录\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`→ 脚本执行结束: "${name}", 耗时: ${durationMinutes}${durationSeconds}\n\n` +
`[${formattedTime}] [INF] BetterGenshinImpact.Service.ScriptService\n` +
`------------------------------`;
log.debug(logMessage);
}
}
// Set game environment settings

View File

@@ -1,7 +1,7 @@
{
"manifest_version": 1,
"name": "自动伐木-地图追踪版",
"version": "1.1.0",
"version": "1.1.2",
"description": "基于地图追踪的自动伐木已支持5.7版本前的全部木材\n默认砍伐全部支持木材至2000上限\n自定义设置:\n-可更改砍伐木材种类和数量\n-可以单独设置每个木材数量\n-可设置队伍中是否包含一斗按保底20%计算砍伐数量时会除以1.2",
"tags": [
"伐木",

View File

@@ -175,7 +175,7 @@ await genshin.returnMainUi();
log.info(`开始执行角色邀约挑战`);
for (let i = 0; i < challengeNumber; i++) {
await gotoTavern();
if (challengeNumber-letterNumber > 0) {
if (letterNumber <= i) {
log.info(`购买第${i+1}`);
await BuyLetter();
letterNumber++;

View File

@@ -31,7 +31,7 @@
"y": -3316.2734,
"action": "combat_script",
"move_mode": "run",
"action_params": "wait(10)",
"action_params": "wait(5)",
"type": "path"
},
{