added trade

This commit is contained in:
2023-06-02 08:54:08 -04:00
parent f71899e9c0
commit 16668c6714
4 changed files with 485 additions and 10 deletions

View File

@ -14,19 +14,19 @@ for(let name in conf.mc.bots){
let bot = new CJbot({name, host: conf.mc.host, ...conf.mc.bots[name]});
CJbot.bots[name] = bot;
for(let command of conf.mc.bots[name].commands || ['default']){
for(let [name, toAdd] of Object.entries(commands[command])){
bot.addCommand(name, toAdd)
}
}
bot.on('onReady', async function(argument) {
await sleep(1000);
bot.bot.setControlState('jump', true);
setTimeout(()=> bot.bot.setControlState('jump', false), 5000)
})
}
(async ()=>{
try{
for(let name in CJbot.bots){
@ -37,11 +37,8 @@ try{
await sleep(30000);
}
}
}catch(e){
console.log('!!!!!!!! error:', e)
}})()