nxy: einschläfern & joke
This commit is contained in:
parent
42e2ad69ec
commit
3c6d3b951e
|
@ -219,4 +219,44 @@ module.exports = bot => {
|
|||
});
|
||||
}
|
||||
}));
|
||||
|
||||
bot._trigger.set("einschlaefern", new bot.trigger({
|
||||
call: /^(\.|\/)einschläfern/i,
|
||||
f: e => {
|
||||
e.replyAction(`schläfert [b]${e.args[0] || e.user.nick}[/b] mit einer Spritze Ketamin ein.`);
|
||||
}
|
||||
}));
|
||||
|
||||
bot._trigger.set("joke", new bot.trigger({
|
||||
call: /^(\.|\/)joke$/i,
|
||||
f: e => {
|
||||
rp("http://www.funny4you.at/webmasterprogramm/zufallswitz.php")
|
||||
.then(res => {
|
||||
res = res
|
||||
.split("<br />").join("")
|
||||
.split("<div class=\"funny4you\">").join("")
|
||||
.split("&").join("&")
|
||||
.split("ä").join("ä")
|
||||
.split("ö").join("ö")
|
||||
.split("ü").join("ü")
|
||||
.split("Ä").join("Ä")
|
||||
.split("Ö").join("Ö")
|
||||
.split("&Üuml;").join("Ü")
|
||||
.split("ß").join("ß")
|
||||
.split(""").join("\"")
|
||||
.replace(/\<span.*/i, "");
|
||||
|
||||
if(e.network !== "Telegram") {
|
||||
res
|
||||
.match(/.{1,450}/g)
|
||||
.map(e.reply);
|
||||
}
|
||||
else
|
||||
e.reply(res);
|
||||
})
|
||||
.catch(err => {
|
||||
console.log(err);
|
||||
});
|
||||
}
|
||||
}));
|
||||
};
|
Loading…
Reference in New Issue
Block a user