aboutsummaryrefslogtreecommitdiff
path: root/commands/Utility/vtquote.js
diff options
context:
space:
mode:
authorAlee <alee14498@gmail.com>2018-08-01 22:46:19 -0400
committerAlee <alee14498@gmail.com>2018-08-01 22:46:19 -0400
commit5881cae922e44a93cff005f497dd02e7bbdfaee9 (patch)
tree247648ba71df8afe844795e39448a64c2df4ceb8 /commands/Utility/vtquote.js
parent8187456565b286e8e9fd2402c999fbe34db16604 (diff)
downloadPokeBot-5881cae922e44a93cff005f497dd02e7bbdfaee9.tar.gz
PokeBot-5881cae922e44a93cff005f497dd02e7bbdfaee9.tar.bz2
PokeBot-5881cae922e44a93cff005f497dd02e7bbdfaee9.zip
Added features from AleeBot
Diffstat (limited to 'commands/Utility/vtquote.js')
-rw-r--r--commands/Utility/vtquote.js54
1 files changed, 54 insertions, 0 deletions
diff --git a/commands/Utility/vtquote.js b/commands/Utility/vtquote.js
new file mode 100644
index 0000000..ec85888
--- /dev/null
+++ b/commands/Utility/vtquote.js
@@ -0,0 +1,54 @@
+/****************************************
+ *
+ * VTQuote: Plugin for Galaxy that tells you VT quotes.
+ * Copyright (C) 2018 TheEdge, jtsshieh, Alee
+ *
+ * Licensed under the Open Software License version 3.0
+ *
+ * *************************************/
+module.exports.run = async (client, message) => {
+ const Discord = require('discord.js');
+
+ let VictorQuote;
+
+ function GetVictorQuote(quoteNum = -1) {
+ VictorQuote = new Discord.RichEmbed();
+
+ let quo = require('../assets/vtquotes.json').quotes
+
+ if (quoteNum == -1) {
+ quoteNum = Math.floor(Math.random() * 1000) % quo.length;
+ quo=quo[quoteNum];
+ }
+
+ const author = quo.author;
+ const authorImage = quo.authorImage;
+ const quote = quo.quote;
+ const year = quo.year;
+ const url = quo.url;
+
+ VictorQuote.setAuthor(author, authorImage);
+ VictorQuote.setColor('#1fd619');
+ VictorQuote.setDescription(quote);
+ VictorQuote.setFooter('- ' + year);
+ VictorQuote.setURL(url);
+
+ return VictorQuote;
+ }
+
+ const victorquote = GetVictorQuote();
+ message.reply('Alright, here\'s your Victor quote.')
+ message.channel.send(victorquote);
+ };
+
+ exports.conf = {
+ aliases: [],
+ guildOnly: false,
+ };
+ exports.help = {
+ name: 'vtquote',
+ description: 'Tells you quotes when victor accidentaly swore.',
+ usage: 'vtquote',
+ category: '- Quote Commands',
+ };
+ \ No newline at end of file