diff --git a/detectors/basicDetector.js b/detectors/basicDetector.js index 951429c..09443e1 100644 --- a/detectors/basicDetector.js +++ b/detectors/basicDetector.js @@ -1,10 +1,11 @@ import Detector from "./Detector.js"; import { cleanMessageContent } from "../utils/strings.js"; -//check the regex for "quoi" -// trigger if it's at the end of the sentence (tu fais quoi) -// trigger if it's followed by 1 to 3 words (c'est quoi ça) -// skip if in the middle of a long sentence (je sais pas quoi faire demain) +/*check the regex for "quoi" +trigger if it's at the end of the sentence (tu fais quoi) +trigger if it's followed by 1 to 3 words (c'est quoi ça) +skip if in the middle of a long sentence (je sais pas quoi faire demain) +*/ const answers = [ ...Array(10).fill('feur'), diff --git a/detectors/coubehDetector.js b/detectors/coubehDetector.js index 1f0bccd..f9ceeaa 100644 --- a/detectors/coubehDetector.js +++ b/detectors/coubehDetector.js @@ -1,6 +1,9 @@ import Detector from "./Detector.js"; import { cleanMessageContent } from "../utils/strings.js"; +/*check if someone reply to a "quoi" with a "quoicoubeh" or "coubeh" +send roasts +*/ const answers = [ 'Motif de ban ça', "Non mais t'es pas bien toi ?", diff --git a/detectors/feurDetector.js b/detectors/feurDetector.js index 36edf2e..30564cd 100644 --- a/detectors/feurDetector.js +++ b/detectors/feurDetector.js @@ -1,6 +1,10 @@ import Detector from "./Detector.js"; import { cleanMessageContent } from "../utils/strings.js"; +/*check if someone reply to a "quoi" with a "feur" or "quoifeur" +send praise +*/ + const answers = [ "Toi t'es un bon", "ça j'aime, ça", @@ -8,7 +12,10 @@ const answers = [ "aller !", 'https://tenor.com/fr/view/deez-ha-got-heem-got-em-got-him-gif-4824899', 'https://tenor.com/fr/view/kaamelott-joueur-voil%C3%A0-faites-plaisir-gif-18227872', - 'https://tenor.com/view/kaamelott-yvain-exp%C3%A9ience-champion-cest-lexp%C3%A9rience-qui-parle-gif-17313437' + 'https://tenor.com/view/kaamelott-yvain-exp%C3%A9ience-champion-cest-lexp%C3%A9rience-qui-parle-gif-17313437', + 'https://tenor.com/fr/view/caprio-oh-well-gif-25938306', + 'https://tenor.com/fr/view/pro-move-ted-lasso-nicely-done-compliment-jason-sudeikis-gif-17283104469342346529', + 'https://tenor.com/fr/view/well-played-sir-gif-22047381' ]; export default class FeurDetector extends Detector { diff --git a/detectors/pingDetector.js b/detectors/pingDetector.js index ee31852..9bd8b7d 100644 --- a/detectors/pingDetector.js +++ b/detectors/pingDetector.js @@ -1,6 +1,8 @@ import Detector from "./Detector.js"; import { cleanMessageContent } from "../utils/strings.js"; +//check if the bot is pinged by someone + const answers = [ 'Oui ? (stiti)', "On m'a appelé ?", diff --git a/detectors/suffixDetector.js b/detectors/suffixDetector.js index 4bff140..b06d9ab 100644 --- a/detectors/suffixDetector.js +++ b/detectors/suffixDetector.js @@ -2,6 +2,16 @@ import Detector from "./Detector.js"; import compromise from 'fr-compromise'; import { cleanMessageContent } from "../utils/strings.js"; +/*if the beginning of the sentence (before trigger) is less than 7 words then drop +otherwise copy the sentence and adjust +exemple : on mange quoi ce midi ? on mange feur ce midi + +does not conjugate + +cut to "ça" or "ca" if used +exemple : c'est quoi ce truc ? c'est feur ce truc +*/ + const suffixes = [ ', mon gars', ', mec', diff --git a/detectors/withPronounDetector.js b/detectors/withPronounDetector.js index be54775..2d917c6 100644 --- a/detectors/withPronounDetector.js +++ b/detectors/withPronounDetector.js @@ -4,6 +4,10 @@ import conj from 'conjugation-fr'; import { toInfinitive } from "../data.js"; // check path ?? import { cleanMessageContent } from "../utils/strings.js"; +/*check the pronoun / subject of the question to answer properly by conjugating +exemple : tu fais quoi ? je fais feur +*/ + const suffixes = [ ', mon gars', ', mec', @@ -13,9 +17,6 @@ const suffixes = [ '' ]; -// check the pronoun of the question to answer properly -// exemple : tu fais quoi ? je fais feur - export default class withPronounDetector extends Detector { async createSpecificReply(message) { const reference = await message.fetchReference().catch(() => null);