Yugioh Card Images

This commit is contained in:
Daniel Odendahl Jr
2017-04-03 01:00:44 +00:00
parent d80d537d8c
commit 0d4ac37a5a
+3
View File
@@ -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:**',