const help = require('./helpFunctions');

module.exports = {
    henlo: henlo,
    mood: mood,
    whoAsked: whoAsked,
};

function henlo(message) {
    const emojis = ['🥰', '🐄', '🐮', '❤️', '👋', '🤠', '😊'];
    const randomNum = help.RNG(emojis.length);
    message.reply('Henlooo ' + message.author.username + '   ' + emojis[randomNum]);
}

function mood(message) {
    const responses = ['Not bad, how yee?', 'MOOdy', 'A bit sad 😢', 'Good, how yee?', 'I\'m fine, how yee?'];
    const randomNum = help.RNG(responses.length);
    message.reply(responses[randomNum]);
}

async function whoAsked(message) {
    const searchKey = 'who-asked';
    const gifAmount = 20;
    const gifs = `https://g.tenor.com/v1/search?q=${searchKey}&key=${process.env.TENOR}&limit=${gifAmount}`;

    message.reply({ embeds: [await help.getGifEmbed(gifs, gifAmount)] });
}