From 0d4ac37a5aff56655be1c127c80b55b38579a8fc Mon Sep 17 00:00:00 2001 From: Daniel Odendahl Jr Date: Mon, 3 Apr 2017 01:00:44 +0000 Subject: [PATCH] Yugioh Card Images --- commands/search/yugioh.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/commands/search/yugioh.js b/commands/search/yugioh.js index 24dc323d..9be2d5cd 100644 --- a/commands/search/yugioh.js +++ b/commands/search/yugioh.js @@ -27,12 +27,15 @@ module.exports = class YuGiOhCommand extends commando.Command { try { let response = await request .get(`http://yugiohprices.com/api/card_data/${cardName}`); + let response2 = await request + .get(`http://yugiohprices.com/api/card_image/${cardName}`); if (response.body.data.card_type === 'monster') { const embed = new Discord.RichEmbed() .setColor(0xBE5F1F) .setTitle(response.body.data.name) .setDescription(response.body.data.text) .setAuthor('Yu-Gi-Oh!', 'http://vignette3.wikia.nocookie.net/yugioh/images/1/10/Back-TF-EN-VG.png/revision/latest?cb=20120824043558') + .setThumbnail(response2.redirects[0]) .addField('**Card Type:**', response.body.data.card_type, true) .addField('**Species:**',