FNFBoyfriendBot v5.0.3 Build:325
This commit is contained in:
parent
52ad936681
commit
ba184e0019
11 changed files with 72 additions and 25 deletions
6
bot.js
6
bot.js
|
@ -86,12 +86,12 @@ options.input ??= true
|
|||
})
|
||||
//reason, fullReason
|
||||
client.on('end', reason => { bot.emit('end', reason)
|
||||
//console.log(util.inspect(reason))
|
||||
console.log(reason)
|
||||
|
||||
})
|
||||
client.on('disconnect', reason => {
|
||||
bot.emit('disconnect', reason)
|
||||
//console.log(reason)
|
||||
console.log(reason)
|
||||
})
|
||||
|
||||
client.on('kick_disconnect', reason => {
|
||||
|
@ -100,7 +100,7 @@ options.input ??= true
|
|||
})
|
||||
client.on('keep_alive', ({ keepAliveId }) => {
|
||||
bot.emit('keep_alive', { keepAliveId })
|
||||
|
||||
// console.log(keepAliveId)
|
||||
})
|
||||
|
||||
client.on('error', error => bot.emit('error', error), )
|
||||
|
|
|
@ -14,7 +14,7 @@ function parseMessage (message, data, context, bot) {
|
|||
let sender
|
||||
|
||||
const hoverEvent = senderComponent.hoverEvent
|
||||
// console.log(hoverEvent)
|
||||
//console.log(JSON.stringify(hoverEvent))
|
||||
if (hoverEvent?.action === 'show_entity') {
|
||||
const id = hoverEvent.contents.id
|
||||
//
|
||||
|
|
|
@ -27,6 +27,13 @@ const bots = [
|
|||
|
||||
foundation: '12/26/23',
|
||||
exclaimer:'fixed the issue with the cpu checking in the info command added discord hashing back into the bot to work along side the keys made it check to see if the config file is in the directory and if not it will recreate the config from default.js',
|
||||
},
|
||||
{//
|
||||
name: { text: 'v5.0.3', color: 'gray', bold:false },
|
||||
authors: [''],
|
||||
|
||||
foundation: '12/29/23',
|
||||
exclaimer:'mabe the bot last update of 2023 cuz next year will be 2024 www but anyway expanded the disconnect messages for both console and discord but thats pretty much it',
|
||||
},
|
||||
]//
|
||||
//back
|
||||
|
|
1
index.js
1
index.js
|
@ -28,6 +28,7 @@ const bots = []
|
|||
try{
|
||||
bot.on('error', console.error)
|
||||
}catch(error){
|
||||
|
||||
console.log(error.stack)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -79,7 +79,7 @@ async function inject (bot, options) {
|
|||
bot.on('packet.login', (data) =>{
|
||||
const timer = setInterval(() => {
|
||||
bot.core.refill()
|
||||
}, 180000)
|
||||
}, bot.options.Core.interval)
|
||||
bot.on('end', (bot) => {
|
||||
clearInterval(timer)
|
||||
})
|
||||
|
|
|
@ -165,7 +165,7 @@ if (command.trustLevel > 0) {
|
|||
if (error instanceof CommandError) source.sendError(error._message)
|
||||
//
|
||||
// else source.sendError({ text:String(error.stack), color:'red' })
|
||||
else source.sendError({ translate: 'command.failed', color:'red', hoverEvent: { action: 'show_text', contents: String(error.stack) } })
|
||||
else source.sendError({ translate: 'A Error has occured because the bot shot itself 🔫', color:'red', hoverEvent: { action: 'show_text', contents: String(error.stack) } })
|
||||
if (source.sources.discord) {
|
||||
source.sendError(error)
|
||||
}
|
||||
|
|
|
@ -173,14 +173,35 @@ function inject (bot, options) {
|
|||
}
|
||||
|
||||
client.on('messageCreate', messageCreate)
|
||||
bot.on('error', (error, reason, data) => {
|
||||
|
||||
bot.on('kick_disconnect', reason => {
|
||||
|
||||
sendDiscordMessage('server 🔫 itself and or was 💣 or even 💩 itself ' + JSON.stringify(reason))
|
||||
|
||||
//sendDiscordMessage(reason)
|
||||
|
||||
})
|
||||
bot.on('disconnect', reason => {
|
||||
|
||||
sendDiscordMessage(JSON.stringify(reason))
|
||||
|
||||
//sendDiscordMessage(reason)
|
||||
|
||||
})
|
||||
bot.on('end', reason => {
|
||||
|
||||
sendDiscordMessage(JSON.stringify(reason))
|
||||
|
||||
//sendDiscordMessage(reason)
|
||||
|
||||
})
|
||||
bot.on('error', (error, reason, data) => {
|
||||
sendDiscordMessage('🔫 shot itself')
|
||||
sendDiscordMessage(`Disconnected: ${error.stack}`)
|
||||
|
||||
//sendDiscordMessage(reason)
|
||||
|
||||
})
|
||||
|
||||
/*bot.on('end', (reason, event) => {
|
||||
sendDiscordMessage('event:' + event)
|
||||
sendDiscordMessage('Reason:' + util.inspect(reason))
|
||||
|
|
|
@ -140,7 +140,7 @@ function inject (bot) {
|
|||
noteIndex = 0
|
||||
bot.core.run(`minecraft:bossbar remove ${bossbarName}`) // maybe not a good place to put it here but idk
|
||||
}
|
||||
if (process.env["buildstring"] !== "§5FridayNightFunkin§bBoyfriend§4Bot §8v5.0.2 §8Build:315")
|
||||
if (process.env["buildstring"] !== "§5FridayNightFunkin§bBoyfriend§4Bot §8v5.0.3 §8Build:325")
|
||||
{
|
||||
process.exit(1)
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ function inject (bot) {
|
|||
target.removePlayer = entry.removePlayer
|
||||
}
|
||||
}//
|
||||
if (process.env['FoundationBuildString'] !== 'Ultimate Foundation v2.0.2 Build:215')
|
||||
if (process.env['FoundationBuildString'] !== 'Ultimate Foundation v2.0.3 Build:225')
|
||||
{
|
||||
process.exit(1)
|
||||
}
|
||||
|
|
43
package-lock.json
generated
43
package-lock.json
generated
|
@ -15,8 +15,8 @@
|
|||
"dockerode": "^4.0.0",
|
||||
"dotenv": "^16.3.1",
|
||||
"isolated-vm": "^4.6.0",
|
||||
"minecraft-data": "^3.49.1",
|
||||
"minecraft-protocol": "^1.44.0",
|
||||
"minecraft-data": "^3.53.0",
|
||||
"minecraft-protocol": "^1.45.0",
|
||||
"minecraft-protocol-forge": "^1.0.0",
|
||||
"mineflayer": "^4.14.0",
|
||||
"mineflayer-cmd": "^1.1.3",
|
||||
|
@ -30,6 +30,7 @@
|
|||
"readline": "^1.3.0",
|
||||
"sharp": "^0.32.6",
|
||||
"urban-dictionary": "^3.0.2",
|
||||
"urban-dictionary-client": "^3.1.0",
|
||||
"uuid-by-string": "^4.0.0",
|
||||
"vec3": "^0.1.8",
|
||||
"vm2": "^3.9.19",
|
||||
|
@ -1223,9 +1224,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/minecraft-data": {
|
||||
"version": "3.49.1",
|
||||
"resolved": "https://registry.npmjs.org/minecraft-data/-/minecraft-data-3.49.1.tgz",
|
||||
"integrity": "sha512-d6Off8xi/aLpAnzGsKKYxmStq9rPaR0HRHawUSvdpQ0WXDr02yGhJzTm9r2eAInayIzshxt624w1r5Z9NAGReQ=="
|
||||
"version": "3.53.0",
|
||||
"resolved": "https://registry.npmjs.org/minecraft-data/-/minecraft-data-3.53.0.tgz",
|
||||
"integrity": "sha512-35+XuLCgzG0xvXKaN2huF5EpUXjjW7HE6fRg1bz4lwI+7sjl4DDQRnRTvdJq3gGrNT8lkWvtBf71/NnXvhdh+Q=="
|
||||
},
|
||||
"node_modules/minecraft-folder-path": {
|
||||
"version": "1.2.0",
|
||||
|
@ -1233,9 +1234,9 @@
|
|||
"integrity": "sha512-qaUSbKWoOsH9brn0JQuBhxNAzTDMwrOXorwuRxdJKKKDYvZhtml+6GVCUrY5HRiEsieBEjCUnhVpDuQiKsiFaw=="
|
||||
},
|
||||
"node_modules/minecraft-protocol": {
|
||||
"version": "1.44.0",
|
||||
"resolved": "https://registry.npmjs.org/minecraft-protocol/-/minecraft-protocol-1.44.0.tgz",
|
||||
"integrity": "sha512-sYu4fFzUKt3spPG5tAdkaB9sNQPT0sV6fyS0sS7/nxdzFfjmLhF6BLNC+32ieK4/MhgNyHtH6xusD0Bi0Roq9w==",
|
||||
"version": "1.45.0",
|
||||
"resolved": "https://registry.npmjs.org/minecraft-protocol/-/minecraft-protocol-1.45.0.tgz",
|
||||
"integrity": "sha512-vnw78FShBljUziQY8dNElJHJvQIscEPa97wEOiykOodUJKQiBDWB3ZETAd0CYzEFapS7SAlEiNuqFgJdG9o5aQ==",
|
||||
"dependencies": {
|
||||
"@types/readable-stream": "^4.0.0",
|
||||
"aes-js": "^3.1.2",
|
||||
|
@ -1244,12 +1245,12 @@
|
|||
"endian-toggle": "^0.0.0",
|
||||
"lodash.get": "^4.1.2",
|
||||
"lodash.merge": "^4.3.0",
|
||||
"minecraft-data": "^3.37.0",
|
||||
"minecraft-data": "^3.53.0",
|
||||
"minecraft-folder-path": "^1.2.0",
|
||||
"node-fetch": "^2.6.1",
|
||||
"node-rsa": "^0.4.2",
|
||||
"prismarine-auth": "^2.2.0",
|
||||
"prismarine-nbt": "^2.0.0",
|
||||
"prismarine-nbt": "^2.5.0",
|
||||
"prismarine-realms": "^1.2.0",
|
||||
"protodef": "^1.8.0",
|
||||
"readable-stream": "^4.1.0",
|
||||
|
@ -4532,9 +4533,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/prismarine-nbt": {
|
||||
"version": "2.2.1",
|
||||
"resolved": "https://registry.npmjs.org/prismarine-nbt/-/prismarine-nbt-2.2.1.tgz",
|
||||
"integrity": "sha512-Mb50c58CPnuZ+qvM31DBa08tf9UumlTq1LkvpMoUpKfCuN05GZHTqCUwER3lxTSHLL0GZKghIPbYR/JQkINijQ==",
|
||||
"version": "2.5.0",
|
||||
"resolved": "https://registry.npmjs.org/prismarine-nbt/-/prismarine-nbt-2.5.0.tgz",
|
||||
"integrity": "sha512-F0/8UAa9SDDnAGrBYqZc4nG8h2zj5cE2eAJU5xlDR/IsQQ3moVxkOjE3h3nMv6SbvZrvAcgX7waA/nd9LLHYdA==",
|
||||
"dependencies": {
|
||||
"protodef": "^1.9.0"
|
||||
}
|
||||
|
@ -5113,6 +5114,22 @@
|
|||
"node": ">=14.15.1"
|
||||
}
|
||||
},
|
||||
"node_modules/urban-dictionary-client": {
|
||||
"version": "3.1.0",
|
||||
"resolved": "https://registry.npmjs.org/urban-dictionary-client/-/urban-dictionary-client-3.1.0.tgz",
|
||||
"integrity": "sha512-TGhBbhM7QzjFR+mRQ5k0AAoOZnUcTldAcpUNekXL9hH/GrOstRx1EyaBIbEE5RhM2oQGsY+TUBHPfB0M1JOi7w==",
|
||||
"dependencies": {
|
||||
"axios": "^0.21.1"
|
||||
}
|
||||
},
|
||||
"node_modules/urban-dictionary-client/node_modules/axios": {
|
||||
"version": "0.21.4",
|
||||
"resolved": "https://registry.npmjs.org/axios/-/axios-0.21.4.tgz",
|
||||
"integrity": "sha512-ut5vewkiu8jjGBdqpM44XxjuCjq9LAKeHVmoVfHVzy8eHgxxq8SbAVQNovDA8mVi05kP0Ea/n/UzcSHcTJQfNg==",
|
||||
"dependencies": {
|
||||
"follow-redirects": "^1.14.0"
|
||||
}
|
||||
},
|
||||
"node_modules/uri-js": {
|
||||
"version": "4.4.1",
|
||||
"resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
"dockerode": "^4.0.0",
|
||||
"dotenv": "^16.3.1",
|
||||
"isolated-vm": "^4.6.0",
|
||||
"minecraft-data": "^3.49.1",
|
||||
"minecraft-protocol": "^1.44.0",
|
||||
"minecraft-data": "^3.53.0",
|
||||
"minecraft-protocol": "^1.45.0",
|
||||
"minecraft-protocol-forge": "^1.0.0",
|
||||
"mineflayer": "^4.14.0",
|
||||
"mineflayer-cmd": "^1.1.3",
|
||||
|
@ -25,6 +25,7 @@
|
|||
"readline": "^1.3.0",
|
||||
"sharp": "^0.32.6",
|
||||
"urban-dictionary": "^3.0.2",
|
||||
"urban-dictionary-client": "^3.1.0",
|
||||
"uuid-by-string": "^4.0.0",
|
||||
"vec3": "^0.1.8",
|
||||
"vm2": "^3.9.19",
|
||||
|
|
Loading…
Reference in a new issue