Change version compatibility in readme

This commit is contained in:
7cc5c4f330d47060 2025-02-14 00:59:45 -05:00
parent e8752d7eac
commit d3f88873f0
Signed by: 7cc5c4f330d47060
SSH key fingerprint: SHA256:e+4tcZut1nBpe10PqjaO+Rvie0Q7W4qIvFzcUw+7riA
3 changed files with 9 additions and 8 deletions

View file

@ -7,7 +7,7 @@ botv12 is a Minecraft bot originally designed for [Kaboom](https://kaboom.pw/) a
- a command core, to run commands quickly
- a hashing system, to enable trusted users to securely run certain commands in chat
It supports all Minecraft versions from 1.13 to 1.21.3 that are supported by node-minecraft-protocol. It may work on other versions, however, support will not be provided for them. It is recommended to use the bot on the version of the server, if at all possible.
It supports all Minecraft versions from 1.18 to 1.21.3 that are supported by node-minecraft-protocol - newer versions have bugs on Kaboom servers. It may work on other versions, however, support will not be provided for them.
## How to install?

View file

@ -9,7 +9,7 @@ export default function load (b) {
b.blocknoZ = 0
b.ccStarted = false
b.pos = { x: 0, y: 0, z: 0 }
const refillPayload = 'command_block{CustomName:\'{"translate":"%s %s","with":[{"translate":"entity.minecraft.ender_dragon"},{"translate":"language.name"}],"color":"#FFAAEE"}\'}'
const refillPayload = `command_block`
b.advanceccq = function () {
if (b.host.options.useChat) return

View file

@ -3,13 +3,14 @@ import parseNBT from '../util/parseNBT.js'
export default function load (b) {
b.players = {}
b._client.on('player_remove', (data) => {
b._client.on('player_remove', data => {
for (const item of data.players) {
if(!data.players[item]) continue;
b.players[item].here = false
b.emit('playerquit', item)
}
})
b._client.on('player_info', (data) => {
b._client.on('player_info', data => {
const buffer2 = {}
for (const player of data.data) {
let uuid
@ -48,7 +49,7 @@ export default function load (b) {
b.emit('playerdata', uuid, displayName, realName)
}
})
b.findUUID = (name) => {
b.findUUID = name => {
for (const i in b.players) {
if (b.players[i].realName === name) {
return i
@ -56,7 +57,7 @@ export default function load (b) {
}
return '00000000-0000-0000-0000-000000000000'
}
b.findRealName = (name) => {
b.findRealName = name => {
for (const i in b.players) {
if (b.players[i].displayName === name) {
return b.players[i].realName
@ -64,14 +65,14 @@ export default function load (b) {
}
return '[[[[ no name ]]]]'
}
b.findRealNameFromUUID = (uuid) => {
b.findRealNameFromUUID = uuid => {
if (b.players[uuid]) {
return b.players[uuid].realName
} else {
return uuid
}
}
b.findDisplayName = (uuid) => {
b.findDisplayName = uuid => {
if (b.players[uuid]) {
const displayName = b.players[uuid].displayName.split(' ')
return displayName[displayName.length - 1]