rewrite trigger system

This commit is contained in:
Flummi
2019-08-19 01:28:01 +00:00
parent 22d79eed18
commit 3a751f2e52
30 changed files with 536 additions and 570 deletions

View File

@@ -1,7 +1,9 @@
import sql from "../sql";
export default bot => {
bot._trigger.set("rape", new bot.trigger({
export default async bot => {
return [{
name: "rape",
call: /^(\.|\/)rape/i,
set: "nxy",
help: {
@@ -28,9 +30,8 @@ export default bot => {
});
}
}
}));
bot._trigger.set("owe", new bot.trigger({
}, {
name: "owe",
call: /^(\.|\/)owe/i,
set: "nxy",
help: {
@@ -53,5 +54,5 @@ export default bot => {
return e.reply("user not found");
});
}
}));
};
}];
};