mirror of
https://github.com/ChomeNS/chomens-bot-mc.git
synced 2024-11-27 09:35:35 -05:00
Ops!!!!!
This commit is contained in:
parent
be57d2caf2
commit
0786d6c801
1 changed files with 4 additions and 4 deletions
8
index.js
8
index.js
|
@ -105,6 +105,9 @@ function botThings() {
|
|||
hideErrors: true,
|
||||
};
|
||||
bot._client = mc.createClient(bot.options);
|
||||
bot.uuid = bot._client.uuid;
|
||||
bot.username = bot._client.username;
|
||||
bot.version = bot._client.version;
|
||||
bot.queue = [];
|
||||
bot.write = (name, data) => bot._client.write(name, data);
|
||||
bot.end = (reason = 'end') => {
|
||||
|
@ -220,15 +223,12 @@ function main() {
|
|||
// fs.appendFileSync('./logs.txt', `\r\Connecting to: ${bot.options.host}:${bot.options.port}...\r\n`);
|
||||
channel.send(`Connecting to: \`${bot.options.host}:${bot.options.port}\`...`);
|
||||
bot._client.on('login', async function(data) {
|
||||
bot.entityId = data.entityId;
|
||||
const chatMessage = require('prismarine-chat')(bot.version);
|
||||
const mcData = require('minecraft-data')(bot.version);
|
||||
console.log(`Successfully logged in to: ${bot.options.host}:${bot.options.port}`);
|
||||
// fs.appendFileSync('./logs.txt', `\r\nSuccessfully logged in to: ${bot.options.host}:${bot.options.port}\r\n`);
|
||||
channel.send(`Successfully logged in to: \`${bot.options.host}:${bot.options.port}\``);
|
||||
bot.uuid = bot._client.uuid;
|
||||
bot.username = bot._client.username;
|
||||
bot.entityId = data.entityId;
|
||||
bot.version = bot._client.version;
|
||||
previusMessage = undefined;
|
||||
loginfinish = false;
|
||||
started = false;
|
||||
|
|
Loading…
Reference in a new issue