This commit is contained in:
ChomeNS 2022-10-17 13:02:44 +07:00
parent 219e182bb0
commit f6bca256e1

View file

@ -98,7 +98,7 @@ function inject(bot) {
// core.fillCore();
}
const interval = setInterval(async () => {
async function loopPlace() {
try {
const fillCommand = `/minecraft:fill ${core.start.x} ${core.start.y} ${core.start.z} ${core.end.x} ${core.end.y} ${core.end.z} command_block{CustomName:'{"text":"ChomeNS Bot Core","color":"yellow"}'}`;
const location = {x: Math.floor(bot.position.x), y: Math.floor(bot.position.y) - 1, z: Math.floor(bot.position.z)};
@ -136,6 +136,11 @@ function inject(bot) {
} catch (e) {
return;
}
}
loopPlace();
const interval = setInterval(() => {
loopPlace();
}, config.core.refillInterval);
return core;