diff options
author | Minteck <contact@minteck.org> | 2022-01-07 18:04:44 +0100 |
---|---|---|
committer | Minteck <contact@minteck.org> | 2022-01-07 18:04:44 +0100 |
commit | ac2dea4a23ca72001e41c1dbf66ff1a0d01e217c (patch) | |
tree | 3cb37a7135bf5530917270ebde08f797ff52ea38 /embed.js | |
parent | 041b8d1035cf0e7f6f8c686ec5dd7aa4ef204907 (diff) | |
download | ponyfind-ac2dea4a23ca72001e41c1dbf66ff1a0d01e217c.tar.gz ponyfind-ac2dea4a23ca72001e41c1dbf66ff1a0d01e217c.tar.bz2 ponyfind-ac2dea4a23ca72001e41c1dbf66ff1a0d01e217c.zip |
Update
Diffstat (limited to 'embed.js')
-rwxr-xr-x[-rw-r--r--] | embed.js | 68 |
1 files changed, 34 insertions, 34 deletions
@@ -1,7 +1,7 @@ const { MessageEmbed } = require("discord.js"); const data = require('./data/data.json'); -module.exports = (page, id) => { +module.exports = (page, id, gid) => { if (typeof data[page] === "undefined") { return false; } @@ -39,98 +39,98 @@ module.exports = (page, id) => { break; } - let kind = l("Unknown", "Inconnu", id); + let kind = l("Unknown", "Inconnu", id, gid); switch (d.kind) { case "Pegasus": - kind = l("Pegasus", "Pégase", id) + kind = l("Pegasus", "Pégase", id, gid) break; case "Earth": - kind = l("Earth Pony", "Poney terrestre", id) + kind = l("Earth Pony", "Poney terrestre", id, gid) break; case "Ahuizotl": - kind = l("Ahiuzotl", "Ahuizotl", id) + kind = l("Ahiuzotl", "Ahuizotl", id, gid) break; case "Rabbit": - kind = l("Rabbit", "Lapin", id) + kind = l("Rabbit", "Lapin", id, gid) break; case "Pony": - kind = l("Pony", "Poney", id) + kind = l("Pony", "Poney", id, gid) break; case "Unicorn": - kind = l("Unicorn", "Licorne", id) + kind = l("Unicorn", "Licorne", id, gid) break; case "Draconequus": - kind = l("Draconequus", "Draconequus", id) + kind = l("Draconequus", "Draconequus", id, gid) break; case "Griffon": - kind = l("Griffon", "Gryphon", id) + kind = l("Griffon", "Gryphon", id, gid) break; case "Alligator": - kind = l("Alligator", "Alligator", id) + kind = l("Alligator", "Alligator", id, gid) break; case "Minotaur": - kind = l("Minotaur", "Minotaure", id) + kind = l("Minotaur", "Minotaure", id, gid) break; case "Buffalo": - kind = l("Buffalo", "Buffle", id) + kind = l("Buffalo", "Buffle", id, gid) break; case "Alicorn": - kind = l("Alicorn", "Alicorne", id) + kind = l("Alicorn", "Alicorne", id, gid) break; case "Persian": - kind = l("Persian", "Persien", id) + kind = l("Persian", "Persien", id, gid) break; case "Owl": - kind = l("Owl", "Hibou", id) + kind = l("Owl", "Hibou", id, gid) break; case "Phoenix": - kind = l("Phoenix", "Phénix", id) + kind = l("Phoenix", "Phénix", id, gid) break; case "Changelingbr": - kind = l("Changelingbr", "Changelingbr", id) + kind = l("Changelingbr", "Changelingbr", id, gid) break; case "Breezie": - kind = l("Breezie", "Brisie", id) + kind = l("Breezie", "Brisie", id, gid) break; case "Dragon": - kind = l("Dragon", "Dragon", id) + kind = l("Dragon", "Dragon", id, gid) break; case "Sea": - kind = l("Sea", "Mer", id) + kind = l("Sea", "Mer", id, gid) break; case "Tortoise": - kind = l("Tortoise", "Tortue", id) + kind = l("Tortoise", "Tortue", id, gid) break; case "Centaurref": - kind = l("Centaurref", "Centaurref", id) + kind = l("Centaurref", "Centaurref", id, gid) break; case "Collie": - kind = l("Collie", "Collie", id) + kind = l("Collie", "Collie", id, gid) break; case "Zebrabr": - kind = l("Zebrabr", "Zebrabr", id) + kind = l("Zebrabr", "Zebrabr", id, gid) break; } @@ -138,7 +138,7 @@ module.exports = (page, id) => { let naming = "-"; if (names.length > 5) { - naming = "- " + names[0] + "\n- " + names[1] + "\n- " + names[2] + "\n- " + names[3] + "\n- " + names[4] + "\n*" + l("and " + (names.length - 5) + " others", "et " + (names.length - 5) + " autres", id) + "*" + naming = "- " + names[0] + "\n- " + names[1] + "\n- " + names[2] + "\n- " + names[3] + "\n- " + names[4] + "\n*" + l("and " + (names.length - 5) + " others", "et " + (names.length - 5) + " autres", id, gid) + "*" } else { if (names.length > 1) { naming = "- " + names.join("\n- ") @@ -153,7 +153,7 @@ module.exports = (page, id) => { let jobs = page; if (d.occupation.length > 5) { - jobs = "- " + d.occupation[0] + "\n- " + d.occupation[1] + "\n- " + d.occupation[2] + "\n- " + d.occupation[3] + "\n- " + d.occupation[4] + "\n*" + l("and " + (d.occupation.length - 5) + " others", "et " + (d.occupation.length - 5) + " autres", id) + "*" + jobs = "- " + d.occupation[0] + "\n- " + d.occupation[1] + "\n- " + d.occupation[2] + "\n- " + d.occupation[3] + "\n- " + d.occupation[4] + "\n*" + l("and " + (d.occupation.length - 5) + " others", "et " + (d.occupation.length - 5) + " autres", id, gid) + "*" } else { if (d.occupation.length > 1) { jobs = "- " + d.occupation.join("\n- ") @@ -164,7 +164,7 @@ module.exports = (page, id) => { let location = page; if (d.residence.length > 5) { - location = "- " + d.residence[0] + "\n- " + d.residence[1] + "\n- " + d.residence[2] + "\n- " + d.residence[3] + "\n- " + d.residence[4] + "\n*" + l("and " + (d.residence.length - 5) + " others", "et " + (d.residence.length - 5) + " autres", id) + "*" + location = "- " + d.residence[0] + "\n- " + d.residence[1] + "\n- " + d.residence[2] + "\n- " + d.residence[3] + "\n- " + d.residence[4] + "\n*" + l("and " + (d.residence.length - 5) + " others", "et " + (d.residence.length - 5) + " autres", id, gid) + "*" } else { if (d.residence.length > 1) { location = "- " + d.residence.join("\n- ") @@ -179,11 +179,11 @@ module.exports = (page, id) => { .setImage(d.image) .setThumbnail(d.mark) .addFields([ - { name: l("Nicknames", "Surnoms", id), value: naming, inline: true }, - { name: l("Sex", "Sexe", id), value: d.sex === "F" ? "♀" : "♂", inline: true }, - { name: l("Kind", "Type", id), value: kind, inline: true }, - { name: l("Occupation(s)", "Occupation(s)", id), value: "(" + l("spoilers", "révélations", id) + ") ||" + jobs + "||", inline: true }, - { name: l("Home(s)", "Résidence(s)", id), value: "(" + l("spoilers", "révélations", id) + ") ||" + location + "||", inline: true } + { name: l("Nicknames", "Surnoms", id, gid), value: naming, inline: true }, + { name: l("Sex", "Sexe", id, gid), value: d.sex === "F" ? "♀" : "♂", inline: true }, + { name: l("Kind", "Type", id, gid), value: kind, inline: true }, + { name: l("Occupation(s)", "Occupation(s)", id, gid), value: "(" + l("spoilers", "révélations", id, gid) + ")\n||" + jobs + "||", inline: true }, + { name: l("Home(s)", "Résidence(s)", id, gid), value: "(" + l("spoilers", "révélations", id, gid) + ")\n||" + location + "||", inline: true } ]) - .setFooter(l("Content provided without warranty, use at your own risk.", "Contenu fourni sans aucune garantie, utilisez à vos risques et périls", id)) + .setFooter(l("Content provided without warranty, use at your own risk.", "Contenu fourni sans aucune garantie, utilisez à vos risques et périls", id, gid)) }
\ No newline at end of file |