Files
bettergi-scripts-list/archive/js/AutoCatherine/main.js
起个名字好难的喵 d69f6e5bc6 地图追踪:香辛果新增30个 (#631)
* 完善归档路径

* 地图追踪:香辛果新增30个
2025-04-22 23:24:07 +08:00

31 lines
880 B
JavaScript

(async function () {
// 所有的代码必须由 async function 包裹
async function AutoPath(locationName) {
log.info(`前往 ${locationName}`);
try {
let filePath = `assets/${locationName}.json`;
await pathingScript.runFile(filePath);
} catch (error) {
log.error(`执行 ${locationName} 路径时发生错误`);
}
await sleep(2000);
if (locationName == "纳塔凯瑟琳") {
keyDown("w");
await sleep(4500);
keyUp("w");
keyDown("d");
await sleep(2000);
keyUp("d");
}
}
let filePath;
if (settings.selectValue === undefined)
filePath = "枫丹凯瑟琳"
else
filePath = settings.selectValue;
log.info("开始执行路径脚本");
await AutoPath(filePath);
})();