function add_chat(e, t, n, r) { if (settings.mutechat) return; if (!n) { var i = t.match( /^[[] ((.*?) → (.*?)) ](.*)$/); i ? i[3] == "@mods" ? (n = "chatmod", t = i[2] + i[4]) : (n = "chatpm", t = i[1] + i[4]) : t.match(/^[(]2[)]/) && (n = "chatprincess") } console.log(t); t = quote_html(t.replace("Rainbow Dash", "ShiXEBa Inu")).replace( /([^0-9a-z#])((?:betid|roll):? |#)([1-9][0-9]{4,9})\b/ig, '$1$2$3' ).replace( /([^0-9a-z#])((?:betid|roll):? |#)([1-9][0-9]{4,9})\b/ig, '$1$2$3' ).replace( /(https:\/\/doge-dice[.]com\/roll\/)([1-9][0-9]{0,9})/ig, ' $2 ' ).replace( /(bitcoin-talk|bticointakl)/ig, "$1 (a phishing site, do not visit)") .replace(/lnputs[.]io/ig, "Lnputs.io (a phishing site, do not visit)" ).replace(/dicen[o0]w/ig, "dice-now").replace( /letsdice/ig, "lets-dice").replace( /grindabit/ig, "spamalot [lol jk]").replace( /bitdice[.]de/ig, "[yet more spam]").replace( /(http:\/\/just-dice[.]blogspot[.](?:ca|com)\/[0-9]+\/[0-9]+\/([a-z0-9-]+)(?:_[0-9]+)?[.]html)/ig, '[$2]' ).replace( /([?]|&)(r|referer|referal)=\s*(?:.+?\b)/ig, "$1$2= [spam link] ").replace( /(\/ref\/[0-9a-z\/]*)/ig, " [spam link]").replace( /(bit[.]ly|gg[.]gg|goo[.]gl|is[.]gd|ge[.]tt)\/[a-z0-9]{4,}/ig, "[suspicious link]").replace( /\bbitwars\b/ig, "[spam link]").replace( /\bmegaapp\b/ig, "[suspicious link]") .replace(/\b(javascript:)/i, "[potential scam warning] $1").replace( /([a-z0-9.-_]*buybtc[a-z0-9.-_]*@gmail[.])com/ig, "I am a scammer and will steal your coins! $1cum to meet your sticky end!" ).replace( /([a-z0-9.-_]*buybtc[a-z0-9.-_]*@gmail[.])com/ig, "").replace( /([^a-z])[ᴦrг]⁠*[aΑА]⁠*[pр]⁠*[eеΕ]/ig, "$1tickle").replace( /([^a-z])[ᴦrг]⁠*[aΑА]⁠*[pр]⁠*i⁠*([^d])/ig, "$1tickli$2").replace( /([^a-z])[ᴦrг]⁠*[aΑА]⁠*[eеΕ]⁠*[pр]/ig, "$1tickel").replace( /([^a-z])[ᴦrг]⁠*[aΑА]⁠*[eеΕ]⁠*[pр]⁠*i/ig, "$1tickeli").replace( /([nɴⓝ])⁠*([1iɪ!|ⓘ]⁠*)([gɢⓖ])⁠*([gɢⓖ]⁠*(?:[gɢⓖ]⁠*)*)([3eеΕᴇⓔ]⁠*[ᴦrгʀⓡ]|[aᴀ4ⓐ])/ig, "$3$2$1$4$5").replace( /(<.*>.*?)\b(butthurt)\b/i, '$1$2' ).replace( /(dogechain[.]info\/)(?:[a-w]{2}|zh-cn)\//g, "$1").replace( /([^a-zA-Z0-9=?/])(?:(?:https?:\/\/)?dogechain[.]info\/tx(?:-index)?\/)?([0-9a-f]{8})([0-9a-f]{56})\b/g, '$1[$2]' ).replace( /([^a-zA-Z0-9=?/])(?:(?:https?:\/\/)?blockchain[.]info\/address\/)?(1[1-9A-HJ-NP-Za-km-z]{7})([1-9A-HJ-NP-Za-km-z]{24,26})\b/g, '$1[$2]' ).replace( /([^a-zA-Z0-9=?/])(?:(?:https?:\/\/)?dogechain[.]info\/address\/)?(D[1-9A-HJ-NP-Za-km-z]{7})([1-9A-HJ-NP-Za-km-z]{24,26})\b/g, '$1[such $2]' ).replace( /\b(https?:\/\/i[.]imgur[.]com\/[0-9a-z]{5,7}[.](?:jpe?g|png|gif)(?:[?][0-9]+)?)\b/ig, '[img]' ).replace( /\b(https?:\/\/imgur[.]com\/(?:a|gallery)\/[0-9a-z]{5,7}\/?(?:#\d+)?)(?:\b|$)/ig, '[imgs]' ).replace( /\b(https?:\/\/(?:(?:www[.])?youtube[.]com\/watch[?]v=|youtu[.]be\/)[0-9a-z_-]{11}[?]?(?:(?:&)?(?:wide|(?:feature|list)=[a-z.0-9]*|t=[0-9msh]+))*)\b/ig, '[video]' ).replace( /\b(https?:\/\/(?:(?:www|r2)[.])?reddit[.]com\/r\/([a-z0-9]+)\/comments\/[a-z0-9]+\/([a-z0-9_]+)(?:\/[0-9a-z]+)?\/?)(\b| |$)/ig, '[reddit:$2 $3]$4' ).replace( /\b(https:\/\/bitcointalk[.]org\/(?:index[.]php)?[?]topic=[0-9]+(?:[.](?:new#new|(?:msg)?[0-9]+))?(?:;(?:all|topicseen))?(?:#new|#msg[0-9]+)?)\b/ig, '[thread]' ), t = moment(e).format("HH:mm:ss") + " " + t, n = n ? " " + n : "", t = '
' + t + "
", r && chatbets_showing ? chatbets.prepend(t) : chatlog.append( t) }