From bf49862840c2d744769ae94cc74ab29762fa6cae Mon Sep 17 00:00:00 2001 From: ChomeNS Date: Wed, 17 Aug 2022 18:59:26 +0700 Subject: [PATCH] som changes --- index.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index fa04fc9..bd92b17 100644 --- a/index.js +++ b/index.js @@ -232,7 +232,9 @@ function main() { bot.vmoptions = { timeout: 2000, sandbox: { - run: bot.core.run, + run: function(cmd) { + bot.core.run(cmd); + }, mc: mc, mineflayer: mineflayer, chat: bot.chat, @@ -381,7 +383,7 @@ function main() { bot.once('end', (reason, event) => { console.log(`Disconnected (${event} event): ${util.inspect(reason)}`); - channel.send(`Disconnected (${event} event): ${util.inspect(reason)}`); + dcmsg.queue += '\n' + `Disconnected (${event} event): ${util.inspect(reason)}`; let timeout = 1000;