mirror of
https://github.com/ChomeNS/chomens-bot-mc.git
synced 2024-11-14 10:44:55 -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,
|
version: config.version,
|
||||||
kaboom: server.kaboom,
|
kaboom: server.kaboom,
|
||||||
logging: server.logging,
|
logging: server.logging,
|
||||||
|
useChat: server.useChat,
|
||||||
checkTimeoutInterval: config.timeoutInterval,
|
checkTimeoutInterval: config.timeoutInterval,
|
||||||
hideErrors: true
|
hideErrors: true
|
||||||
}
|
}
|
||||||
|
|
29
config.js
29
config.js
|
@ -16,8 +16,7 @@ module.exports = {
|
||||||
},
|
},
|
||||||
console: true,
|
console: true,
|
||||||
chat: {
|
chat: {
|
||||||
useChat: false,
|
messageLength: 128
|
||||||
messageLength: 100
|
|
||||||
},
|
},
|
||||||
core: {
|
core: {
|
||||||
layers: 3,
|
layers: 3,
|
||||||
|
@ -77,32 +76,36 @@ module.exports = {
|
||||||
host: 'play.kaboom.pw',
|
host: 'play.kaboom.pw',
|
||||||
port: 25565,
|
port: 25565,
|
||||||
kaboom: true,
|
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',
|
host: 'kitsune.icu',
|
||||||
port: 25565,
|
port: 25565,
|
||||||
kaboom: true,
|
kaboom: true,
|
||||||
logging: false
|
logging: false,
|
||||||
|
useChat: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
host: 'play.chipmunk.land',
|
host: 'play.chipmunk.land',
|
||||||
port: 25565,
|
port: 25565,
|
||||||
kaboom: true,
|
kaboom: true,
|
||||||
logging: true
|
logging: true,
|
||||||
|
useChat: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
host: 'chayapak.chipmunk.land',
|
host: 'chayapak.chipmunk.land',
|
||||||
port: 25565,
|
port: 25565,
|
||||||
kaboom: true,
|
kaboom: true,
|
||||||
logging: true
|
logging: true,
|
||||||
|
useChat: false
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
function inject (bot, dcclient, config) {
|
function inject (bot, dcclient, config) {
|
||||||
const ChatMessage = require('prismarine-chat')(bot.version)
|
const ChatMessage = require('prismarine-chat')(bot.version)
|
||||||
bot.tellraw = function (selector, message) {
|
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', '&'))
|
bot.chat(ChatMessage.fromNotch(message).toMotd().replaceAll('\xa7', '&'))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue