Sørg for at botten ikke introducere hvis man skriver 'hvem er du' på en offentlig chat
This commit is contained in:
parent
ccda0ceb40
commit
1462d06b0e
2
main.lua
2
main.lua
|
@ -520,7 +520,7 @@ local function handle_message(bot, user, channel, message, is_slow_channel)
|
|||
end
|
||||
|
||||
-- Bot introduction
|
||||
if message:lower():match('%f[%a]hvem%f[%A]') and (message:lower():match('%f[%a]'..escape_pattern(CONFIG.IRC_NICK)..'%f[%A]') or message:lower():match '%f[%a]du%f[%A]') then
|
||||
if message:lower():match('%f[%a]hvem%f[%A]') and (message:lower():match('%f[%a]'..escape_pattern(CONFIG.IRC_NICK)..'%f[%A]') or not is_slow_channel and message:lower():match '%f[%a]du%f[%A]') then
|
||||
human_delay()
|
||||
local msg = BOT_INTRODUCTION:format(CONFIG.IRC_NICK)
|
||||
bot:sendChat(channel, msg)
|
||||
|
|
Loading…
Reference in New Issue
Block a user