Files
angram/lib/plugins/informer.js
T
jay 034f8d331a fix(informer): 🐛 convert array to string for chat
`bot.chat` only supports strings
2021-01-05 08:18:21 +05:00

22 lines
430 B
JavaScript

let cfg
let bot
let mcData
function info() {
const block = bot.blockAtCursor()
console.log(block)
cfg.quiet || bot.chat([block.id, block.name].join(": "))
}
const load = (config) => {
cfg = config
bot = cfg.bot
cfg.info = {
quiet: cfg.quiet,
}
mcData = bot.mcData || (bot.mcData = require('minecraft-data')(bot.version))
}
const unload = () => {}
module.exports = { load, unload, info }