v7.0.5, build: 2200. debloated the bot, implemented some v8 features, converted the config to js, made the disconnect, error, and kick_disconnect packets emit as clientDisconnect, fixed mem leaks, made vanish and command spy selfcare use core, removed filter, customchat, command suggestions and boot modules

This commit is contained in:
Parker2991
2025-04-02 16:52:01 -04:00
parent c522270815
commit 799b49569e
30 changed files with 418 additions and 1013 deletions
+1 -2
View File
@@ -5,14 +5,13 @@ function inject (context) {
const bot = context.bot;
const config = context.config;
const options = context.options;
const { MessageBuilder } = require('prismarine-chat')(bot.options.version);
bot.on("parsed_message", (data) => {
if (data.type !== "minecraft:chat") return;
const prefixes = config.prefixes;
prefixes.map((prefix) => {
const plainMessage = bot.getMessageAsPrismarine(data.contents)?.toString();
// console.log(plainMessage);
if (!plainMessage.startsWith(prefix)) return
const command = plainMessage.substring(prefix.length)
const source = new CommandSource(data.sender, { discord: false, console: false }, true)