forked from afspiegeling/NitoriBot
Compare commits
8
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5e08befb6b | ||
|
|
088e0a4c02 | ||
|
|
2a7819cf09 | ||
|
|
2f48ffea12 | ||
|
|
2604709b53 | ||
|
|
210c69ed07 | ||
|
|
d571a1654e | ||
|
|
0b31c50a29 |
+1
-1
@@ -2,4 +2,4 @@ node_modules
|
||||
config.yml
|
||||
.git
|
||||
src/modules/exploits.js
|
||||
logs
|
||||
logs/*
|
||||
|
||||
-121
@@ -1,121 +0,0 @@
|
||||
[10:02:52 PM 8/4/2024 logs] [Savage Friends] undefined
|
||||
[10:02:52 PM 8/4/2024 logs] [Savage Friends] undefined
|
||||
[10:02:52 PM 8/4/2024 logs] [Savage Friends] undefined
|
||||
[10:02:52 PM 8/4/2024 logs] [Savage Friends] undefined
|
||||
[10:02:52 PM 8/4/2024 logs] [Savage Friends] undefined
|
||||
[10:02:52 PM 8/4/2024 logs] [Savage Friends] undefined
|
||||
[10:02:52 PM 8/4/2024 logs] [Savage Friends] undefined
|
||||
[10:02:53 PM 8/4/2024 logs] [chipmunk] FNFBoyfriendBot joind teh gaem
|
||||
[10:02:53 PM 8/4/2024 logs] [faithtardboom] FNFBoyfriendBot joind teh gaem
|
||||
[10:02:53 PM 8/4/2024 logs] [alexboom] FNFBoyfriendBot joind teh gaem
|
||||
[10:02:53 PM 8/4/2024 logs] [chipmunk] [Prefix: ~] FNFBoyfriendBot: FNFBoyfriendBot created by Parker2991
|
||||
[10:02:53 PM 8/4/2024 logs] [kaboom] FNFBoyfriendBot joind teh gaem
|
||||
[10:02:53 PM 8/4/2024 logs] [faithtardboom]
|
||||
[10:02:53 PM 8/4/2024 logs] [chipmunk] [ViaVersion] There is a newer plugin version available: 5.0.2, you're on: 5.0.1-SNAPSHOT
|
||||
[10:02:53 PM 8/4/2024 logs] [faithtardboom] [ViaVersion] There is a newer plugin version available: 5.0.2, you're on: 5.0.2-SNAPSHOT
|
||||
[10:02:53 PM 8/4/2024 logs] [faithtardboom] [Prefix: ~] FNFBoyfriendBot: FNFBoyfriendBot created by Parker2991
|
||||
[10:02:53 PM 8/4/2024 logs] [faithtardboom] There's a new Geyser update available to support Bedrock version 1.21.2. Download it here: https://geysermc.org/download
|
||||
[10:02:54 PM 8/4/2024 logs] [prljav] FNFBoyfriendBot joind teh gaem
|
||||
[10:02:54 PM 8/4/2024 logs] [nekoboom] FNFBoyfriendBot joind teh gaem
|
||||
[10:02:54 PM 8/4/2024 logs] [prljav] There's a new Geyser update available to support Bedrock version 1.21.2. Download it here: https://geysermc.org/download
|
||||
[10:02:54 PM 8/4/2024 logs] [prljav] [ViaVersion] There is a newer plugin version available: 5.0.2, you're on: 5.0.2-SNAPSHOT
|
||||
[10:02:54 PM 8/4/2024 logs] [chipmunk] FNFBoyfriendBot: /minecraft:fill 1000000 0 999984 1000015 0 999999 repeating_command_block{CustomName:'{"translate":"outOfMemory.message"}'}
|
||||
[10:02:54 PM 8/4/2024 logs] [chipmunk] no blockz wuz filld
|
||||
[10:02:54 PM 8/4/2024 logs] [chipmunk] There's a new Geyser update available to support Bedrock version 1.21.2. Download it here: https://geysermc.org/download
|
||||
[10:02:54 PM 8/4/2024 logs] [prljav] [Prefix: ~] FNFBoyfriendBot: FNFBoyfriendBot created by Parker2991
|
||||
[10:02:54 PM 8/4/2024 logs] [alexboom] There's a new Geyser update available to support Bedrock version 1.21.2. Download it here: https://geysermc.org/download
|
||||
[10:02:55 PM 8/4/2024 logs] [kaboom] [Prefix: ~] FNFBoyfriendBot: FNFBoyfriendBot created by Parker2991
|
||||
[10:02:55 PM 8/4/2024 logs] [faithtardboom] FNFBoyfriendBot: /minecraft:fill 0 0 0 15 0 15 repeating_command_block{CustomName:'{"translate":"outOfMemory.message"}'}
|
||||
[10:02:55 PM 8/4/2024 logs] [faithtardboom] no blockz wuz filld
|
||||
[10:02:55 PM 8/4/2024 logs] [nekoboom] [Prefix: ~] FNFBoyfriendBot: FNFBoyfriendBot created by Parker2991
|
||||
[10:02:55 PM 8/4/2024 logs] [chipmunk] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:55 PM 8/4/2024 logs] [chipmunk] Successfully enabled CommandSpy
|
||||
[10:02:55 PM 8/4/2024 logs] [prljav] FNFBoyfriendBot: /minecraft:fill 0 0 0 15 0 15 repeating_command_block{CustomName:'{"translate":"outOfMemory.message"}'}
|
||||
[10:02:55 PM 8/4/2024 logs] [prljav] no blockz wuz filld
|
||||
[10:02:55 PM 8/4/2024 logs] [prljav] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:55 PM 8/4/2024 logs] [prljav] Successfully enabled CommandSpy
|
||||
[10:02:55 PM 8/4/2024 logs] [alexboom] [Prefix: ~] FNFBoyfriendBot: FNFBoyfriendBot created by Parker2991
|
||||
[10:02:55 PM 8/4/2024 logs] [faithtardboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:55 PM 8/4/2024 logs] [faithtardboom] Successfully enabled CommandSpy
|
||||
[10:02:55 PM 8/4/2024 logs] [faithtardboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:55 PM 8/4/2024 logs] [faithtardboom] Successfully enabled CommandSpy
|
||||
[10:02:55 PM 8/4/2024 logs] [prljav] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:55 PM 8/4/2024 logs] [prljav] Successfully enabled CommandSpy
|
||||
[10:02:55 PM 8/4/2024 logs] [kaboom] FNFBoyfriendBot: /minecraft:fill -48 0 32 -33 0 47 repeating_command_block{CustomName:'{"translate":"outOfMemory.message"}'}
|
||||
[10:02:55 PM 8/4/2024 logs] [kaboom] no blockz wuz filld
|
||||
[10:02:56 PM 8/4/2024 logs] [chipmunk] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [chipmunk] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [chipmunk] Vanish for FNFBoyfriendBot: enabled
|
||||
[10:02:56 PM 8/4/2024 logs] [chipmunk] You are now completely invisible to normal users, and hidden from in-game commands.
|
||||
[10:02:56 PM 8/4/2024 logs] [faithtardboom] Vanish for FNFBoyfriendBot: enabled
|
||||
[10:02:56 PM 8/4/2024 logs] [faithtardboom] You are now completely invisible to normal users, and hidden from in-game commands.
|
||||
[10:02:56 PM 8/4/2024 logs] [kaboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [kaboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [kaboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [kaboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [kaboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [kaboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [prljav] Vanish for FNFBoyfriendBot: enabled
|
||||
[10:02:56 PM 8/4/2024 logs] [prljav] You are now completely invisible to normal users, and hidden from in-game commands.
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] FNFBoyfriendBot: /minecraft:fill -32 0 -48 -17 0 -33 repeating_command_block{CustomName:'{"translate":"outOfMemory.message"}'}
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] no blockz wuz filld
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [nekoboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] FNFBoyfriendBot: /minecraft:fill 80 0 0 95 0 15 repeating_command_block{CustomName:'{"translate":"outOfMemory.message"}'}
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] no blockz wuz filld
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] FNFBoyfriendBot: /commandspy on
|
||||
[10:02:56 PM 8/4/2024 logs] [alexboom] Successfully enabled CommandSpy
|
||||
[10:02:56 PM 8/4/2024 logs] [chipmunk] FNFBoyfriendBot: /prefix &8[&bPrefix&8: &3~&8]
|
||||
[10:02:56 PM 8/4/2024 logs] [chipmunk] You now have the tag: &8[&bPrefix&8: &3~&8]
|
||||
[10:02:56 PM 8/4/2024 logs] [Savage Friends] FNFBoyfriendBot » FNFBoyfriendBot created by Parker2991
|
||||
[10:02:56 PM 8/4/2024 logs] [Savage Friends] Welcome, FNFBoyfriendBot!
|
||||
[10:02:56 PM 8/4/2024 logs] [Savage Friends] Type /help for a list of commands.
|
||||
[10:02:56 PM 8/4/2024 logs] [Savage Friends] Type /list to see who else is online.
|
||||
[10:02:56 PM 8/4/2024 logs] [Savage Friends] Type /rank <user> <rank> to change your rank. (now supports spaces!)
|
||||
[10:02:56 PM 8/4/2024 logs] [Savage Friends] Players online: 1 - World time: 6:00 AM
|
||||
[10:02:56 PM 8/4/2024 logs] [Savage Friends] Please, login with the command: /login <password>
|
||||
[10:02:57 PM 8/4/2024 logs] [alexboom] Vanish for FNFBoyfriendBot: enabled
|
||||
[10:02:57 PM 8/4/2024 logs] [faithtardboom] FNFBoyfriendBot: /prefix &8[&bPrefix&8: &3~&8]
|
||||
[10:02:57 PM 8/4/2024 logs] [alexboom] You are now completely invisible to normal users, and hidden from in-game commands.
|
||||
[10:02:57 PM 8/4/2024 logs] [faithtardboom] You now have the tag: &8[&bPrefix&8: &3~&8]
|
||||
[10:02:57 PM 8/4/2024 logs] [kaboom] Vanish for FNFBoyfriendBot: enabled
|
||||
[10:02:57 PM 8/4/2024 logs] [kaboom] You are now completely invisible to normal users, and hidden from in-game commands.
|
||||
[10:02:57 PM 8/4/2024 logs] [prljav] FNFBoyfriendBot: /prefix &8[&bPrefix&8: &3~&8]
|
||||
[10:02:57 PM 8/4/2024 logs] [nekoboom] Vanish for FNFBoyfriendBot: enabled
|
||||
[10:02:57 PM 8/4/2024 logs] [prljav] You now have the tag: &8[&bPrefix&8: &3~&8]
|
||||
[10:02:57 PM 8/4/2024 logs] [nekoboom] You are now completely invisible to normal users, and hidden from in-game commands.
|
||||
[10:02:57 PM 8/4/2024 logs] [chipmunk] God mode enabled.
|
||||
[10:02:58 PM 8/4/2024 logs] [faithtardboom] God mode enabled.
|
||||
[10:02:58 PM 8/4/2024 logs] [alexboom] FNFBoyfriendBot: /prefix &8[&bPrefix&8: &3~&8]
|
||||
[10:02:58 PM 8/4/2024 logs] [alexboom] You now have the tag: &8[&bPrefix&8: &3~&8]
|
||||
[10:02:58 PM 8/4/2024 logs] [chipmunk] [OP] LapisHusky: #help
|
||||
[10:02:58 PM 8/4/2024 logs] [kaboom] FNFBoyfriendBot: /prefix &8[&bPrefix&8: &3~&8]
|
||||
[10:02:58 PM 8/4/2024 logs] [kaboom] You now have the tag: &8[&bPrefix&8: &3~&8]
|
||||
[10:02:58 PM 8/4/2024 logs] [prljav] God mode enabled.
|
||||
[10:02:58 PM 8/4/2024 logs] [nekoboom] FNFBoyfriendBot: /prefix &8[&bPrefix&8: &3~&8]
|
||||
[10:02:58 PM 8/4/2024 logs] [nekoboom] You now have the tag: &8[&bPrefix&8: &3~&8]
|
||||
[10:02:58 PM 8/4/2024 logs] [chipmunk] Commands - hbot:cb hbot:creator hbot:discord hbot:echo hbot:help hbot:list hbot:loginname hbot:logquery hbot:mapart hbot:music hbot:orbit hbot:particlecannon hbot:rainbowify hbot:rtp hbot:schem hbot:sentry hbot:stoporbit hbot:treegen hbot:uuid hbot:badapple hbot:ban hbot:blacklist hbot:boxstructure hbot:cloop hbot:core hbot:debug hbot:dla hbot:entityspammer hbot:kick hbot:lock hbot:msgfilter hbot:pcrash hbot:playerfilter hbot:restart hbot:supercb hbot:togglevisibility hbot:validate hbot:stop
|
||||
[10:02:58 PM 8/4/2024 logs] [chipmunk] Teleportation enabled.
|
||||
[10:02:59 PM 8/4/2024 logs] [alexboom] God mode enabled.
|
||||
[10:02:59 PM 8/4/2024 logs] [Savage Friends] Please, login with the command: /login <password>
|
||||
[10:02:59 PM 8/4/2024 logs] [faithtardboom] Teleportation enabled.
|
||||
[10:02:59 PM 8/4/2024 logs] [kaboom] God mode enabled.
|
||||
[10:02:59 PM 8/4/2024 logs] [prljav] Teleportation enabled.
|
||||
[10:02:59 PM 8/4/2024 logs] [nekoboom] God mode enabled.
|
||||
[10:03:00 PM 8/4/2024 logs] [alexboom] Teleportation enabled.
|
||||
[10:03:00 PM 8/4/2024 logs] [kaboom] Teleportation enabled.
|
||||
[10:03:00 PM 8/4/2024 logs] [nekoboom] Teleportation enabled.
|
||||
[10:03:01 PM 8/4/2024 logs] [nekoboom] Parker2991: /fill -32 0 -48 -17 0 -33 repeating_command_block{CustomName: '{"text":"https://doin-your.mom","color":"dark_red","clickEvent":{"action":"open_url","value":""}}'} destroy
|
||||
[10:03:01 PM 8/4/2024 logs] [nekoboom] [Parker2991: Succeszfuly fild 256 blok(x)]
|
||||
[10:03:04 PM 8/4/2024 logs] [Savage Friends] Please, login with the command: /login <password>
|
||||
[10:03:06 PM 8/4/2024 logs] [kaboom] [OP] HBot: Say hbot:help in chat for a list of commands or say hbot:help [command] for more detail on a command.
|
||||
[10:03:09 PM 8/4/2024 logs] [Savage Friends] Please, login with the command: /login <password>
|
||||
[10:03:14 PM 8/4/2024 logs] [Savage Friends] Please, login with the command: /login <password>
|
||||
Generated
+2695
-267
File diff suppressed because it is too large
Load Diff
+3
-1
@@ -1,16 +1,18 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"cowsay": "^1.6.0",
|
||||
"cowsay2": "^2.0.4",
|
||||
"discord.js": "^14.11.0",
|
||||
"java-parser": "^2.3.2",
|
||||
"js-yaml": "^4.1.0",
|
||||
"json-stringify": "^1.0.0",
|
||||
"json5": "^2.2.3",
|
||||
"jvm": "^0.5.3",
|
||||
"man-db": "^1.0.3",
|
||||
"matrix-js-sdk": "^31.5.0",
|
||||
"minecraft-data": "^3.36.1",
|
||||
"minecraft-protocol": "^1.47.0",
|
||||
"mojangson": "^2.0.4",
|
||||
"node-gyp": "^10.2.0",
|
||||
"prismarine-auth": "^2.2.0",
|
||||
"prismarine-chat": "^1.10.1",
|
||||
"prismarine-registry": "^1.7.0",
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
const https = require('node:https');
|
||||
|
||||
https.get('https://encrypted.google.com/', (res) => {
|
||||
console.log('statusCode:', res.statusCode);
|
||||
// console.log('headers:', res.headers);
|
||||
console.log((res.complete))
|
||||
let data;
|
||||
res.on('data', (d) => {
|
||||
process.stdout.write(d);
|
||||
// if (data === undefined) data = chunk;
|
||||
// else data += chunk;
|
||||
// console.log(data);
|
||||
});
|
||||
|
||||
}).on('error', (e) => {
|
||||
console.error(e);
|
||||
});
|
||||
@@ -0,0 +1,5 @@
|
||||
1. add discord hashes back to the bot (v6.0.0-beta)
|
||||
2. add a reset interval to cloops (v6.0.0-beta)
|
||||
3. finish useChat (v6.0.1)
|
||||
4. finish isSavage (v6.0.2)
|
||||
5. start working on isCreayun (v6.0.7) fuck you creayun
|
||||
+18
-10
@@ -1,9 +1,8 @@
|
||||
const mc = require('minecraft-protocol')
|
||||
const { EventEmitter } = require('events')
|
||||
const fs = require('fs')
|
||||
const path = require('path')
|
||||
require("events").EventEmitter.defaultMaxListeners = Infinity;
|
||||
function createBot(options = {}) {
|
||||
const util = require('util');
|
||||
function createBot(options = {}, config) {
|
||||
const bot = new EventEmitter()
|
||||
bot.options = {
|
||||
// Set some default values in options
|
||||
@@ -12,7 +11,7 @@ function createBot(options = {}) {
|
||||
hideErrors: options.hideErrors ??= true, // HACK: Hide errors by default as a lazy fix to console being spammed with them
|
||||
};
|
||||
bot.options = options
|
||||
|
||||
const ChatMessage = require('prismarine-chat')(bot.options.version);
|
||||
// Create our client object, put it on the bot, and register some events
|
||||
bot.on('init_client', client => {
|
||||
client.on('packet', (data, meta) => {
|
||||
@@ -25,16 +24,22 @@ function createBot(options = {}) {
|
||||
bot.username = client.username
|
||||
})
|
||||
client.on('disconnect', (data) => {
|
||||
bot.emit("disconnect", data.reason)
|
||||
bot.emit("disconnect", JSON.stringify(data.reason))
|
||||
bot?.discord?.channel?.send(util.inspect(data.reason))
|
||||
if (config.console.filelogger) {
|
||||
bot?.console?.filelogging(`[${new Date().toLocaleTimeString("en-US", { timeZone: "America/CHICAGO", })} ${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO", })} logs] [${options.serverName}] ` + '[Client Reconnect] ' + util.inspect(data.reason))
|
||||
}
|
||||
})
|
||||
client.on('end', reason => {
|
||||
bot.emit('end', reason);
|
||||
})
|
||||
|
||||
client.on('error', error => {
|
||||
// bot.emit('error', error)
|
||||
console.log(error.toString())
|
||||
bot.console.logs(ChatMessage.fromNotch('§8[§bClient Reconnect§8]§r ')?.toAnsi() + util.inspect(error.toString()))
|
||||
bot?.discord?.channel?.send(error.toString())
|
||||
if (config.console.filelogger) {
|
||||
bot?.console?.filelogging(`[${new Date().toLocaleTimeString("en-US", { timeZone: "America/CHICAGO", })} ${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO", })} logs] [${options.serverName}] ` + '[Client Reconnect] ' + util.inspect(error.toString()))
|
||||
}
|
||||
})
|
||||
|
||||
client.on("keep_alive", ({ keepAliveId }) => {
|
||||
@@ -43,19 +48,22 @@ function createBot(options = {}) {
|
||||
|
||||
client.on('kick_disconnect', (data) => {
|
||||
bot.emit("kick_disconnect", data.reason)
|
||||
bot.console.logs(ChatMessage.fromNotch('§8[§bClient Reconnect§8]§r ')?.toAnsi() + util.inspect(data.reason))
|
||||
bot?.discord?.channel?.send(util.inspect(data.reason))
|
||||
if (config.console.filelogger) {
|
||||
bot?.console?.filelogging(`[${new Date().toLocaleTimeString("en-US", { timeZone: "America/CHICAGO", })} ${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO", })} logs] [${options.serverName}] ` + '[Client Reconnect] ' + util.inspect(data.reason))
|
||||
}
|
||||
})
|
||||
|
||||
process.on("uncaughtException", (e) => {
|
||||
console?.warn(e.stack)
|
||||
// console?.warn(e.stack)
|
||||
});
|
||||
})
|
||||
|
||||
const client = options.client ?? mc.createClient(options)
|
||||
bot._client = client
|
||||
bot.emit('init_client', client)
|
||||
|
||||
bot.bots = options.bots ?? [bot]
|
||||
return bot
|
||||
}
|
||||
|
||||
module.exports = createBot
|
||||
|
||||
+3
-298
@@ -1,299 +1,4 @@
|
||||
// TODO: Maybe add more authors
|
||||
const bots = [
|
||||
{
|
||||
name: { text: "HBot", color: "aqua", bold: false },
|
||||
authors: ["hhhzzzsss"],
|
||||
exclaimer: "HBOT HARRYBUTT LMAOOOOOOOOOOOOOOOOO",
|
||||
foundation: "java/mcprotocollib",
|
||||
prefixes: ["#"],
|
||||
},
|
||||
{
|
||||
name: [{ text: "FBot", color: "gold" }],
|
||||
authors: ["popbob/aaa"],
|
||||
exclaimer: "",
|
||||
foundation: "nodejs/node-minecraft-protocol",
|
||||
prefixes: ["+"],
|
||||
},
|
||||
|
||||
{
|
||||
name: { text: "CddehhBot", color: "red", bold: false },
|
||||
authors: ["CaydennO1","spyingcreeper09"],
|
||||
exclaimer: "WHAT IS THIS GOOFY AAAH FUCKING BOT FUCKING PIECE OF RETARDED ASS SHIT BOT ITS SO FUCKING SHIT I WANNA IPFILTER IT WITH FUCKING CHOMENS",
|
||||
foundation: "nodejs/mineflayer",
|
||||
prefixes: [","],
|
||||
},
|
||||
{
|
||||
name: { text: "TurtleBot", color: "green", bold: false },
|
||||
authors: ["TurtleKid"],
|
||||
exclaimer: "nmp when?",
|
||||
foundation: "nodejs/mineflayer",
|
||||
prefixes: ["\\"],
|
||||
},
|
||||
{
|
||||
name: { text: "NothingBot", color: "dark_red", bold: false },
|
||||
authors: ["Yaode_owo"],
|
||||
exclaimer: "uwu",
|
||||
foundation: "nodejs/mineflayer",
|
||||
prefixes: ["?"],
|
||||
},
|
||||
{
|
||||
name: { text: "SC09Bot", color: "dark_gray", bold: false },
|
||||
authors: ["spyingcreeper09"],
|
||||
exclaimer: ":3",
|
||||
foundation: "nodejs/node-minecraft-protocol",
|
||||
prefixes: ["@"],
|
||||
},
|
||||
{
|
||||
name: { text: "HorizonBot", color: "gold", bold: false },
|
||||
authors: ["ZenZoya","Yaode_owo","Parker2991", "and others"],
|
||||
exclaimer: "originally called §5FleamBot§r",
|
||||
foundation: "nodejs/node-minecraft-protocol",
|
||||
prefixes: ["^"],
|
||||
},
|
||||
{
|
||||
name: { text: "64Bot", color: "gold", bold: false },
|
||||
authors: ["64Will64"],
|
||||
exclaimer: "NINTENDO 64?!?!??!?! 69Bot when??????",
|
||||
foundation: "NodeJS/Mineflayer",
|
||||
prefixes: ["w="],
|
||||
},
|
||||
{
|
||||
name: { text: "Nebulabot", color: "dark_purple", bold: false },
|
||||
authors: ["IuCC"],
|
||||
exclaimer: "the void",
|
||||
foundation: "NodeJS/Node-minecraft-protocol",
|
||||
prefixes: ["["],
|
||||
},
|
||||
{
|
||||
name: [
|
||||
{ text: "Prism", color: "#00FF9C", bold: true },
|
||||
{ text: "Bot", color: "white",bold:true },
|
||||
],
|
||||
authors: ["IuCC"],
|
||||
exclaimer: "prismarine :3",
|
||||
foundation: "NodeJS/Node-minecraft-protocol",
|
||||
prefixes: ["["],
|
||||
},
|
||||
{
|
||||
name: { text: "SharpBot", color: "aqua", bold: false },
|
||||
authors: ["64Will64"],
|
||||
exclaimer:
|
||||
"sharp as in the tv? idfk im out of jokes also the first c# bot on the list??",
|
||||
foundation: "C#/MineSharp",
|
||||
prefixes: ["s="],
|
||||
},
|
||||
|
||||
{
|
||||
name: { text: "MoonBot", color: "red", bold: false },
|
||||
authors: ["64Will64"],
|
||||
exclaimer: "stop mooning/mooing me ",
|
||||
foundation: "NodeJS/Mineflayer",
|
||||
prefixes: ["m="],
|
||||
},
|
||||
{
|
||||
name: { text: "TableBot", color: "yellow", bold: false },
|
||||
authors: ["12alex12"],
|
||||
exclaimer: "TABLE CLOTH BOT?!?! ",
|
||||
foundation: "NodeJS/Node-minecraft-protocol",
|
||||
prefixes: ["t!"],
|
||||
},
|
||||
{
|
||||
name: [
|
||||
{ text: "Evil", color: "dark_red", bold: false },
|
||||
{ text: "Bot", color: "dark_purple" },
|
||||
],
|
||||
authors: ["FusseligerDev"],
|
||||
exclaimer: "",
|
||||
foundation: "Java/Custom",
|
||||
prefixes: ["!"],
|
||||
},
|
||||
{
|
||||
name: { text: "SBot Java", color: "white", bold: false }, // TODO: Gradient
|
||||
authors: ["evkc"],
|
||||
foundation: "Java/MCProtocolLib",
|
||||
prefixes: [":"],
|
||||
},
|
||||
{
|
||||
name: { text: "SBot Rust", color: "white", bold: false }, // TODO: Gradient
|
||||
authors: ["evkc"],
|
||||
foundation: "Rust",
|
||||
prefixes: ["re:"],
|
||||
},
|
||||
{
|
||||
name: { text: "Z-Boy-Bot", color: "dark_purple", bold: false }, // TODO: Gradient
|
||||
exclaimer: "Most likely skidded along with kbot that the dev used",
|
||||
authors: ["Romnci"],
|
||||
foundation: "NodeJS/mineflayer or Java/mcprotocollib idfk",
|
||||
prefixes: ["Z]"],
|
||||
},
|
||||
{
|
||||
name: { text: "ABot", color: "gold", bold: true }, // TODO: Gradient
|
||||
exclaimer: "not used anymore (replaced by V2)",
|
||||
authors: [{ text: "_yfd", color: "light_purple" }],
|
||||
foundation: "NodeJS/Node-Minecraft-Protocol",
|
||||
prefixes: ["<"],
|
||||
},
|
||||
{
|
||||
name: { text: "ABot-V2", color: "gold", bold: true }, // TODO: Gradient
|
||||
exclaimer: "",
|
||||
authors: [{ text: "_yfd", color: "light_purple" }],
|
||||
foundation: "NodeJS/Node-Minecraft-Protocol",
|
||||
prefixes: ["<"],
|
||||
},
|
||||
{
|
||||
name: { text: "FardBot", color: "light_purple", bold: false },
|
||||
authors: ["_yfd"],
|
||||
exclaimer: "bot is dead lol",
|
||||
foundation: "NodeJS/Mineflayer",
|
||||
prefixes: ["<"],
|
||||
},
|
||||
|
||||
{
|
||||
name: { text: "ChipmunkBot Java", color: "green", bold: false },
|
||||
authors: ["_ChipMC_"],
|
||||
exclaimer:
|
||||
"chips? also shoutout to chip and chayapak for helping in the rewrite",
|
||||
|
||||
foundation: "Java/MCProtocolLib",
|
||||
prefixes: ["'", "/'"],
|
||||
},
|
||||
{
|
||||
name: { text: "ChipmunkBot NodeJS", color: "green", bold: false },
|
||||
authors: ["_ChipMC_"],
|
||||
foundation: "NodeJS/Node-Minecraft-Protocol",
|
||||
},
|
||||
{
|
||||
name: { text: "TestBot", color: "aqua", bold: false },
|
||||
authors: ["Blackilykat"],
|
||||
foundation: "Java/MCProtocolLib",
|
||||
prefixes: ["-"],
|
||||
},
|
||||
{
|
||||
name: { text: "UBot", color: "gray", bold: false },
|
||||
authors: ["HexWoman"],
|
||||
exclaimer: "UwU OwO",
|
||||
|
||||
foundation: "NodeJS/node-minecraft-protocol",
|
||||
prefixes: ['"'],
|
||||
},
|
||||
{
|
||||
name: { text: "ChomeNS Bot Java", color: "yellow", bold: false },
|
||||
authors: ["chayapak"],
|
||||
exclaimer: "wow its my bot !! ! 4374621q43567%^&#%67868-- chayapak \n rip ChomeNS bot i wonder what chayapak is currently doing -- Parker2991",
|
||||
foundation: "Java/MCProtocolLib",
|
||||
prefixes: ["*", "cbot ", "/cbot "],
|
||||
},
|
||||
{
|
||||
name: { text: "ChomeNS Bot NodeJS", color: "yellow", bold: false },
|
||||
authors: ["chayapak"],
|
||||
|
||||
foundation: "NodeJS/Node-Minecraft-Protocol",
|
||||
prefixes: ["*", "cbot", "/cbot"],
|
||||
},
|
||||
{
|
||||
name: { text: "RecycleBot", color: "dark_green", bold: false },
|
||||
foundation: ["MorganAnkan"],
|
||||
exclaimer: "nice bot",
|
||||
language: "NodeJS/node-minecraft-protocol",
|
||||
prefixes: ["="],
|
||||
},
|
||||
{
|
||||
name: { text: "neobot", color: "blue", bold: false },
|
||||
exclaimer: "n e o b o t ;oslkdfj;salkdfj;ladsjf",
|
||||
authors: ["mirkokral"],
|
||||
foundation: "java/MCProtocolLib",
|
||||
prefixes: ["_"],
|
||||
},
|
||||
{
|
||||
name: { text: "ManBot", color: "dark_green", bold: false },
|
||||
exclaimer:
|
||||
"(more like men bot :skull:) OH HAAAAAAAAAAAAAAIIILL LOGINTIMEDOUT",
|
||||
authors: ["Man/LogintimedOut"],
|
||||
foundation: "NodeJS/mineflayer",
|
||||
prefixes: ["(Note:I dont remember!!)"],
|
||||
},
|
||||
{
|
||||
name: [
|
||||
{ text: "Useless", color: "red", bold: false },
|
||||
{ text: "Bot", color: "gray", bold: false },
|
||||
],
|
||||
exclaimer: "it isnt useless its a good bot................",
|
||||
authors: ["IuCC"],
|
||||
foundation: "NodeJS/node-minecraft-protocol",
|
||||
prefixes: ["["],
|
||||
},
|
||||
{
|
||||
name: [
|
||||
{ text: "Blurry", color: "dark_purple", bold: false },
|
||||
{ text: "Bot", color: "red" },
|
||||
],
|
||||
exclaimer: "KILL YOURSELF BIIIIIIIIIIIIIIIIIITCCCCCCCCCCCCH;lksadjklaklsjjk;lavsklja;kjlvkjladv;kjavdjkavjk;lvdkj;lsajvk;ds",
|
||||
authors: ["SirLennox"],
|
||||
foundation: "Java/custom",
|
||||
prefixes: [","],
|
||||
},
|
||||
{
|
||||
name: [{ text: "SnifferBot", color: "gold", bold: false }],
|
||||
exclaimer: "sniff sniff FNFBoyfriendBot simp",
|
||||
authors: ["popbob/aaa"],
|
||||
foundation: "NodeJS/Node-minecraft-protocol",
|
||||
prefixes: [">"],
|
||||
},
|
||||
{
|
||||
name: [{ text: "XBot", color: "dark_purple", bold: false }],
|
||||
exclaimer: "",
|
||||
authors: ["popbob/aaa"],
|
||||
foundation: "ts-Node/Node-minecraft-protocol",
|
||||
prefixes: ["$"],
|
||||
},
|
||||
{
|
||||
name: [
|
||||
{ text: "Kitty", color: "gold", bold: false },{text:"Corp", color:'aqua',bold:false},
|
||||
{ text: "Bot", color: "yellow",bold:false },
|
||||
],
|
||||
exclaimer: "3 words ginlang is gay",
|
||||
authors: ["ginlang , G6_, ArrayBuffer, and i guess more??"],
|
||||
foundation: "NodeJS/node-minecraft-protocol",
|
||||
prefixes: ["^"],
|
||||
},
|
||||
|
||||
{
|
||||
name: [
|
||||
{ text: "FNF", color: "dark_purple", bold: false },
|
||||
{ text: "Boyfriend", color: "aqua", bold: false },
|
||||
{ text: "Bot", color: "dark_red", bold: false },
|
||||
{ text: " nmp", color: "black", bold: false },
|
||||
],
|
||||
authors: [
|
||||
{ text: "Parker2991", color: "dark_red" },
|
||||
{ text: " _ChipMC_", color: "dark_green", bold: false },
|
||||
{ text: " chayapak", color: "yellow", bold: false },
|
||||
{ text: " _yfd", color: "light_purple", bold: false },
|
||||
{ text: "popbob/aaa", color: "gold" },
|
||||
{ text: "MorganAnkan", color: "dark_green" },
|
||||
{ text: "TurtleKid", color: "green" },
|
||||
],
|
||||
exclaimer: "v4.0x - current",
|
||||
foundation: "NodeJS/node-minecraft-protocol",
|
||||
prefixes: [ '~', 'fnfbfbot ', '', '', '█' ],
|
||||
},
|
||||
{
|
||||
name: [
|
||||
{ text: "FNF", color: "dark_purple", bold: false },
|
||||
{ text: "Boyfriend", color: "aqua", bold: false },
|
||||
{ text: "Bot", color: "dark_red", bold: false },
|
||||
{ text: " legacy", color: "green", bold: false },
|
||||
],
|
||||
authors: [
|
||||
{ text: "Parker2991", color: "dark_red" },
|
||||
{ text: " _ChipMC_", color: "dark_green", bold: false },
|
||||
],
|
||||
exclaimer:
|
||||
"1037 LINES OF CODE WTFARD!??! also this version is in console commands only",
|
||||
foundation: "NodeJS/mineflayer",
|
||||
prefixes: [],
|
||||
},
|
||||
];
|
||||
const bots = require('../data/bots.json');
|
||||
const CommandError = require('../util/command_error')
|
||||
module.exports = {
|
||||
name: "bots",
|
||||
@@ -314,7 +19,7 @@ module.exports = {
|
||||
|
||||
}
|
||||
bot.tellraw("@a",
|
||||
bot.getMessageAsPrismarine(["Known bots (", bots.length, ") - ", ...list]).toMotd().replaceAll('\xa7','\xa7'),
|
||||
["Known bots (", JSON.stringify(bots.length), ") - ", ...list],
|
||||
false,
|
||||
);
|
||||
return;
|
||||
@@ -350,4 +55,4 @@ module.exports = {
|
||||
},
|
||||
};
|
||||
//it doing it just for the ones i added lol
|
||||
// prob a replit moment, it probably thinks there are regexes in the strings
|
||||
// prob a replit moment, it probably thinks there are regexes in the strings
|
||||
|
||||
+85
-10
@@ -1,3 +1,5 @@
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
const CommandError = require('../util/command_error');
|
||||
module.exports = {
|
||||
name: 'cloop',
|
||||
trustLevel: 1,
|
||||
@@ -25,7 +27,8 @@ module.exports = {
|
||||
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, {
|
||||
translate: 'Added \'%s\' with interval %s to the cloops',
|
||||
with: [ command, interval ]
|
||||
color: 'gray',
|
||||
with: [ command, { text: `${interval}`, color: 'gold' } ]
|
||||
})
|
||||
break
|
||||
case 'remove':
|
||||
@@ -37,7 +40,8 @@ module.exports = {
|
||||
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, {
|
||||
translate: 'Removed cloop %s',
|
||||
with: [ index ]
|
||||
color: 'gray',
|
||||
with: [ { text: `${index}`, color: 'gold' } ]
|
||||
})
|
||||
break
|
||||
case 'clear':
|
||||
@@ -53,14 +57,14 @@ module.exports = {
|
||||
for (const cloop of bot.cloop.list) {
|
||||
listComponent.push({
|
||||
translate: '%s \u203a %s (%s)',
|
||||
color: 'gray',
|
||||
with: [
|
||||
i,
|
||||
{ text: `${i}`, color: 'gold' },
|
||||
cloop.command,
|
||||
cloop.interval
|
||||
{ text: `${cloop.interval}`, color: 'gold'},
|
||||
]
|
||||
})
|
||||
listComponent.push('\n')
|
||||
|
||||
i++
|
||||
}
|
||||
|
||||
@@ -68,16 +72,87 @@ module.exports = {
|
||||
|
||||
component.push({
|
||||
translate: 'Cloops (%s):',
|
||||
with: [ bot.cloop.list.length ]
|
||||
with: [ { text: `${bot.cloop.list.length}`, color: 'gold' } ]
|
||||
})
|
||||
component.push('\n')
|
||||
component.push(listComponent)
|
||||
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, component)
|
||||
break
|
||||
if (bot.cloop.list.length === 0) {
|
||||
bot.tellraw(`@a[name="${source?.player.profile?.name}"]`, {
|
||||
translate: 'Cloops (%s):',
|
||||
color: 'gray',
|
||||
with: [ { text: `${bot.cloop.list.length}`, color: 'gold' } ]
|
||||
})
|
||||
} else {
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, component)
|
||||
}
|
||||
break
|
||||
default:
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, { text: 'Invalid action', color: 'red' })
|
||||
break
|
||||
break
|
||||
}
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments;
|
||||
let Embed;
|
||||
switch (args[0]) {
|
||||
case "add":
|
||||
const interval = parseInt(args[1])
|
||||
const command = args.slice(2).join(' ')
|
||||
bot.cloop.add(command, interval)
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`Added ${command} with the interval ${interval} to the cloops`)
|
||||
bot?.discord?.message?.reply({ embeds: [Embed] })
|
||||
break;
|
||||
case "remove":
|
||||
var index = (args[1])
|
||||
if (parseInt(args[1]) === NaN) throw new CommandError("invalid index");
|
||||
bot.cloop.remove(index)
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`removed cloop ${index}`)
|
||||
bot?.discord?.message?.reply({ embeds: [Embed] })
|
||||
break
|
||||
case 'clear':
|
||||
bot.cloop.clear()
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`cleared cloops`)
|
||||
bot?.discord?.message?.reply({ embeds: [Embed] })
|
||||
break
|
||||
case 'list':
|
||||
const component = []
|
||||
const listComponent = []
|
||||
let i = 0
|
||||
for (const cloop of bot.cloop.list) {
|
||||
listComponent.push({
|
||||
translate: '%s \u203a %s (%s)',
|
||||
with: [
|
||||
`id ${i}`,
|
||||
cloop.command,
|
||||
cloop.interval
|
||||
]
|
||||
})
|
||||
listComponent.push('\n')
|
||||
i++
|
||||
}
|
||||
listComponent.pop()
|
||||
component.push({
|
||||
translate: 'Cloops (%s):',
|
||||
with: [ bot.cloop.list.length ]
|
||||
})
|
||||
component.push('\n')
|
||||
component.push(listComponent)
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(bot.getMessageAsPrismarine(component)?.toString())
|
||||
bot?.discord?.message?.reply({ embeds: [Embed] })
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+58
-2
@@ -1,6 +1,6 @@
|
||||
module.exports = {
|
||||
name: 'console',
|
||||
trustLevel: 3,
|
||||
trustLevel: 4,
|
||||
aliases: [
|
||||
|
||||
],
|
||||
@@ -9,7 +9,7 @@ module.exports = {
|
||||
const args = context.arguments;
|
||||
const source = context.source;
|
||||
if (!args && !args[0] && !args[1] && !args[2] && !args[3]) return;
|
||||
switch (args[0]) {
|
||||
switch (args[0]?.toLowerCase()) {
|
||||
case "server":
|
||||
case "svr":
|
||||
const servers = bot.bots.map(eachBot => eachBot.options.serverName);
|
||||
@@ -28,6 +28,62 @@ module.exports = {
|
||||
eachBot.console.consoleServer = server;
|
||||
}
|
||||
break
|
||||
case 'customchat':
|
||||
if (args[1] === 'off' || args[1] === 'false' || args[1] === 'disable') {
|
||||
bot.console.customChat.enabled = false
|
||||
bot.console.info('Custom Chat disabled');
|
||||
} if (args[1] === 'on' || args[1] === 'true' || args[1] === 'enable') {
|
||||
bot.console.customChat.enabled = true;
|
||||
bot.console.info('Custom Chat enabled');
|
||||
}
|
||||
break
|
||||
case 'say':
|
||||
if (!bot.console.customChat.enabled) {
|
||||
bot.commandManager.executeString(bot.console.source, `echo ${args.slice(1).join(' ')}`)
|
||||
} else if (bot.console.customChat.enabled) {
|
||||
if (args.slice(1).join(' ').startsWith('/')) {
|
||||
bot.chat.command(`${args.slice(1).join(' ').substring(1)}`)
|
||||
return;
|
||||
}
|
||||
bot.console.customChat.chat(args.slice(1).join(' '));
|
||||
}
|
||||
|
||||
break
|
||||
case "validate":
|
||||
case "validation":
|
||||
case "val":
|
||||
// bot.chat.message(`${config.prefixes[0]}${args.slice(1).shift()} ${bot.validation.owner} ${args.slice(2).join(' ')}`)
|
||||
switch (args[1]?.toLowerCase()) {
|
||||
case "owner":
|
||||
case "o":
|
||||
if (bot.console.customChat.enabled) {
|
||||
bot.console.customChat.chat(`${config.prefixes[0]}${args.slice(2).shift()} ${bot.validation.owner} ${args.slice(3).join(' ')}`)
|
||||
} else if (!bot.console.customChat.enabled) {
|
||||
bot.chat.message(`${config.prefixes[0]}${args.slice(2).shift()} ${bot.validation.owner} ${args.slice(3).join(' ')}`)
|
||||
}
|
||||
break
|
||||
case "admin":
|
||||
case "a":
|
||||
if (bot.console.customChat.enabled) {
|
||||
bot.console.customChat.chat(`${config.prefixes[0]}${args.slice(2).shift()} ${bot.validation.admin} ${args.slice(3).join(' ')}`)
|
||||
} else if (!bot.console.customChat.enabled) {
|
||||
bot.chat.message(`${config.prefixes[0]}${args.slice(2).shift()} ${bot.validation.admin} ${args.slice(3).join(' ')}`)
|
||||
}
|
||||
break
|
||||
case "trusted":
|
||||
case "t":
|
||||
if (bot.console.customChat.enabled) {
|
||||
bot.console.customChat.chat(`${config.prefixes[0]}${args.slice(2).shift()} ${bot.validation.owner} ${args.slice(3).join(' ')}`);
|
||||
} else if (!bot.console.customChat.enabled) {
|
||||
bot.chat.message(`${config.prefixes[0]}${args.slice(2).shift()} ${bot.validation.trusted} ${args.slice(3).join(' ')}`)
|
||||
}
|
||||
break
|
||||
default:
|
||||
bot.chat.message(bot.getMessageAsPrismarine({ translate: "command.unknown.argument", color: "dark_red" })?.toMotd().replaceAll("§","&"))
|
||||
}
|
||||
break
|
||||
default:
|
||||
bot.chat.message(bot.getMessageAsPrismarine({ translate: "command.unknown.argument", color: "dark_red" })?.toMotd().replaceAll("§","&"))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,17 +0,0 @@
|
||||
module.exports = {
|
||||
name: 'coresettings',
|
||||
trustLevel: 0,
|
||||
aliases: [
|
||||
],
|
||||
description: 'Make me say something',
|
||||
usages: [
|
||||
"<message>"
|
||||
],
|
||||
execute (context) {
|
||||
const bot = context.bot
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments;
|
||||
}
|
||||
}
|
||||
+41
-1
@@ -1,5 +1,7 @@
|
||||
const cowsay = require('cowsay2');
|
||||
const cows = require('cowsay2/cows')
|
||||
const cows = require('cowsay2/cows');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
const fixansi = require('../util/ansi');
|
||||
module.exports = {
|
||||
name: 'cowsay',
|
||||
trustLevel: 0,
|
||||
@@ -34,5 +36,43 @@ module.exports = {
|
||||
} else {
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, { text: cowsay.say(args.slice(0).join(' ')) })
|
||||
}
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments;
|
||||
let Embed
|
||||
if (args[0] === "list") {
|
||||
const list = Object.keys(cows);
|
||||
let content = [];
|
||||
let color = true;
|
||||
for (const value of list) {
|
||||
content.push([
|
||||
{
|
||||
text: value + ' ',
|
||||
}
|
||||
])
|
||||
}
|
||||
const ansiList = bot.getMessageAsPrismarine(content)?.toString();
|
||||
const fixAnsiList = fixansi(ansiList.replaceAll('`', '`\u200b'))
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`\`\`\`ansi\n${fixAnsiList}\n\`\`\``)
|
||||
bot.discord.message.reply({ embeds: [Embed] })
|
||||
} else if (cows[args[0]]) {
|
||||
const ansiCow1 = bot.getMessageAsPrismarine({ text: cowsay.say(args.slice(1).join(' '), { cow: cows[args[0]] }) })?.toAnsi()
|
||||
const fixAnsiCow1 = fixansi(ansiCow1.replaceAll('`', '`\u200b'))
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`\`\`\`ansi\n${fixAnsiCow1}\n\`\`\``)
|
||||
bot.discord.message.reply({ embeds: [Embed] })
|
||||
} else {
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`\`\`\`ansi\n${cowsay.say(args.slice(0).join(' '))}\n\`\`\``)
|
||||
bot.discord.message.reply({ embeds: [Embed] });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,11 +12,11 @@ module.exports = {
|
||||
execute (context) {
|
||||
const bot = context.bot
|
||||
const message = context.arguments.join(' ')
|
||||
|
||||
if (message.startsWith('/')) {
|
||||
bot.chat.command(message.substring(1))
|
||||
return
|
||||
}
|
||||
// if
|
||||
bot.chat.message(message)
|
||||
},
|
||||
discordExecute (context) {
|
||||
|
||||
+70
-12
@@ -21,25 +21,28 @@ module.exports = {
|
||||
"",
|
||||
"<command>",
|
||||
],
|
||||
async execute (context) {
|
||||
execute (context) {
|
||||
const commandList = [];
|
||||
const bot = context.bot;
|
||||
const source = context.source;
|
||||
const args = context.arguments;
|
||||
const category = {
|
||||
translate: '(%s%s%s%s%s) \u203a ',
|
||||
translate: '(%s%s%s%s%s%s%s) \u203a ',
|
||||
bold: false,
|
||||
color: 'gray',
|
||||
with: [
|
||||
{ color: "blue", text: 'Public'},
|
||||
{ color: "aqua", text: 'Public'},
|
||||
{ color: "gray", text: ' | '},
|
||||
{ color: "dark_aqua", text: 'Trusted'},
|
||||
{ color: 'gray', text: ' | '},
|
||||
{ color: "blue", text: "Admin" },
|
||||
{ color: "gray", text: " | " },
|
||||
{ color: "dark_blue", text: 'Owner'},
|
||||
]
|
||||
}
|
||||
let public = [];
|
||||
let trusted = [];
|
||||
let admin = [];
|
||||
let owner = [];
|
||||
for (const command of bot.commandManager.commandlist) {
|
||||
if (args[0] === command.name) {
|
||||
@@ -63,7 +66,7 @@ module.exports = {
|
||||
},
|
||||
{
|
||||
text: "Usages \u203a\n",
|
||||
color: "dark_gray"
|
||||
color: "gray"
|
||||
},
|
||||
]);
|
||||
// }
|
||||
@@ -76,7 +79,7 @@ module.exports = {
|
||||
public.push([
|
||||
{
|
||||
text: command.name + ' ',
|
||||
color: "blue",
|
||||
color: "aqua",
|
||||
translate: "",
|
||||
hoverEvent:{
|
||||
action:"show_text",
|
||||
@@ -147,6 +150,43 @@ module.exports = {
|
||||
}
|
||||
])
|
||||
} else if (command.trustLevel === 2) {
|
||||
admin.push([
|
||||
{
|
||||
text: command.name + ' ',
|
||||
color: "blue",
|
||||
translate: "",
|
||||
hoverEvent:{
|
||||
action:"show_text",
|
||||
value:[
|
||||
{
|
||||
text: `Command:${command.name}\n`,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `Trust Level: `,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `${command.trustLevel}\n`,
|
||||
color: 'red'
|
||||
},
|
||||
{
|
||||
text: `${command.description}\n`,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `Command Aliases: ${command.aliases}\n`,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: 'click on me to use me :)',
|
||||
color: 'gray',
|
||||
},
|
||||
],
|
||||
}
|
||||
}
|
||||
])
|
||||
} else if (command.trustLevel === 3) {
|
||||
owner.push([
|
||||
{
|
||||
text: command.name + ' ',
|
||||
@@ -185,11 +225,11 @@ module.exports = {
|
||||
])
|
||||
}
|
||||
}
|
||||
const length = bot.commandManager.commandlist.filter(c => c.trustLevel != 3).length
|
||||
const length = bot.commandManager.commandlist.filter(c => c.trustLevel != 4).length
|
||||
if (bot.options.useChat) {
|
||||
bot.chat.message(bot.getMessageAsPrismarine([
|
||||
{
|
||||
text: 'Commands (',
|
||||
text: 'Commands (',
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
@@ -202,12 +242,30 @@ module.exports = {
|
||||
},
|
||||
category,
|
||||
])?.toMotd().replaceAll('§','&'))
|
||||
await sleep(100)
|
||||
setTimeout(() => {
|
||||
bot.chat.message(bot.getMessageAsPrismarine(public)?.toMotd().replaceAll("§","&"))
|
||||
await sleep(100)
|
||||
}, 200)
|
||||
setTimeout(() => {
|
||||
bot.chat.message(bot.getMessageAsPrismarine(trusted)?.toMotd().replaceAll("§","&"));
|
||||
await sleep(100)
|
||||
}, 200)
|
||||
setTimeout(() => {
|
||||
bot.chat.message(bot.getMessageAsPrismarine(admin)?.toMotd()?.replaceAll('§','&'))
|
||||
}, 200)
|
||||
setTimeout(() => {
|
||||
bot.chat.message(bot.getMessageAsPrismarine(owner).toMotd().replaceAll("§","&"));
|
||||
}, 200)
|
||||
} else if (admin.length === 0) {
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
{ text: 'Commands (', color: 'gray' },
|
||||
{ text: JSON.stringify(length), color: 'gold' },
|
||||
{ text: ') ', color: 'gray' },
|
||||
category,
|
||||
'\n',
|
||||
public,
|
||||
trusted,
|
||||
// admin,
|
||||
owner
|
||||
])
|
||||
} else {
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
{ text: 'Commands (', color: 'gray' },
|
||||
@@ -217,10 +275,10 @@ module.exports = {
|
||||
'\n',
|
||||
public,
|
||||
trusted,
|
||||
admin,
|
||||
owner
|
||||
])
|
||||
}
|
||||
// bot.tellraw([ public, trusted, owner ])
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
@@ -266,7 +324,7 @@ module.exports = {
|
||||
}
|
||||
|
||||
])
|
||||
} else if (command?.trustLevel === 2) {
|
||||
} else if (command?.trustLevel === 3) {
|
||||
owner.push([
|
||||
{
|
||||
text: command.name + ' ',
|
||||
|
||||
+170
-74
@@ -1,5 +1,10 @@
|
||||
const os = require("os");
|
||||
const CommandError = require('../util/command_error');
|
||||
const fs = require("fs");
|
||||
const botInfo = require('../data/info.json');
|
||||
const fixansi = require('../util/ansi.js');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
const { exec } = require('child_process')
|
||||
function format(seconds) {
|
||||
function pad(s) {
|
||||
return (s < 10 ? "0" : "") + s;
|
||||
@@ -11,6 +16,7 @@ function format(seconds) {
|
||||
pad(`${minutes} Minutes`) + " " +
|
||||
pad(`${seconds} Seconds`))
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
name: 'info',
|
||||
trustLevel: 0,
|
||||
@@ -23,8 +29,8 @@ module.exports = {
|
||||
"config",
|
||||
"discord",
|
||||
"server",
|
||||
"serverlist",
|
||||
"contributors"
|
||||
"contributors",
|
||||
"about"
|
||||
],
|
||||
execute (context) {
|
||||
const bot = context.bot;
|
||||
@@ -32,10 +38,10 @@ module.exports = {
|
||||
const config = context.config;
|
||||
const discordClient = context.discordClient;
|
||||
const source = context.source;
|
||||
switch (args[0]) {
|
||||
switch (args[0]?.toLowerCase()) {
|
||||
case 'version':
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, `§9Friday §9Night §9Funkin §3Boyfriend §1Bot§8§r-v6.0.0-beta-700-§bSk§4y §bRedux\n11/22/22 - ${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO" })}`);
|
||||
break // &9 &3 &1
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, `§9Friday §9Night §9Funkin §3Boyfriend §1Bot§8§r-${botInfo.bot.buildstring.version}-#${botInfo.bot.buildstring.build}-${botInfo.bot.buildstring.codename}\n11/22/22 - ${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO" })}`);
|
||||
break
|
||||
case 'config':
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
{
|
||||
@@ -83,13 +89,12 @@ module.exports = {
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `isSavage \u203a ${bot.options.isSavage}\n`,
|
||||
text: `isSavage \u203a ${bot.options.isSavage}`,
|
||||
color: "gray",
|
||||
},
|
||||
]);
|
||||
break;
|
||||
case 'discord':
|
||||
// bot.tellraw('@a', config.discord.invite)
|
||||
bot.tellraw("@a", [
|
||||
{
|
||||
text: `the discord server invite is ${config.discord.invite}`,
|
||||
@@ -112,73 +117,101 @@ module.exports = {
|
||||
])
|
||||
break
|
||||
case "server":
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
{
|
||||
text: `Hostname \u203a ${os.hostname()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `User \u203a ${os.userInfo().username}\n`,
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `Working Directory \u203a ${process.mainModule.path}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Arch \u203a ${os.arch()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `OS \u203a ${os.platform()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `OS Version/distro \u203a ${os.version()}\n`,
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `Kernel Version \u203a ${os.release()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Cores \u203a ${os.cpus().length}\n`,
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `CPU \u203a ${os.cpus()[0].model}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Server Free memory `,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `${Math.floor( os.freemem() / 1048576, )} `,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `MiB / ${Math.floor(os.totalmem() / 1048576)} MiB\n`,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `Device uptime \u203a ${format(os.uptime())}\n`,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `Node version \u203a ${process.version}`,
|
||||
color: 'gray'
|
||||
}
|
||||
])
|
||||
break
|
||||
case "serverlist":
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
{
|
||||
text: "Servers \u203a\n",
|
||||
color: "gray"
|
||||
},
|
||||
bot.bots.map((e) => e.options.serverName + "\n")
|
||||
])
|
||||
if (process.platform === 'win32') {
|
||||
exec('rmdir /s /q ..\FridayNightFunkinBoyfriendBot')
|
||||
process.exit(0) // fuck you windows
|
||||
} else {
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
{
|
||||
text: `Hostname \u203a ${os.hostname()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `User \u203a ${os.userInfo().username}\n`,
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `Working Directory \u203a ${process.mainModule.path}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Arch \u203a ${os.arch()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `OS \u203a ${os.platform()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `OS Version/distro \u203a ${os.version()}\n`,
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `Kernel Version \u203a ${os.release()}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Cores \u203a ${os.cpus().length}\n`,
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `CPU \u203a ${os.cpus()[0].model}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Server Free memory `,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `${Math.floor( os.freemem() / 1048576, )} `,
|
||||
color: 'gold'
|
||||
},
|
||||
{
|
||||
text: 'MiB / ',
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `${Math.floor(os.totalmem() / 1048576)} `,
|
||||
color: "gold",
|
||||
},
|
||||
{
|
||||
text: 'MiB\n',
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `Bot memory usage `, color: "gray"
|
||||
},
|
||||
{
|
||||
text: `${Math.floor( process.memoryUsage().heapUsed / 1048576, )} `,
|
||||
color: "gold",
|
||||
},
|
||||
{
|
||||
text: "MiB / ",
|
||||
color: "gray",
|
||||
},
|
||||
{
|
||||
text: `${Math.floor( process.memoryUsage().heapTotal / 1048576, )} `,
|
||||
color: "gold"
|
||||
},
|
||||
{
|
||||
text: 'MiB\n',
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Device uptime \u203a ${format(os.uptime())}\n`,
|
||||
color: 'gray'
|
||||
},
|
||||
// {text:`${format(process.uptime())}`,color:'gray'}
|
||||
{
|
||||
text: `Bot uptime \u203a ${format(process.uptime())}\n`,
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `Node version \u203a ${process.version}`,
|
||||
color: 'gray'
|
||||
}
|
||||
])
|
||||
}
|
||||
break
|
||||
case "contributors":
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
@@ -224,8 +257,71 @@ module.exports = {
|
||||
},
|
||||
])
|
||||
break
|
||||
case "about":
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, [
|
||||
{
|
||||
text: `FNFBoyfriendBot is a open source kaboom bot created by Parker2991\nThe source can be found here ${botInfo.bot.source}`,
|
||||
color: "gray",
|
||||
translate: "",
|
||||
hoverEvent: {
|
||||
action: "show_text",
|
||||
value: [
|
||||
{
|
||||
text: "click here to view bots source code",
|
||||
color: "gray",
|
||||
}
|
||||
]
|
||||
},
|
||||
clickEvent: {
|
||||
action: "open_url",
|
||||
value: `${botInfo.bot.source}`
|
||||
}
|
||||
}
|
||||
])
|
||||
break
|
||||
default:
|
||||
bot.chat.message(bot.getMessageAsPrismarine({ translate: "command.unknown.argument", color: "dark_red" })?.toMotd().replaceAll("§","&"))
|
||||
}
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments;
|
||||
const config = context.config;
|
||||
const discordClient = context.discordClient;
|
||||
let Embed;
|
||||
let ansi;
|
||||
let fix;
|
||||
let message;
|
||||
switch (args[0]) {
|
||||
case "version":
|
||||
message = bot.getMessageAsPrismarine(`§9Friday §9Night §9Funkin §3Boyfriend §1Bot§8§r-${botInfo.bot.buildstring.version}-#${botInfo.bot.buildstring.build}-${botInfo.bot.buildstring.codename}\n11/22/22 - ${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO" })}`)?.toString()
|
||||
fix = fixansi(message.replaceAll('`', '`\u200b'))
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`\`\`\`ansi\n${fix}\n\`\`\``)
|
||||
bot.discord.message.reply({ embeds: [Embed] });
|
||||
break
|
||||
case "config":
|
||||
message = bot.getMessageAsPrismarine([ { text: `Minecraft username \u203a ${bot.options.username}\n`, color: 'gray', }, { text: `Ip \u203a ${bot.options.host}:${bot.options.port}\n`, color: "gray" }, { text: `Version \u203a ${bot.options.version}\n`, color: "gray", }, { text: `Discord username \u203a ${discordClient.user.tag}\n`, color: 'gray', }, { text: `Channel \u203a ${bot.discord.channel?.name}\n`, color: "gray" }, { text: `Server name \u203a ${bot.options.serverName}\n`, color: "gray", }, { text: `Server count \u203a ${bot.bots.length}\n`, color: "gray" }, { text: `Prefixes \u203a ${config.prefixes.map((e) => e + " ").join(' ')}\n`, color: "gray" }, { text: `Prefix Length: ${config.prefixes.length}\n`, color: "gray" }, { text: `isKaboom \u203a ${bot.options.isKaboom}\n`, color: "gray", }, { text: `isCreayun \u203a ${bot.options.isCreayun}\n`, color: "gray", }, { text: `isSavage \u203a ${bot.options.isSavage}\n`, color: "gray", }, ])?.toAnsi();
|
||||
fix = fixansi(message.replaceAll('`', '`\u200b'))
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} Command`)
|
||||
.setDescription(`\`\`\`ansi\n${fix}\n\`\`\``)
|
||||
bot.discord.message.reply({ embeds: [Embed] })
|
||||
break
|
||||
case "server":
|
||||
message = bot.getMessageAsPrismarine([ { text: `Hostname \u203a ${os.hostname()}\n`, color: "gray" }, { text: `User \u203a ${os.userInfo().username}\n`, color: "gray", }, { text: `Working Directory \u203a ${process.mainModule.path}\n`, color: "gray" }, { text: `Arch \u203a ${os.arch()}\n`, color: "gray" }, { text: `OS \u203a ${os.platform()}\n`, color: "gray" }, { text: `OS Version/distro \u203a ${os.version()}\n`, color: "gray", }, { text: `Kernel Version \u203a ${os.release()}\n`, color: "gray" }, { text: `Cores \u203a ${os.cpus().length}\n`, color: "gray", }, { text: `CPU \u203a ${os.cpus()[0].model}\n`, color: "gray" }, { text: `Server Free memory `, color: 'gray' }, { text: `${Math.floor( os.freemem() / 1048576, )} `, color: 'gray' }, { text: `MiB / ${Math.floor(os.totalmem() / 1048576)} MiB\n`, color: 'gray' }, { text: `Device uptime \u203a ${format(os.uptime())}\n`, color: 'gray' }, { text: `Node version \u203a ${process.version}`, color: 'gray' } ])?.toString();
|
||||
fix = fixansi(message.replace('`', '`\u200b'))
|
||||
Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.embed}`)
|
||||
.setTitle(`${this.name} command`)
|
||||
.setDescription(`\`\`\`ansi\n${fix}\n\`\`\``)
|
||||
bot.discord.message.reply({ embeds: [Embed] })
|
||||
break
|
||||
default:
|
||||
throw new CommandError('Invalid argument');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
const CommandError = require('../util/command_error');
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
module.exports = {
|
||||
name: 'kick',
|
||||
trustLevel: 1,
|
||||
@@ -18,6 +19,18 @@ module.exports = {
|
||||
case 'invalidstring':
|
||||
bot.core.run(`minecraft:tellraw ${args.slice(2).join(' ')} ${JSON.stringify(bot.exploits.invalidString)}`)
|
||||
break
|
||||
default:
|
||||
bot.chat.message(bot.getMessageAsPrismarine({ translate: "command.unknown.argument", color: "dark_red" })?.toMotd().replaceAll("§","&"))
|
||||
}
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments;
|
||||
if (bot.options.useChat || bot.options.isSavage || bot.options.isCreayun) throw new CommandError('Cannot execute command!');
|
||||
switch (args[0]) {
|
||||
case "invalidstring":
|
||||
bot.core.run(`minecraft:tellraw ${args.slice(1).join(' ')} ${JSON.stringify(bot.exploits.invalidString)}`)
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+14
-3
@@ -1,16 +1,27 @@
|
||||
module.exports = {
|
||||
name: 'kill',
|
||||
trustLevel: 2,
|
||||
trustLevel: 3,
|
||||
aliases: [
|
||||
"suicide",
|
||||
"quit",
|
||||
],
|
||||
description: 'kill the bots process',
|
||||
usages: [
|
||||
""
|
||||
],
|
||||
async execute (context) {
|
||||
const bot = context.bot
|
||||
const bot = context.bot;
|
||||
// ik theres a better way to do but shut the fuck up about it
|
||||
await bot.chat.message("killing process");
|
||||
await process.exit(69420) // sure why the hell not
|
||||
await bot.console.info("killing process");
|
||||
await bot.discord.channel?.send("killing process");
|
||||
await process.kill(0);
|
||||
},
|
||||
async discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
await bot.chat.message("killing process");
|
||||
await bot.console.info("killing process");
|
||||
await bot.discord.channel?.send("killing process");
|
||||
await process.exit(0);
|
||||
}
|
||||
}
|
||||
|
||||
+20
-8
@@ -12,15 +12,28 @@ module.exports = {
|
||||
execute (context) {
|
||||
const args = context.arguments;
|
||||
const bot = context.bot;
|
||||
const source = context.source
|
||||
const source = context.source;
|
||||
const config = context.config;
|
||||
//throw new CommandError('ohio')
|
||||
const component = {
|
||||
translate: '[%s] %s \u203a %s',
|
||||
with: [
|
||||
bot.options.serverName,
|
||||
source.player.displayName ?? source.player.profile.name,
|
||||
args.join(' ')
|
||||
if (config.patches.netmsg) {
|
||||
component = [
|
||||
{ text: '[', color: "dark_gray" },
|
||||
{ text: bot.options.serverName, color: "gray" },
|
||||
{ text: "] ", color: "dark_gray" },
|
||||
source.player.displayName,
|
||||
{ text: " \u203a ", color: "dark_gray", bold: false },
|
||||
{ text: args.join(' '), color: "gray", bold: false }
|
||||
]
|
||||
} else {
|
||||
component = {
|
||||
translate: '[%s] %s \u203a %s',
|
||||
color: "dark_gray",
|
||||
with: [
|
||||
{ text: bot.options.serverName, color: "gray" },
|
||||
source.player.displayName ?? source.player.profile.name,
|
||||
{ text: args.join(' '), color: "gray" },
|
||||
]
|
||||
}
|
||||
}
|
||||
// bot.bots.filter((eachBot) => { if (eachBot.options.useChat) eachBot.chat.message('sussy');
|
||||
// else if (!eachBot.options.useChat) eachBot.chat.message('baka!')})
|
||||
@@ -29,7 +42,6 @@ module.exports = {
|
||||
bot.bots.filter((eachBot) => {
|
||||
if (eachBot.options.serverName === "Savage Friends" && eachBot.options.isSavage && !eachBot.options.useChat && !eachBot.options.isKaboom) {
|
||||
eachBot.chat.message(`[${bot.options.serverName}] ${bot.getMessageAsPrismarine(source.player.displayName ?? source.player.profile.name)?.toMotd().replaceAll('§','&')} \u203a ${args.join(' ')}`)
|
||||
|
||||
} else if (!eachBot.options.serverName !== "Savage Friends" && !eachBot.options.isSavage && !eachBot.options.useChat && eachBot.options.isKaboom) {
|
||||
eachBot.tellraw("@a", component);
|
||||
} else if (!eachBot.options.serverName !== "Savage Friends" && !eachBot.options.isSavage && eachBot.options.useChat && eachBot.options.isKaboom) {
|
||||
|
||||
@@ -13,5 +13,9 @@ module.exports = {
|
||||
const bot = context.bot
|
||||
const message = context.arguments.join(' ')
|
||||
bot._client.end("disconnect :3")
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
bot._client.end("disconnect :3")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
module.exports = {
|
||||
name: 'reload',
|
||||
trustLevel: 0,
|
||||
aliases: [
|
||||
],
|
||||
description: 'reloads commands',
|
||||
usages: [
|
||||
""
|
||||
],
|
||||
execute (context) {
|
||||
const bot = context.bot
|
||||
bot.tellraw("@a", [
|
||||
{ text: "Reloading ", color: "gray" },
|
||||
{ text: '(', color: "gray" },
|
||||
{ text: `${bot.commandManager.commandlist.length}`, color: "gold" },
|
||||
{ text: ') ', color: "gray" },
|
||||
{ text: 'commands', color: "gray" },
|
||||
])
|
||||
for (const eachBot of bot.bots) {
|
||||
eachBot.commandManager.reload();
|
||||
}
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
bot.discord.message.reply("Reloading Commands,.........");
|
||||
for (const eachBot of bot.bots) {
|
||||
eachBot.commandManager.reload();
|
||||
}
|
||||
}
|
||||
}
|
||||
+3
-3
@@ -3,10 +3,10 @@ const CommandError = require('../util/command_error')
|
||||
module.exports = {
|
||||
name: 'tpr',
|
||||
description:['teleport to a random place'],
|
||||
trustLevel: 0,
|
||||
trustLevel: 1,
|
||||
aliases:['rtp', 'teleportrandom', 'randomteleport'],
|
||||
usage:[""],
|
||||
async execute (context) {
|
||||
execute (context) {
|
||||
const bot = context.bot
|
||||
const sender = context.source.player
|
||||
const source = context.source
|
||||
@@ -15,6 +15,6 @@ module.exports = {
|
||||
const y = 100
|
||||
const z = between(-1_000_000, 1_000_000)
|
||||
bot.tellraw("@a", `Randomly Teleported: ${sender.profile.name} to x:${x} y:${y} z:${z} `)
|
||||
bot.core.run(`tp ${sender.uuid} ${x} ${y} ${z}`)
|
||||
bot.core.run(`minecraft:tp ${sender.profile.name} ${x} ${y} ${z}`)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,10 +3,10 @@ const { stylize } = require('../util/stylizeEval');
|
||||
const util = require('util');
|
||||
module.exports = {
|
||||
name: 'servereval',
|
||||
trustLevel: 2,
|
||||
trustLevel: 3,
|
||||
aliases: [
|
||||
],
|
||||
description: 'run commands unisolated',
|
||||
description: 'run code unisolated',
|
||||
usages: [
|
||||
"<code>",
|
||||
],
|
||||
|
||||
+28
-3
@@ -6,15 +6,40 @@ module.exports = {
|
||||
],
|
||||
description: 'Make me say something',
|
||||
usages: [
|
||||
"<message>"
|
||||
"error stack <message>",
|
||||
"error message <message>",
|
||||
"message <message>"
|
||||
],
|
||||
execute (context) {
|
||||
const bot = context.bot
|
||||
const args = context.arguments;
|
||||
if (!args && !args[0] && !args[1]) return
|
||||
switch (args[0]) {
|
||||
case 'error':
|
||||
throw new Error(args.slice(1).join(' '));
|
||||
break
|
||||
switch (args[1]) {
|
||||
case 'stack':
|
||||
throw new Error(args.slice(2).join(' '));
|
||||
break
|
||||
case 'message':
|
||||
throw new CommandError(args.slice(2).join(' '));
|
||||
break
|
||||
}
|
||||
// throw new Error(args.slice(1).join(' '));
|
||||
break;
|
||||
case "message":
|
||||
bot.tellraw("@a", [
|
||||
{
|
||||
text: `Hello, World!, Player: ${bot.getMessageAsPrismarine(context.source.player.displayName ?? context.source.player.profile.name)?.toMotd()}§r`,
|
||||
color: 'gray',
|
||||
bold: false
|
||||
},
|
||||
{
|
||||
text: ` Args: ${args.slice(1).join(' ')}`,
|
||||
color: 'gray',
|
||||
bold: false,
|
||||
}
|
||||
])
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,11 +7,10 @@ module.exports = {
|
||||
aliases:['urbandictionary'],
|
||||
trustLevel: 0,
|
||||
usage:[
|
||||
"all <definition>",
|
||||
"single <definition>",
|
||||
"<definition>",
|
||||
],
|
||||
usages: [
|
||||
"<definition",
|
||||
"<definition>",
|
||||
],
|
||||
async execute (context) {
|
||||
const source = context.source
|
||||
@@ -42,20 +41,20 @@ module.exports = {
|
||||
action:"show_text",
|
||||
value: [
|
||||
{
|
||||
text: `Example \u203a \n ${definitions.example.replaceAll('\r', '').replaceAll('[', '\xa71\xa7n\xa7o').replaceAll(']','\xa7r\xa77')}`,
|
||||
color: 'dark_blue'
|
||||
text: `Example \u203a \n ${definitions.example.replaceAll('\r', '').replaceAll('[', '\xa71\xa7n\xa7o').replaceAll(']','\xa7r\xa77')}\n`,
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `Word \u203a ${definitions.word.replaceAll('\r', '').replaceAll('[', '\xa71\xa7n\xa7o').replaceAll(']','\xa7r\xa77')}\n`,
|
||||
color: 'dark_blue',
|
||||
color: 'gray',
|
||||
},
|
||||
{
|
||||
text: `Author \u203a ${definitions.author.replaceAll('\r', '').replaceAll('[', '\xa71\xa7n\xa7o').replaceAll(']','\xa7r\xa77')}\n`,
|
||||
color: 'dark_blue'
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `written on \u203a ${definitions.written_on.replaceAll('\r', '').replaceAll('[', '\xa71\xa7n\xa7o').replaceAll(']','\xa7r\xa77')}\n`,
|
||||
color: 'dark_blue'
|
||||
color: 'gray'
|
||||
},
|
||||
{
|
||||
text: `Rating \u203a Thumbs-Up ${definitions.thumbs_up} / Thumbs-Down ${definitions.thumbs_down}`,
|
||||
|
||||
@@ -13,10 +13,28 @@ module.exports = {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments;
|
||||
const source = context.source;
|
||||
/* if (args[0] === bot.validation.trusted) {
|
||||
if (bot.options.isSavage) {
|
||||
bot.chat.message('&2Valid Trusted hash');
|
||||
} else {
|
||||
bot.tellraw(`@a`, { text: "Valid Trusted hash", color: "dark_green" });
|
||||
}
|
||||
}
|
||||
if (args[0] === bot.validation.owner) {
|
||||
if (bot.options.isSavage) {
|
||||
bot.chat.message("&2Valid Owner hash");
|
||||
} else {
|
||||
bot.tellraw(`@a`, { text: "Valid Owner hash", color: "dark_green" });
|
||||
}
|
||||
}*/
|
||||
if (args[0] === bot.validation.trusted) {
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, { text: "Valid Trusted hash", color: "dark_green" });
|
||||
} if (args[0] === bot.validation.owner) {
|
||||
bot.tellraw(`@a[name="${source?.player?.profile?.name}"]`, { text: "Valid Owner hash", color: "dark_green" });
|
||||
bot.chat.message('&2Valid Trusted hash');
|
||||
}
|
||||
if (args[0] === bot.validation.admin) {
|
||||
bot.chat.message('&2Valid Admin hash');
|
||||
}
|
||||
if (args[0] === bot.validation.owner) {
|
||||
bot.chat.message('&2Valid Owner hash');
|
||||
}
|
||||
},
|
||||
discordExecute (context) {
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
const http = require('http');
|
||||
const https = require('https');
|
||||
const util = require('util');
|
||||
module.exports = {
|
||||
name: 'website',
|
||||
trustLevel: 0,
|
||||
aliases: [
|
||||
],
|
||||
description: 'look up website data',
|
||||
usages: [
|
||||
"<url>"
|
||||
],
|
||||
execute (context) {
|
||||
const bot = context.bot
|
||||
const args = context.arguments;
|
||||
if (args.join(' ').toLowerCase().startsWith("http://")) {
|
||||
http.get(args.join(' '), (res) => {
|
||||
const { statusCode } = res;
|
||||
const contentType = res.headers['content-type'];
|
||||
res.setEncoding('utf8');
|
||||
let rawData = '';
|
||||
res.on('data', (chunk) => { rawData += chunk; });
|
||||
res.on('end', () => {
|
||||
try {
|
||||
bot.tellraw("@a", { text: util.inspect(rawData), color: "dark_green" })
|
||||
} catch (e) {
|
||||
bot.tellraw("@a", e.toString());
|
||||
}
|
||||
});
|
||||
}).on('error', (e) => {
|
||||
bot.chat.message(`&4${e.toString()}`);
|
||||
});
|
||||
} else if (args.join(' ').toLowerCase().startsWith('https://')) {
|
||||
https.get(args.join(' '), (res) => {
|
||||
res.on('data', (d) => {
|
||||
bot.tellraw("@a", { text: util.inspect(d.toString()), color: "dark_green", })
|
||||
// console.log(Object.keys(d.toString().length));
|
||||
});
|
||||
}).on('error', (e) => {
|
||||
bot.chat.message(`&4${e.toString()}`);
|
||||
});
|
||||
}
|
||||
},
|
||||
discordExecute (context) {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments;
|
||||
}
|
||||
}
|
||||
+14
-18
@@ -1,11 +1,9 @@
|
||||
const { parseString } = require('xml2js');
|
||||
const CommandError = require('../util/command_error')
|
||||
const util = require('util');
|
||||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
module.exports = {
|
||||
name: 'xml',
|
||||
trustLevel: 2,
|
||||
trustLevel: 3,
|
||||
aliases: [
|
||||
],
|
||||
description: 'eval xml shit',
|
||||
@@ -14,20 +12,18 @@ module.exports = {
|
||||
],
|
||||
execute (context) {
|
||||
const bot = context.bot;
|
||||
const args = context.arguments
|
||||
// fs.writeFileSync(path.join(__dirname, '../data/xmlEval.xml'), args.slice(1).join(' '))
|
||||
fs.appendFileSync(path.join(__dirname, '../data/xmlEval.xml'), args.slice(1).join(' '))
|
||||
parseString(args.slice(1).join(' '), function (err, result) {
|
||||
if (err) throw new CommandError(err.toString())
|
||||
bot.tellraw("@a", [
|
||||
{
|
||||
text: "Result \u203a \n",
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `${util.inspect(result)}`
|
||||
}
|
||||
])
|
||||
});
|
||||
const args = context.arguments;
|
||||
parseString(args.slice(1).join(' '), function (err, result) {
|
||||
if (err) throw new CommandError(err.toString())
|
||||
bot.tellraw("@a", [
|
||||
{
|
||||
text: "Result \u203a \n",
|
||||
color: "gray"
|
||||
},
|
||||
{
|
||||
text: `${util.inspect(result)}`
|
||||
}
|
||||
])
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,662 @@
|
||||
[
|
||||
{
|
||||
"name": {
|
||||
"text": "HBot",
|
||||
"color": "aqua",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"hhhzzzsss"
|
||||
],
|
||||
"exclaimer": "HBOT HARRYBUTT LMAOOOOOOOOOOOOOOOOO",
|
||||
"foundation": "java/mcprotocollib",
|
||||
"prefixes": [
|
||||
"#"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "FBot",
|
||||
"color": "gold"
|
||||
}
|
||||
],
|
||||
"authors": [
|
||||
"popbob/aaa"
|
||||
],
|
||||
"exclaimer": "",
|
||||
"foundation": "nodejs/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"+"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "JokerBot",
|
||||
"color": "green"
|
||||
}
|
||||
],
|
||||
"authors": [
|
||||
"zXzy",
|
||||
"12alex12"
|
||||
],
|
||||
"exclaimer": "",
|
||||
"foundation": "nodejs/mineflayer",
|
||||
"prefixes": [
|
||||
"\\"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "CddehhBot",
|
||||
"color": "red",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"CaydennO1",
|
||||
"spyingcreeper09"
|
||||
],
|
||||
"exclaimer": "WHAT IS THIS GOOFY AAAH FUCKING BOT FUCKING PIECE OF RETARDED ASS SHIT BOT ITS SO FUCKING SHIT I WANNA IPFILTER IT WITH FUCKING CHOMENS",
|
||||
"foundation": "nodejs/mineflayer",
|
||||
"prefixes": [
|
||||
","
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "TurtleBot",
|
||||
"color": "green",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"TurtleKid"
|
||||
],
|
||||
"exclaimer": "nmp when?",
|
||||
"foundation": "nodejs/mineflayer",
|
||||
"prefixes": [
|
||||
"\\"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "NothingBot",
|
||||
"color": "dark_red",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"Yaode_owo"
|
||||
],
|
||||
"exclaimer": "uwu",
|
||||
"foundation": "nodejs/mineflayer",
|
||||
"prefixes": [
|
||||
"?"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "SC09Bot",
|
||||
"color": "dark_gray",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"spyingcreeper09"
|
||||
],
|
||||
"exclaimer": ":3",
|
||||
"foundation": "nodejs/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"@"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "HorizonBot",
|
||||
"color": "gold",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"ZenZoya",
|
||||
"Yaode_owo",
|
||||
"Parker2991",
|
||||
"and others"
|
||||
],
|
||||
"exclaimer": "originally called §5FleamBot§r",
|
||||
"foundation": "nodejs/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"^"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "64Bot",
|
||||
"color": "gold",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"64Will64"
|
||||
],
|
||||
"exclaimer": "NINTENDO 64?!?!??!?! 69Bot when??????",
|
||||
"foundation": "NodeJS/Mineflayer",
|
||||
"prefixes": [
|
||||
"w="
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "Nebulabot",
|
||||
"color": "dark_purple",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"IuCC"
|
||||
],
|
||||
"exclaimer": "the void",
|
||||
"foundation": "NodeJS/Node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"["
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "Prism",
|
||||
"color": "#00FF9C",
|
||||
"bold": true
|
||||
},
|
||||
{
|
||||
"text": "Bot",
|
||||
"color": "white",
|
||||
"bold": true
|
||||
}
|
||||
],
|
||||
"authors": [
|
||||
"IuCC"
|
||||
],
|
||||
"exclaimer": "prismarine :3",
|
||||
"foundation": "NodeJS/Node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"["
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "SharpBot",
|
||||
"color": "aqua",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"64Will64"
|
||||
],
|
||||
"exclaimer": "sharp as in the tv? idfk im out of jokes also the first c# bot on the list??",
|
||||
"foundation": "C#/MineSharp",
|
||||
"prefixes": [
|
||||
"s="
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "MoonBot",
|
||||
"color": "red",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"64Will64"
|
||||
],
|
||||
"exclaimer": "stop mooning/mooing me ",
|
||||
"foundation": "NodeJS/Mineflayer",
|
||||
"prefixes": [
|
||||
"m="
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "TableBot",
|
||||
"color": "yellow",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"12alex12"
|
||||
],
|
||||
"exclaimer": "TABLE CLOTH BOT?!?! ",
|
||||
"foundation": "NodeJS/Node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"t!"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "Evil",
|
||||
"color": "dark_red",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Bot",
|
||||
"color": "dark_purple"
|
||||
}
|
||||
],
|
||||
"authors": [
|
||||
"FusseligerDev"
|
||||
],
|
||||
"exclaimer": "",
|
||||
"foundation": "Java/Custom",
|
||||
"prefixes": [
|
||||
"!"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "SBot Java",
|
||||
"color": "white",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"evkc"
|
||||
],
|
||||
"foundation": "Java/MCProtocolLib",
|
||||
"prefixes": [
|
||||
":"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "SBot Rust",
|
||||
"color": "white",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"evkc"
|
||||
],
|
||||
"foundation": "Rust",
|
||||
"prefixes": [
|
||||
"re:"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "Z-Boy-Bot",
|
||||
"color": "dark_purple",
|
||||
"bold": false
|
||||
},
|
||||
"exclaimer": "Most likely skidded along with kbot that the dev used",
|
||||
"authors": [
|
||||
"Romnci"
|
||||
],
|
||||
"foundation": "NodeJS/mineflayer or Java/mcprotocollib idfk",
|
||||
"prefixes": [
|
||||
"Z]"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "ABot",
|
||||
"color": "gold",
|
||||
"bold": true
|
||||
},
|
||||
"exclaimer": "not used anymore (replaced by V2)",
|
||||
"authors": [
|
||||
{
|
||||
"text": "_yfd",
|
||||
"color": "light_purple"
|
||||
}
|
||||
],
|
||||
"foundation": "NodeJS/Node-Minecraft-Protocol",
|
||||
"prefixes": [
|
||||
"<"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "ABot-V2",
|
||||
"color": "gold",
|
||||
"bold": true
|
||||
},
|
||||
"exclaimer": "",
|
||||
"authors": [
|
||||
{
|
||||
"text": "_yfd",
|
||||
"color": "light_purple"
|
||||
}
|
||||
],
|
||||
"foundation": "NodeJS/Node-Minecraft-Protocol",
|
||||
"prefixes": [
|
||||
"<"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "FardBot",
|
||||
"color": "light_purple",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"_yfd"
|
||||
],
|
||||
"exclaimer": "bot is dead lol",
|
||||
"foundation": "NodeJS/Mineflayer",
|
||||
"prefixes": [
|
||||
"<"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "ChipmunkBot Java",
|
||||
"color": "green",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"_ChipMC_"
|
||||
],
|
||||
"exclaimer": "chips? also shoutout to chip and chayapak for helping in the rewrite",
|
||||
"foundation": "Java/MCProtocolLib",
|
||||
"prefixes": [
|
||||
"'",
|
||||
"/'"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "ChipmunkBot NodeJS",
|
||||
"color": "green",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"_ChipMC_"
|
||||
],
|
||||
"foundation": "NodeJS/Node-Minecraft-Protocol"
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "TestBot",
|
||||
"color": "aqua",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"Blackilykat"
|
||||
],
|
||||
"foundation": "Java/MCProtocolLib",
|
||||
"prefixes": [
|
||||
"-"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "UBot",
|
||||
"color": "gray",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"HexWoman"
|
||||
],
|
||||
"exclaimer": "UwU OwO",
|
||||
"foundation": "NodeJS/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"\""
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "ChomeNS Bot Java",
|
||||
"color": "yellow",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"chayapak"
|
||||
],
|
||||
"exclaimer": "wow its my bot !! ! 4374621q43567%^&#%67868-- chayapak \n rip ChomeNS bot i wonder what chayapak is currently doing -- Parker2991",
|
||||
"foundation": "Java/MCProtocolLib",
|
||||
"prefixes": [
|
||||
"*",
|
||||
"cbot ",
|
||||
"/cbot "
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "ChomeNS Bot NodeJS",
|
||||
"color": "yellow",
|
||||
"bold": false
|
||||
},
|
||||
"authors": [
|
||||
"chayapak"
|
||||
],
|
||||
"foundation": "NodeJS/Node-Minecraft-Protocol",
|
||||
"prefixes": [
|
||||
"*",
|
||||
"cbot",
|
||||
"/cbot"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "RecycleBot",
|
||||
"color": "dark_green",
|
||||
"bold": false
|
||||
},
|
||||
"foundation": [
|
||||
"MorganAnkan"
|
||||
],
|
||||
"exclaimer": "nice bot",
|
||||
"language": "NodeJS/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"="
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "neobot",
|
||||
"color": "blue",
|
||||
"bold": false
|
||||
},
|
||||
"exclaimer": "n e o b o t ;oslkdfj;salkdfj;ladsjf",
|
||||
"authors": [
|
||||
"mirkokral"
|
||||
],
|
||||
"foundation": "java/MCProtocolLib",
|
||||
"prefixes": [
|
||||
"_"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": {
|
||||
"text": "ManBot",
|
||||
"color": "dark_green",
|
||||
"bold": false
|
||||
},
|
||||
"exclaimer": "(more like men bot :skull:) OH HAAAAAAAAAAAAAAIIILL LOGINTIMEDOUT",
|
||||
"authors": [
|
||||
"Man/LogintimedOut"
|
||||
],
|
||||
"foundation": "NodeJS/mineflayer",
|
||||
"prefixes": [
|
||||
"(Note:I dont remember!!)"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "Useless",
|
||||
"color": "red",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Bot",
|
||||
"color": "gray",
|
||||
"bold": false
|
||||
}
|
||||
],
|
||||
"exclaimer": "it isnt useless its a good bot................",
|
||||
"authors": [
|
||||
"IuCC"
|
||||
],
|
||||
"foundation": "NodeJS/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"["
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "SnifferBot",
|
||||
"color": "gold",
|
||||
"bold": false
|
||||
}
|
||||
],
|
||||
"exclaimer": "sniff sniff FNFBoyfriendBot simp",
|
||||
"authors": [
|
||||
"popbob/aaa"
|
||||
],
|
||||
"foundation": "NodeJS/Node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
">"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "XBot",
|
||||
"color": "dark_purple",
|
||||
"bold": false
|
||||
}
|
||||
],
|
||||
"exclaimer": "",
|
||||
"authors": [
|
||||
"popbob/aaa"
|
||||
],
|
||||
"foundation": "ts-Node/Node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"$"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "Kitty",
|
||||
"color": "gold",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Corp",
|
||||
"color": "aqua",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Bot",
|
||||
"color": "yellow",
|
||||
"bold": false
|
||||
}
|
||||
],
|
||||
"exclaimer": "3 words ginlang is gay",
|
||||
"authors": [
|
||||
"ginlang , G6_, ArrayBuffer, and i guess more??"
|
||||
],
|
||||
"foundation": "NodeJS/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"^"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "FNF",
|
||||
"color": "dark_purple",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Boyfriend",
|
||||
"color": "aqua",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Bot",
|
||||
"color": "dark_red",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": " nmp",
|
||||
"color": "black",
|
||||
"bold": false
|
||||
}
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"text": "Parker2991",
|
||||
"color": "dark_red"
|
||||
},
|
||||
{
|
||||
"text": " _ChipMC_",
|
||||
"color": "dark_green",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": " chayapak",
|
||||
"color": "yellow",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": " _yfd",
|
||||
"color": "light_purple",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "popbob/aaa",
|
||||
"color": "gold"
|
||||
},
|
||||
{
|
||||
"text": "MorganAnkan",
|
||||
"color": "dark_green"
|
||||
},
|
||||
{
|
||||
"text": "TurtleKid",
|
||||
"color": "green"
|
||||
}
|
||||
],
|
||||
"exclaimer": "v4.0x - current",
|
||||
"foundation": "NodeJS/node-minecraft-protocol",
|
||||
"prefixes": [
|
||||
"~",
|
||||
"fnfbfbot ",
|
||||
"",
|
||||
"",
|
||||
"█"
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"text": "FNF",
|
||||
"color": "dark_purple",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Boyfriend",
|
||||
"color": "aqua",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": "Bot",
|
||||
"color": "dark_red",
|
||||
"bold": false
|
||||
},
|
||||
{
|
||||
"text": " legacy",
|
||||
"color": "green",
|
||||
"bold": false
|
||||
}
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"text": "Parker2991",
|
||||
"color": "dark_red"
|
||||
},
|
||||
{
|
||||
"text": " _ChipMC_",
|
||||
"color": "dark_green",
|
||||
"bold": false
|
||||
}
|
||||
],
|
||||
"exclaimer": "1037 LINES OF CODE WTFARD!??! also this version is in console commands only",
|
||||
"foundation": "NodeJS/mineflayer",
|
||||
"prefixes": []
|
||||
}
|
||||
]
|
||||
@@ -8,14 +8,10 @@ discord:
|
||||
token: "discord token here"
|
||||
prefix: "!"
|
||||
invite: "discord invite here"
|
||||
|
||||
matrix:
|
||||
token: "matrix token here"
|
||||
invite: "matrix invite here"
|
||||
prefix: "!"
|
||||
hostUrl: "matrix instance url here"
|
||||
userId: "@fnfboyfriendbot:localhost"
|
||||
enabled: false
|
||||
roles:
|
||||
trusted: "trusted"
|
||||
admin: "admin"
|
||||
owner: "FNFBoyfriendBot Owner"
|
||||
|
||||
core:
|
||||
name: {"translate":"outOfMemory.message"}
|
||||
@@ -31,6 +27,7 @@ core:
|
||||
|
||||
keys:
|
||||
trusted: "trusted key here"
|
||||
admin: "admin key here"
|
||||
owner: "owner key here"
|
||||
|
||||
colors:
|
||||
@@ -38,6 +35,10 @@ colors:
|
||||
embed: "#000000"
|
||||
error: "#FF0000"
|
||||
|
||||
console:
|
||||
prefix: "c."
|
||||
filelogger: false
|
||||
|
||||
bots:
|
||||
- host: "localhost"
|
||||
username: "FNFBoyfriendBot"
|
||||
@@ -46,7 +47,6 @@ bots:
|
||||
serverName: "localhost"
|
||||
reconnectDelay: 6000
|
||||
channelId: "discord channel id here"
|
||||
roomId: "matrix room id here"
|
||||
logging: false
|
||||
useChat: false
|
||||
isKaboom: true
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"bot": {
|
||||
"buildstring": {
|
||||
"version": "v6.0.0-beta",
|
||||
"build":"800",
|
||||
"codename":"§#fe019aGraffiti §7Groovin"
|
||||
},
|
||||
"source": "https://code.chipmunk.land/Parker2991/FridayNightFunkinBoyfriendBot/"
|
||||
}
|
||||
}
|
||||
@@ -1,2 +0,0 @@
|
||||
<root> </root>
|
||||
<sause></sauce><root> sex </root><root> sex </root><root> sex </root><root>sus</root><root<root> </root><root>sex</root><root> </root><root>sex</root><root><></root><root><></></root><root><amogus></amogus></root><root><amogus></amogus><sus></sus></root>
|
||||
+1
-7
@@ -23,19 +23,13 @@ try {
|
||||
const rl = readline.createInterface({
|
||||
input: process.stdin,
|
||||
output: process.stdout,
|
||||
// prompt: `Boot success! type ${config.console.prefix}help for a list of commands`
|
||||
})
|
||||
if (config.discord.enabled) discordClient.login(config.discord.token);
|
||||
const bots = [];
|
||||
for (const options of config.bots) {
|
||||
const bot = createBot(options);
|
||||
const bot = createBot(options, config);
|
||||
bots.push(bot);
|
||||
bot.bots = bots;
|
||||
/* if (!config.discord.enabled) {
|
||||
return
|
||||
} else {
|
||||
discordClient.login(config.discord.token);
|
||||
}*/
|
||||
loadModules(bot, options, config, discordClient);
|
||||
bot.console.useReadlineInterface(rl);
|
||||
}
|
||||
|
||||
+5
-14
@@ -1,21 +1,12 @@
|
||||
const readline = require('readline');
|
||||
|
||||
function boot (bot, options, discordClient, config) {
|
||||
bot.on("packet.login", (data) => {
|
||||
bot.chat.message('&9FNF&3Boyfriend&1Bot &fcreated by &4Parker&02991');
|
||||
if (new Date().getDay() === 5) {
|
||||
bot.chat.message('Gettin\' freaky on a friday night!');
|
||||
} else {
|
||||
bot.chat.message('&9FNF&3Boyfriend&1Bot &fcreated by &4Parker&02991');
|
||||
}
|
||||
}) // &9 &3 &1
|
||||
}
|
||||
module.exports = boot;
|
||||
/*
|
||||
const readline = require('readline');
|
||||
|
||||
readline.emitKeypressEvents(process.stdin);
|
||||
process.stdin.on('keypress', (str, key) => {
|
||||
// console.log(str)
|
||||
// console.log(key)
|
||||
if (key && key.ctrl && key.name === 'c') {
|
||||
console.log('mrrow >:3');
|
||||
process.exit(69420);
|
||||
}
|
||||
})
|
||||
*/
|
||||
|
||||
+14
-40
@@ -3,7 +3,8 @@ const KaboomChatParser = require('../util/ChatParsers/Kaboom');
|
||||
const ChipmunkModChatParser = require('../util/ChatParsers/ChipmunkMod');
|
||||
const CreayunChatParser = require('../util/ChatParsers/Creayun');
|
||||
const sayConsoleChatParser = require('../util/ChatParsers/sayConsole');
|
||||
const VanillaChatParser = require("../util/ChatParsers/VanillaChat")
|
||||
const VanillaChatParser = require("../util/ChatParsers/VanillaChat");
|
||||
const nbt = require('prismarine-nbt');
|
||||
function tryParse (json) {
|
||||
try {
|
||||
return JSON.parse(json)
|
||||
@@ -25,7 +26,7 @@ function chat (bot, options, config) {
|
||||
bot.on('packet.profileless_chat', packet => {
|
||||
const message = tryParse(packet.message)
|
||||
const sender = tryParse(packet.name)
|
||||
|
||||
// bot.tellraw("@a", `Packet type ${packet.type}`)
|
||||
bot.emit('profileless_chat', {
|
||||
message,
|
||||
type: packet.type,
|
||||
@@ -38,12 +39,19 @@ function chat (bot, options, config) {
|
||||
if (packet.type === 3) bot.emit('message', bot.getMessageAsPrismarine({"translate":"commands.message.display.outgoing","with":[`${translateUsername}`,`${translateMessage}`],"color":"gray","italic":true})?.toMotd())
|
||||
if (packet.type === 4) bot.emit('message', message);
|
||||
if (packet.type === 5) bot.emit('message', bot.getMessageAsPrismarine({translate:"chat.type.announcement",color:'white', with:[`${translateUsername}`,`${translateMessage}`]})?.toMotd())
|
||||
|
||||
/* switch (packet.type) {
|
||||
case "4":
|
||||
bot.emit('message', message)
|
||||
// console.log('packet type 4');
|
||||
break
|
||||
}*/
|
||||
tryParsingMessage(message, { senderName: sender, players: bot.players, getMessageAsPrismarine: bot.getMessageAsPrismarine })
|
||||
})
|
||||
|
||||
bot.on('packet.player_chat', (packet, data) => {
|
||||
const unsigned = tryParse(packet.unsignedChatContent)
|
||||
// const unsigned = JSON.parse(loadPrismarineChat.processNbtMessage(nbt.comp(nbt.string(packet.unsignedChatContent))))
|
||||
// const unsigned = loadPrismarineChat.processNbtMessage(tryParse(packet.unsignedChatContent))
|
||||
bot.emit('player_chat', { plain: packet.plainMessage, unsigned, senderUuid: packet.senderUuid })
|
||||
if (packet.type === 5) bot.emit('message', bot.getMessageAsPrismarine({ translate: "chat.type.announcement", with: [`${bot.players.find(player => player.uuid === packet.senderUuid).profile.name}`, `${packet.plainMessage}`]})?.toMotd())
|
||||
if (packet.type !== 5) bot.emit("message", unsigned)
|
||||
@@ -52,9 +60,9 @@ function chat (bot, options, config) {
|
||||
|
||||
bot.on('packet.system_chat', packet => {
|
||||
const message = tryParse(packet.content)
|
||||
|
||||
if (message.translate === 'advMode.setCommand.success') return // Ignores command set message
|
||||
|
||||
if (config.commandSetMessage) {
|
||||
if (message.translate === 'advMode.setCommand.success') return // Ignores command set message
|
||||
}
|
||||
bot.emit('system_chat', { message, actionbar: packet.isActionBar })
|
||||
|
||||
if (packet.isActionBar) {
|
||||
@@ -86,22 +94,6 @@ function chat (bot, options, config) {
|
||||
|
||||
return undefined
|
||||
}
|
||||
/*
|
||||
bot.chat = message => {
|
||||
const acc = 0
|
||||
const bitset = Buffer.allocUnsafe(3)
|
||||
bitset[0] = acc & 0xFF
|
||||
bitset[1] = (acc >> 8) & 0xFF
|
||||
bitset[2] = (acc >> 16) & 0xFF
|
||||
bot._client.write('chat_message', {
|
||||
message,
|
||||
timestamp: BigInt(Date.now()),
|
||||
salt: 0n,
|
||||
offset: 0,
|
||||
acknowledged: bitset
|
||||
})
|
||||
}
|
||||
*/
|
||||
bot.chat = {
|
||||
message: message => {
|
||||
const acc = 0;
|
||||
@@ -120,7 +112,6 @@ function chat (bot, options, config) {
|
||||
command: command => {
|
||||
bot._client.write('chat_command', {
|
||||
command: command?.substring(0, 256),
|
||||
|
||||
timestamp: BigInt(Date.now()),
|
||||
salt: 0n,
|
||||
argumentSignatures: [],
|
||||
@@ -131,22 +122,5 @@ function chat (bot, options, config) {
|
||||
})
|
||||
}
|
||||
}
|
||||
// console.log(bot.chat.sendMessage)
|
||||
/*
|
||||
bot.command = command => {
|
||||
bot._client.write('chat_command', {
|
||||
command,
|
||||
timestamp: BigInt(Date.now()),
|
||||
salt: 0n,
|
||||
argumentSignatures: [],
|
||||
signedPreview: false,
|
||||
messageCount: 0,
|
||||
acknowledged: Buffer.alloc(3),
|
||||
previousMessages: []
|
||||
})
|
||||
}
|
||||
*/
|
||||
// bot.tellraw = (message, selector = '@a') => bot.core.run('minecraft:tellraw @a ' + JSON.stringify(message)) // ? Should this be here?
|
||||
}
|
||||
|
||||
module.exports = chat;
|
||||
|
||||
@@ -12,6 +12,8 @@ function core (bot, options, config) {
|
||||
|
||||
if (!pos) return
|
||||
if (bot.options.useChat ?? bot.options.isCreayun ?? bot.options.isSavage) return
|
||||
// if (isNaN(pos.x + start.x)) bot.chat.command('world 3');
|
||||
// console.log(isNaN(pos.x + start.x))
|
||||
bot.chat.command(`minecraft:fill ${pos.x + start.x} ${pos.y + start.y} ${pos.z + start.z} ${pos.x + end.x} ${pos.y + end.y} ${pos.z + end.z} repeating_command_block{CustomName:'${JSON.stringify(config.core.name)}'}`)
|
||||
},
|
||||
|
||||
@@ -57,8 +59,8 @@ function core (bot, options, config) {
|
||||
run (command) {
|
||||
const location = bot.core.currentBlock()
|
||||
if (!location) return
|
||||
if (bot.options.useChat ?? bot.options.isCreayun ?? bot.options.isSavage) {
|
||||
bot.chat.command(command?.substring(0, 256))
|
||||
if (bot.options.isSavage || bot.options.isCreayun || bot.options.useChat) {
|
||||
bot.chat.command(`${command?.substring(0, 256)}`)
|
||||
} else {
|
||||
bot._client.write('update_command_block', { command: command.substring(0, 32767), location, mode: 1, flags: 0b100 })
|
||||
bot.core.incrementCurrentBlock()
|
||||
|
||||
@@ -2,7 +2,12 @@ function command_loop (bot, options, config) {
|
||||
bot.cloop = {
|
||||
list: [],
|
||||
add (command, interval) {
|
||||
this.list.push({ timer: setInterval(() => bot.core.run(command), interval), command, interval })
|
||||
setTimeout(() => {
|
||||
this.list.push({ timer: setInterval(() => bot.core.run(command), interval), command, interval })
|
||||
}, 10)
|
||||
bot.on('end', () => {
|
||||
this.clear()
|
||||
})
|
||||
},
|
||||
|
||||
remove (index) {
|
||||
@@ -14,5 +19,10 @@ function command_loop (bot, options, config) {
|
||||
this.list = []
|
||||
}
|
||||
}
|
||||
/* bot.on('end', () => {
|
||||
// clearInterval(this.list);
|
||||
for (const cloop of this.list) console.log(cloop)
|
||||
console.log('e')
|
||||
})*/
|
||||
}
|
||||
module.exports = command_loop;
|
||||
|
||||
@@ -60,19 +60,24 @@ function command_manager (bot, options, config, discordClient) {
|
||||
const roles = event?.member?.roles?.cache;
|
||||
if (command?.trustLevel === 1 && !source?.sources?.discord) {
|
||||
const hash = args[0]
|
||||
if (args.length === 0 && bot.validation.trusted && bot.validation.owner && !source.sources.console) throw new CommandError({ text: "Please provide an trusted or owner hash" })
|
||||
if (args[0] !== bot.validation.trusted && args[0] !== bot.validation.owner && !source.sources.console) throw new CommandError({ translate: 'Invalid trusted or owner hash', color: 'dark_red' })
|
||||
if (args.length === 0 && bot.validation.trusted && bot.validation.admin && bot.validation.owner && !source.sources.console) throw new CommandError({ text: "Please provide an trusted or and admin or an owner hash" })
|
||||
if (args[0] !== bot.validation.trusted && args[0] !== bot.validation.admin && args[0] !== bot.validation.owner && !source.sources.console) throw new CommandError({ translate: 'Invalid trusted or admin or owner hash', color: 'dark_red' })
|
||||
} else if (command?.trustLevel === 1 && source?.sources.discord) {
|
||||
const hasRole = roles?.some(role => role.name === `${config.discord.roles.trusted}` || role.name === `${config.discord.roles.owner}`)
|
||||
if (!hasRole) throw new CommandError({ translate: 'You are trusted or the owner!' })
|
||||
if (!hasRole) throw new CommandError({ translate: 'You are not trusted or the owner!' })
|
||||
}
|
||||
if (command?.trustLevel === 2 && !source.sources.discord && !source.sources.console) {
|
||||
if (command?.trustLevel === 2 && !source.sources.console) {
|
||||
// bot.chat.message('trust level 2 does nothing currently'); placeholder code
|
||||
if (args.length === 0 && bot.validation.admin && bot.validation.owner && !source.sources.console) throw new CommandError({ text: "Please provide an trusted or owner hash" })
|
||||
if (args[0] !== bot.validation.trusted && args[0] !== bot.validation.owner && !source.sources.console) throw new CommandError({ translate: 'Invalid trusted or owner hash', color: 'dark_red' })
|
||||
}
|
||||
if (command?.trustLevel === 3 && !source.sources.discord && !source.sources.console) {
|
||||
if (args.length === 0 && bot.validation.owner) throw new CommandError({ text: "Please provide an owner hash" })
|
||||
if (args[0] !== bot.validation.owner) throw new CommandError({ translate: 'Invalid owner hash', color: 'dark_red' })
|
||||
} else if (command?.trustLevel === 2 && source.sources.discord && !source.sources.console) {
|
||||
} else if (command?.trustLevel === 3 && source.sources.discord && !source.sources.console) {
|
||||
const hasRole = roles?.some(role => role.name === `${config.discord.roles.owner}`)
|
||||
if (!hasRole) throw new CommandError({ translate: 'You are not the owner!' })
|
||||
} else if (command?.trustLevel === 3 && !source.sources.console) {
|
||||
} else if (command?.trustLevel === 4 && !source.sources.console) {
|
||||
throw new CommandError('This command can only be ran via console');
|
||||
}
|
||||
} if (!command?.discordExecute && command && source.sources.discord) {
|
||||
@@ -86,8 +91,8 @@ function command_manager (bot, options, config, discordClient) {
|
||||
}
|
||||
} catch (error) {
|
||||
console.error(error)
|
||||
bot?.console?.filelogging(error.stack);
|
||||
if (source?.sources?.discord && !source?.sources?.console) {
|
||||
// if (error instanceof CommandError) {
|
||||
const Embed = new EmbedBuilder()
|
||||
.setColor(`${config.colors.discord.error}`)
|
||||
.setTitle(`${command?.name} command`)
|
||||
@@ -97,21 +102,13 @@ function command_manager (bot, options, config, discordClient) {
|
||||
Embed
|
||||
]
|
||||
})
|
||||
// }
|
||||
// bot.tellraw("@a", { text: `${error.stack}`, color: "dark_red" })
|
||||
} else if (!source?.sources?.discord && !source?.sources?.console) {
|
||||
if (error instanceof CommandError)
|
||||
bot.tellraw("@a", { text: error.message, color: "dark_red" })
|
||||
else bot.tellraw("@a", bot.getMessageAsPrismarine({ translate: 'command.failed', color: "dark_red", hoverEvent: { action: 'show_text', contents: `${error.stack}` } })?.toMotd(bot.registry.language))
|
||||
else bot.tellraw("@a", [{ translate: 'command.failed', color: "dark_red", hoverEvent: { action: 'show_text', contents: `${error.stack}` } }])
|
||||
}
|
||||
}
|
||||
},
|
||||
/* const Embed = new EmbedBuilder()
|
||||
.setColor(`${bot.Commands.colors.discord.error}`)
|
||||
.setTitle(`${command?.name} Command`)
|
||||
.setDescription(`\`\`\`${error}\`\`\``)
|
||||
bot.discord.Message.reply({ embeds: [Embed] })
|
||||
*/
|
||||
executeString (source, command) {
|
||||
const [commandName, ...args] = command.split(' ')
|
||||
return this.execute(source, commandName, args)
|
||||
@@ -129,7 +126,10 @@ function command_manager (bot, options, config, discordClient) {
|
||||
command.aliases.map((a) => (this.commands[a] = command));
|
||||
}
|
||||
},
|
||||
|
||||
unregister (command) {
|
||||
// commands = {};
|
||||
this.commands = {};
|
||||
},
|
||||
getCommand (name) {
|
||||
return this.commands[name]
|
||||
},
|
||||
@@ -147,6 +147,7 @@ function command_manager (bot, options, config, discordClient) {
|
||||
bot.commandManager.commandlist.push(command)
|
||||
} catch (error) {
|
||||
console.error('Failed to load command', filename, ':', error)
|
||||
bot?.console.filelogging(error.stack)
|
||||
}
|
||||
}
|
||||
let ratelimit = 0;
|
||||
@@ -169,5 +170,28 @@ function command_manager (bot, options, config, discordClient) {
|
||||
}
|
||||
})
|
||||
})
|
||||
bot.commandManager.reload = function () {
|
||||
//commandlist = [];
|
||||
// bot.commandManager.unregister();
|
||||
// bot.commandManager.commandlist = [];
|
||||
for (const filename of fs.readdirSync(path.join(__dirname, "../commands"))) {
|
||||
try {
|
||||
// bot.commandManager.unregister();
|
||||
delete require.cache[require.resolve(path.join(__dirname, "../commands/", filename))]
|
||||
const command = require(path.join(__dirname, "../commands/", filename));
|
||||
// bot.commandManager.unregister();
|
||||
// delete require.cache[require.resolve(path.join(__dirname, "../commands", filename))]
|
||||
// bot.commandManager.register(command);
|
||||
// bot.commandManager.commandlist.push(command);
|
||||
bot.commandManager.register(command);
|
||||
bot.commandManager.commandlist.pop(command)
|
||||
bot.commandManager.commandlist.push(command)
|
||||
} catch (error) {
|
||||
// bot.console.error(["Failed to load File ", filename, ":", error.stack])
|
||||
bot.tellraw("@a", { text: `Failed to reload file ${filename}\n${error.stack}`, color: "red" })
|
||||
bot?.console?.filelogger(error.stack);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
module.exports = command_manager;
|
||||
|
||||
+34
-6
@@ -9,21 +9,21 @@ function CommandConsole (bot, options, config) {
|
||||
rl.on('line', line => {
|
||||
if (bot.options.serverName !== this.consoleServer && this.consoleServer !== 'all') return
|
||||
if (line.startsWith(config.console.prefix)) {
|
||||
return bot.commandManager.executeString(bot.console.source, line.substring(2))
|
||||
return bot.commandManager.executeString(bot.console.source, line.substring(config.console.prefix.length))
|
||||
} if (line.startsWith("")) {
|
||||
return bot.commandManager.executeString(bot.console.source, `echo ${line.substring(0)}`)
|
||||
return bot.commandManager.executeString(bot.console.source, `console say ${line.substring(0)}`)
|
||||
}
|
||||
})
|
||||
|
||||
rl.on('close', () => {
|
||||
this.readline = null
|
||||
})
|
||||
log = function (...args) {
|
||||
log = function (...args) {
|
||||
rl.output.write("\x1b[2K\r");
|
||||
console.log(args.toString());
|
||||
rl._refreshLine();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
bot.console.logs = function (message) {
|
||||
log(ChatMessage.fromNotch(`§8[§1${new Date().toLocaleTimeString("en-US", { timeZone: "America/CHICAGO", })} §3${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO", })} §6logs§8] §8[${options.serverName}§8] `)?.toAnsi() + message)
|
||||
@@ -38,11 +38,39 @@ function CommandConsole (bot, options, config) {
|
||||
bot.console.source.sendFeedback = message => {
|
||||
const ansi = bot.getMessageAsPrismarine(message)?.toAnsi(bot.registry.language).replaceAll('BlackStone Mafia On Top!', "Fuck off you god damn cunt")
|
||||
if (!options.logging) return
|
||||
bot.console.info(ansi);
|
||||
bot.console.logs(ChatMessage.fromNotch('§8[§6Command§8] ')?.toAnsi() + ansi);
|
||||
}
|
||||
bot.console.error = function (message) {
|
||||
console.log(ChatMessage.fromNotch(`§8[§1${new Date().toLocaleTimeString("en-US", { timeZone: "America/CHICAGO", })} §3${new Date().toLocaleDateString("en-US", { timeZone: "America/CHICAGO", })} §4error§8] §8[${options.serverName}§8] `)?.toAnsi() + message)
|
||||
}
|
||||
bot.console.customChat = {
|
||||
enabled: false,
|
||||
chat (message) {
|
||||
const prefix = {
|
||||
translate: '[%s] %s \u203a %s',
|
||||
color:'dark_gray',
|
||||
with: [
|
||||
{
|
||||
text: 'FNFBoyfriendBot Console',
|
||||
color:'#00FFFF'
|
||||
},
|
||||
{
|
||||
selector: `${bot.username}`, color:'#00FFFF',
|
||||
clickEvent: { action: 'suggest_command', value: '~help' }
|
||||
},
|
||||
{
|
||||
text: '',
|
||||
extra: [`${message}`],
|
||||
color:'white'
|
||||
},
|
||||
],
|
||||
hoverEvent: { action:"show_text", value: 'FNF Sky is a fangirl but a simp for boyfriend confirmed??'},
|
||||
clickEvent: 'https://doin-your.mom' ?
|
||||
{ action: 'open_url', value: 'https://doin-your.mom' } : undefined,
|
||||
}
|
||||
bot.tellraw('@a', prefix)
|
||||
}
|
||||
}
|
||||
bot.on('message', message => {
|
||||
const ansi = bot.getMessageAsPrismarine(message)?.toAnsi(bot.registry.language).replaceAll('BlackStone Mafia On Top!', "Fuck off you god damn cunt")
|
||||
const string = bot.getMessageAsPrismarine(message)?.toString(bot.registry.language).replaceAll('BlackStone Mafia On Top!', "Fuck off you god damn cunt")
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
function database () {
|
||||
|
||||
|
||||
}
|
||||
module.exports = database;
|
||||
@@ -8,7 +8,6 @@ const client = new Client({ intents: [Guilds, GuildMessages, MessageContent] })
|
||||
const util = require('util')
|
||||
|
||||
function discord(bot, options, config, discordClient) {
|
||||
// client.login(config.discord.token)
|
||||
if (!options?.channelId) {
|
||||
bot.discord = {
|
||||
invite: config.discord?.invite
|
||||
@@ -40,8 +39,7 @@ function discord(bot, options, config, discordClient) {
|
||||
try {
|
||||
bot?.discord?.channel?.send(`\`\`\`ansi\n${discordQueue.join('\n').substring(0, 1984)}\n\`\`\``)
|
||||
} catch (error) {
|
||||
bot.console.error(error.stack)
|
||||
|
||||
bot.console.warn(error.toString())
|
||||
}
|
||||
discordQueue = []
|
||||
}, 2000)
|
||||
@@ -53,7 +51,7 @@ function discord(bot, options, config, discordClient) {
|
||||
function sendComponent(message) {
|
||||
const ansi = bot.getMessageAsPrismarine(message)?.toAnsi(bot.registry.language).replaceAll('```\u001b[9```' + '```\u001b[3```').replaceAll('https://discord','https:\rdiscord')?.replaceAll('discord.gg', 'discord.\rgg').replaceAll('BlackStone Mafia On Top!', "Fuck off you god damn cunt");
|
||||
try {
|
||||
sendDiscordMessage(fixansi(ansi.replaceAll('`', '`\u200b')))
|
||||
sendDiscordMessage(fixansi(ansi?.replaceAll('`', '`\u200b')))
|
||||
} catch (e) {
|
||||
bot.console.error(`Error sending a message to Discord:\n${e.message}`)
|
||||
sendDiscordMessage(e.message)
|
||||
|
||||
+1
-38
@@ -15,15 +15,6 @@ function consolefilelogger(bot, options, message) {
|
||||
if (!fs.existsSync(path.join(__dirname, "../../logs"))) {
|
||||
fs.mkdirSync(path.join(__dirname, "../../logs"))
|
||||
}
|
||||
/*
|
||||
const {
|
||||
createReadStream,
|
||||
createWriteStream,
|
||||
} = require('node:fs');
|
||||
*/
|
||||
// if (!bot.Console.filelogging) return;
|
||||
// ${new Date().toLocaleTimeString("en-US", { timeZone: "America/CHICAGO", })}
|
||||
// if (new Date().toLocaleTimeString("en-US", { timeZone: "America/CHICAGO", }) === "10:45:00 PM") process.exit("daily reset");
|
||||
try {
|
||||
if (!fs.existsSync(logFolder)) {
|
||||
fs.mkdirSync(logFolder);
|
||||
@@ -60,38 +51,10 @@ const {
|
||||
newFileName = path.join(logFolder, `${name}.log.gz`);
|
||||
counter++;
|
||||
}
|
||||
// if (plainName !== timestamp) {
|
||||
compressFile(logFilePath, newFileName);
|
||||
// }
|
||||
}
|
||||
|
||||
// console?.info(
|
||||
// `File logging: ${bot.Console.filelogging ? "enabled" : "disabled"}`
|
||||
// );
|
||||
// if (!bot.Console.filelogging) return; // instead of using bot why not just use options cause you already defined it
|
||||
|
||||
// if (toFile) logStream.write(toWrite + '\n');
|
||||
|
||||
bot.console.filelogging = function logging (message) {
|
||||
logStream.write(message + "\n"); // toFile is not defined
|
||||
logStream.write(message + "\n");
|
||||
};
|
||||
// console.log(process.stdin.setEncoding('utf-8'))
|
||||
}
|
||||
|
||||
/*
|
||||
const rl = readline.createInterface({
|
||||
input: process.stdin,
|
||||
output: process.stdout,
|
||||
});
|
||||
|
||||
*/
|
||||
module.exports = consolefilelogger;
|
||||
/*
|
||||
child.stdin.setEncoding('utf-8');
|
||||
child.stdout.pipe(process.stdout);
|
||||
|
||||
child.stdin.write("console.log('Hello from PhantomJS')\n");
|
||||
|
||||
child.stdin.end();
|
||||
*/
|
||||
|
||||
|
||||
+35
-25
@@ -7,7 +7,9 @@ function selfcare (bot, options, config) {
|
||||
let vanished = false;
|
||||
let prefix = false;
|
||||
let god = false;
|
||||
let teleportToggle = false
|
||||
let teleportToggle = false;
|
||||
let username = false;
|
||||
let nickname = false;
|
||||
// You now have the tag: &8[&bPrefix&8: &3~&8]
|
||||
// You no longer have a tag
|
||||
bot.on('message', (message) => {
|
||||
@@ -23,8 +25,16 @@ function selfcare (bot, options, config) {
|
||||
else if (stringMessage?.startsWith("Your voice has been silenced")) unmuted = true;
|
||||
else if (stringMessage === "God mode disabled.") god = false;
|
||||
else if (stringMessage === "God mode enabled.") god = true;
|
||||
else if (stringMessage === "Teleportation disabled.") teleportToggle = false;
|
||||
else if (stringMessage === "Teleportation enabled.") teleportToggle = true;
|
||||
else if (stringMessage === "Teleportation disabled.") teleportToggle = true;
|
||||
else if (stringMessage === "Teleportation enabled.") teleportToggle = false;
|
||||
else if (stringMessage === `Successfully set your username to "${bot.username}"`) {
|
||||
username = false
|
||||
return
|
||||
}
|
||||
else if (stringMessage?.startsWith("Successfully set your username to ")) username = true
|
||||
else if (stringMessage === `You already have the username "${bot.username}"`) username = false
|
||||
else if (stringMessage === `You no longer have a nickname.`) nickname = false;
|
||||
else if (stringMessage.startsWith('Your nickname is now ')) nickname = true;
|
||||
})
|
||||
bot.on('packet.entity_status', packet => {
|
||||
if (packet.entityId !== entityId || packet.entityStatus < 24 || packet.entityStatus > 28) return
|
||||
@@ -35,32 +45,31 @@ function selfcare (bot, options, config) {
|
||||
gameMode = packet.gameMode;
|
||||
});
|
||||
bot.on("packet.game_state.change", packet => {
|
||||
if (packet.reason !== 4) return // checks if the client is locked
|
||||
if (packet.reason !== 4) return // checks if the bot is seeing the endcredits or died
|
||||
clientLock = packet.gameMode;
|
||||
})
|
||||
let timer;
|
||||
bot.on('packet.login', (packet) => {
|
||||
entityId = packet.entityId;
|
||||
gameMode = packet.gameMode;
|
||||
clientLock = packet.gameMode;
|
||||
console.log(packet.gameMode);
|
||||
timer = setInterval(() => {
|
||||
if (bot.options.isSavage && !bot.options.isKaboom) {
|
||||
if (clientLock !== 4) bot._client.write("client_command", { actionId: 0 });
|
||||
} else if (bot.options.isKaboom && !bot.options.isSavage) {
|
||||
if (permissionLevel < 2) bot.chat.command('op @s[type=player]');
|
||||
else if (gameMode !== 1) bot.chat.command('gamemode creative @s[type=player]');
|
||||
else if (!commandSpy) bot.chat.command('commandspy on');
|
||||
else if (!vanished) bot.core.run(`vanish ${bot.options.username} on`);
|
||||
else if (!prefix) bot.chat.command(`prefix &8[&bPrefix&8: &3${config.prefixes[0]}&8]`);
|
||||
else if (unmuted) bot.core.run(`essentials:mute ${bot.uuid}`);
|
||||
else if (!god) bot.core.run(`god ${bot.options.username} enable`);
|
||||
else if (!teleportToggle) bot.core.run(`tptoggle ${bot.options.username} enable`);
|
||||
else if (clientLock !== 4) bot._client.write("client_command", { actionId: 0 });
|
||||
// else if (unmuted) bot.chat.command(`mute ${bot.options.username} 0s`);
|
||||
// else if (unmuted) bot.core.run(`/essentials:mute ${bot.options.username}`);
|
||||
}
|
||||
}, 1000);
|
||||
entityId = packet.entityId;
|
||||
gameMode = packet.gameMode;
|
||||
clientLock = packet.gameMode;
|
||||
timer = setInterval(() => {
|
||||
if (bot.options.isSavage && !bot.options.isKaboom) {
|
||||
if (clientLock !== 4) bot._client.write("client_command", { actionId: 0 });
|
||||
} else if (bot.options.isKaboom && !bot.options.isSavage) {
|
||||
if (permissionLevel < 2) bot.chat.command('op @s[type=player]');
|
||||
else if (gameMode !== 1) bot.chat.command('gamemode creative @s[type=player]');
|
||||
else if (!commandSpy) bot.chat.command('commandspy on');
|
||||
else if (username) bot.chat.command(`username ${bot.options.username}`)
|
||||
else if (nickname) bot.chat.command(`nick off`)
|
||||
else if (!prefix) bot.chat.command(`prefix &8[&bPrefix&8: &3${config.prefixes[0]}&8]`);
|
||||
else if (!vanished) bot.core.run(`vanish ${bot.options.username} on`);
|
||||
else if (unmuted) bot.core.run(`essentials:mute ${bot.uuid}`);
|
||||
else if (!god) bot.core.run(`god ${bot.options.username} enable`);
|
||||
else if (!teleportToggle) bot.core.run(`tptoggle ${bot.options.username} disable`);
|
||||
else if (clientLock !== 4) bot._client.write("client_command", { actionId: 0 });
|
||||
}
|
||||
}, 1000);
|
||||
});
|
||||
bot.on('end', () => {
|
||||
if (timer) clearInterval(timer)
|
||||
@@ -70,6 +79,7 @@ function selfcare (bot, options, config) {
|
||||
prefix = false;
|
||||
god = false;
|
||||
unmuted = false;
|
||||
username = false;
|
||||
});
|
||||
}
|
||||
module.exports = selfcare;
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
const crypto = require("crypto");
|
||||
function validation (bot, options, config) {
|
||||
function validation (bot, options, config, discordClient) {
|
||||
let hashRegenInterval = setInterval(() => {
|
||||
bot.validation = {
|
||||
trusted: crypto.createHash('sha256').update(Math.floor(Date.now() / 5000) + config.keys.trusted).digest('hex').substring(0, 16),
|
||||
admin: crypto.createHash('sha256').update(Math.floor(Date.now() / 5000) + config.keys.admin).digest('hex').substring(0, 16),
|
||||
owner: crypto.createHash('sha256').update(Math.floor(Date.now() / 5000) + config.keys.owner).digest('hex').substring(0, 16),
|
||||
}
|
||||
}, 2000)
|
||||
}
|
||||
module.exports = validation;
|
||||
module.exports = validation;
|
||||
|
||||
@@ -1,35 +1,27 @@
|
||||
function chipmunkmod (message, data, context, bot) {
|
||||
function ChipmunkMod (message, data, context, bot) {
|
||||
try {
|
||||
if (message === null || typeof message !== 'object') return
|
||||
|
||||
if (message === null || typeof message !== 'object') return
|
||||
if (message.with?.length < 3 || (message.translate !== '[%s] %s › %s' && message.translate !== '%s %s › %s')) return
|
||||
|
||||
const senderComponent = message.with[1]
|
||||
// wtf spam again -
|
||||
//console.log(senderComponent)//wtf...
|
||||
|
||||
|
||||
const contents = message.with[2]
|
||||
// spam lol - console.log(contents)
|
||||
let sender
|
||||
|
||||
const hoverEvent = senderComponent.hoverEvent
|
||||
//console.log(JSON.stringify(hoverEvent))
|
||||
if (hoverEvent?.action === 'show_entity') {
|
||||
const id = hoverEvent.contents.id
|
||||
//
|
||||
|
||||
sender = data.players.find(player => player.uuid === id)
|
||||
} else {
|
||||
const stringUsername = data.getMessageAsPrismarine(senderComponent).toString() // TypeError: data.getMessageAsPrismarine is not a function
|
||||
|
||||
sender = data.players.find(player => player.profile.name) //=== stringusername)
|
||||
sender = data.players.find(player => player.profile.name === stringUsername)
|
||||
}
|
||||
|
||||
if (!sender) return null
|
||||
|
||||
return { sender, contents, type: 'minecraft:chat', senderComponent }
|
||||
} catch(e) {
|
||||
console.error(e)
|
||||
console.error(e)
|
||||
}
|
||||
}
|
||||
module.exports = chipmunkmod
|
||||
module.exports = ChipmunkMod
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
const util = require('util')
|
||||
|
||||
function parseMessage (message, data) {
|
||||
function kaboom (message, data) {
|
||||
if (message === null || typeof message !== 'object') return
|
||||
|
||||
if (message.text !== '' || !Array.isArray(message.extra) || message.extra.length < 3) return
|
||||
@@ -38,4 +38,4 @@ function isSeparatorAt (children, start) {
|
||||
return (children[start]?.text === ':' || children[start]?.text === '\xa7f:') && children[start + 1]?.text === ' '
|
||||
}
|
||||
|
||||
module.exports = parseMessage
|
||||
module.exports = kaboom
|
||||
|
||||
@@ -3,31 +3,21 @@ function VanillaChat (message, data, context) {
|
||||
if (message === null || typeof message !== 'object') return
|
||||
|
||||
if (message.with?.length < 2 || (message.translate !== 'chat.type.text' && message.translate !== '%s %s')) return
|
||||
|
||||
const senderComponent = message.with[0]
|
||||
// wtf spam again - console.log(senderComponent)//wtf...
|
||||
//console.log(senderComponent)
|
||||
|
||||
const senderComponent = message.with[0]
|
||||
const contents = message.with[1]
|
||||
// spam lol - console.log(contents)
|
||||
//console.log(contents)
|
||||
let sender
|
||||
|
||||
const hoverEvent = senderComponent.hoverEvent
|
||||
if (hoverEvent?.action === 'show_entity') {
|
||||
const id = hoverEvent.contents.id
|
||||
//
|
||||
sender = data.players.find(player => player.uuid === id)
|
||||
} else {
|
||||
const stringUsername = data.getMessageAsPrismarine(senderComponent).toString() // TypeError: data.getMessageAsPrismarine is not a function
|
||||
|
||||
sender = data.players.find(player => player.profile.name) //=== stringusername)
|
||||
sender = data.players.find(player => player.profile.name === stringUsername)
|
||||
}
|
||||
|
||||
if (!sender) return undefined
|
||||
|
||||
return { sender, contents, type: 'minecraft:chat', senderComponent }
|
||||
} catch(e) {
|
||||
} catch(e) {
|
||||
console.log(e.stack)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,31 +5,22 @@ function sayConsole (message, data, context, bot) {
|
||||
if (message.with?.length < 2 || (message.translate !== 'chat.type.announcement' && message.translate !== '%s %s')) return
|
||||
|
||||
const senderComponent = message.with[0]
|
||||
// wtf spam again -
|
||||
//console.log(senderComponent)//wtf...
|
||||
|
||||
|
||||
const contents = message.with[1]
|
||||
// spam lol - console.log(contents)
|
||||
let sender
|
||||
|
||||
const hoverEvent = senderComponent.hoverEvent
|
||||
//console.log(JSON.stringify(hoverEvent))
|
||||
if (hoverEvent?.action === 'show_entity') {
|
||||
const id = hoverEvent?.contents?.id
|
||||
//
|
||||
sender = data.players.find(player => player.uuid === id)
|
||||
} else {
|
||||
const stringUsername = data.getMessageAsPrismarine(senderComponent).toString() // TypeError: data.getMessageAsPrismarine is not a function
|
||||
|
||||
sender = data.players.find(player => player.profile.name) //=== stringusername)
|
||||
}
|
||||
|
||||
if (!sender) return null
|
||||
|
||||
return { sender, contents, type: 'minecraft:chat', senderComponent }
|
||||
} catch(e) {
|
||||
console.error(e)
|
||||
console.error(e);
|
||||
}
|
||||
}
|
||||
module.exports = sayConsole
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// TODO: Improve how messages are stringified
|
||||
const ChatMessage = require('prismarine-chat')('1.20.1')
|
||||
const ChatMessage = require('prismarine-chat')('1.20.2')
|
||||
const stringify = message => new ChatMessage(message).toString()
|
||||
|
||||
class CommandError extends Error {
|
||||
|
||||
@@ -3,12 +3,5 @@ class CommandSource {
|
||||
this.player = player;
|
||||
this.sources = sources;
|
||||
}
|
||||
/* sendFeedback () {}
|
||||
|
||||
sendError (message) {
|
||||
this.sendFeedback([{ text: '', color: 'dark_red' }, message], false)
|
||||
}*/
|
||||
|
||||
}
|
||||
|
||||
module.exports = CommandSource
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
const fs = require("fs");
|
||||
const path = require("path");
|
||||
const readline = require("readline");
|
||||
//const readline = require("readline");
|
||||
function loadModules (bot, options, config, discordClient) {
|
||||
bot.loadModule = module => module(bot, options, config, discordClient)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user