mirror of
https://github.com/ChomeNS/chomens-bot-mc.git
synced 2024-11-27 01:25:33 -05:00
useChat in server, ayun"boom" back
This commit is contained in:
parent
2a56cff88b
commit
7cfeacdae3
3 changed files with 18 additions and 14 deletions
1
bot.js
1
bot.js
|
@ -25,6 +25,7 @@ async function createBot (server, config, getBots, setNewBot, dcclient, rl) {
|
|||
version: config.version,
|
||||
kaboom: server.kaboom,
|
||||
logging: server.logging,
|
||||
useChat: server.useChat,
|
||||
checkTimeoutInterval: config.timeoutInterval,
|
||||
hideErrors: true
|
||||
}
|
||||
|
|
29
config.js
29
config.js
|
@ -16,8 +16,7 @@ module.exports = {
|
|||
},
|
||||
console: true,
|
||||
chat: {
|
||||
useChat: false,
|
||||
messageLength: 100
|
||||
messageLength: 128
|
||||
},
|
||||
core: {
|
||||
layers: 3,
|
||||
|
@ -77,32 +76,36 @@ module.exports = {
|
|||
host: 'play.kaboom.pw',
|
||||
port: 25565,
|
||||
kaboom: true,
|
||||
logging: true
|
||||
logging: true,
|
||||
useChat: false
|
||||
},
|
||||
{
|
||||
host: 'sus.shhnowisnottheti.me',
|
||||
port: 25565,
|
||||
kaboom: false,
|
||||
logging: true,
|
||||
useChat: true
|
||||
},
|
||||
// R.I.P ayunboom
|
||||
// {
|
||||
// host: 'sus.shhnowisnottheti.me',
|
||||
// port: 25565,
|
||||
// kaboom: true,
|
||||
// logging: true
|
||||
// },
|
||||
{
|
||||
host: 'kitsune.icu',
|
||||
port: 25565,
|
||||
kaboom: true,
|
||||
logging: false
|
||||
logging: false,
|
||||
useChat: false
|
||||
},
|
||||
{
|
||||
host: 'play.chipmunk.land',
|
||||
port: 25565,
|
||||
kaboom: true,
|
||||
logging: true
|
||||
logging: true,
|
||||
useChat: false
|
||||
},
|
||||
{
|
||||
host: 'chayapak.chipmunk.land',
|
||||
port: 25565,
|
||||
kaboom: true,
|
||||
logging: true
|
||||
logging: true,
|
||||
useChat: false
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
function inject (bot, dcclient, config) {
|
||||
const ChatMessage = require('prismarine-chat')(bot.version)
|
||||
bot.tellraw = function (selector, message) {
|
||||
if (config.chat.useChat && selector === '@a') {
|
||||
if (bot.options.useChat && selector === '@a') {
|
||||
bot.chat(ChatMessage.fromNotch(message).toMotd().replaceAll('\xa7', '&'))
|
||||
return
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue