wrong file oops

This commit is contained in:
ChomeNS 2023-03-01 13:10:26 +07:00
parent 30b864b4c6
commit f94e93281a

View file

@ -49,7 +49,7 @@ function parsePlayerMessages (message, packet, bot) {
bot.emit('chat', username, message) bot.emit('chat', username, message)
} else if (raw.match(/.* .*\u00BB .*/g)) { } else if (raw.match(/.* .*\u00BB .*/g)) {
const username = raw.replace(/.*?\[.*?\] /g, '').replace(/\u00BB.*/g, '').replace(/§#....../gm, '').split(' ')[0] const username = raw.replace(/.*?\[.*?\] /g, '').replace(/\u00BB.*/g, '').replace(/§#....../gm, '').split(' ')[0]
const message = raw.split('\u00BB ').slice(1).join(' ').substring(2) const message = raw.split('\u00BB ').slice(1).join(' ')
bot.emit('chat', username, message) bot.emit('chat', username, message)
} else if (raw.match(/.* .*> .*/g)) { } else if (raw.match(/.* .*> .*/g)) {
const username = raw.replace(/.*?\[.*?\] /g, '').replace(/>.*/g, '').replace(/§#....../gm, '').split(' ')[0] const username = raw.replace(/.*?\[.*?\] /g, '').replace(/>.*/g, '').replace(/§#....../gm, '').split(' ')[0]