2022-10-26 12:38:28 +02:00
|
|
|
const { EmbedBuilder } = require("discord.js");
|
2021-06-12 12:53:51 +02:00
|
|
|
module.exports = {
|
|
|
|
name: "work",
|
|
|
|
description: "Work to earn money",
|
|
|
|
category: "Economy",
|
|
|
|
timeout: 1000 * 60 * 10,
|
2021-09-17 18:28:39 +02:00
|
|
|
run: async (client, interaction, args, utils) => {
|
2021-11-18 18:56:42 +01:00
|
|
|
const jobs = [
|
2021-06-12 12:53:51 +02:00
|
|
|
"Software engineer",
|
|
|
|
"Programmer",
|
|
|
|
"Teacher",
|
|
|
|
"YouTuber",
|
|
|
|
"Student",
|
|
|
|
"Desginer",
|
|
|
|
"Editor",
|
|
|
|
"Banker",
|
|
|
|
];
|
2021-09-17 18:28:39 +02:00
|
|
|
const earning = utils.rndint(5000, 3000);
|
2021-11-18 18:56:42 +01:00
|
|
|
const job = jobs[Math.floor(Math.random() * jobs.length)];
|
2021-09-17 18:28:39 +02:00
|
|
|
await client.add(interaction.user.id, earning, interaction);
|
|
|
|
interaction.followUp({
|
2021-11-18 18:56:42 +01:00
|
|
|
embeds: [
|
2022-10-26 12:38:28 +02:00
|
|
|
new EmbedBuilder()
|
2021-11-18 18:56:42 +01:00
|
|
|
.setAuthor(
|
|
|
|
interaction.user.tag,
|
|
|
|
interaction.user.displayAvatarURL({ dynamic: true })
|
|
|
|
)
|
|
|
|
.setDescription(
|
|
|
|
`Good Job! You worked as a **${job}** and earned **${earning}${client.currency}**`
|
|
|
|
)
|
|
|
|
.setTimestamp()
|
2022-10-26 12:38:28 +02:00
|
|
|
.setFooter({
|
|
|
|
text: `Made by ${client.author}`,
|
|
|
|
iconURL: client.user.displayAvatarURL(),
|
|
|
|
})
|
2021-11-18 18:56:42 +01:00
|
|
|
.setColor(client.color),
|
|
|
|
],
|
2021-09-17 18:28:39 +02:00
|
|
|
});
|
2021-06-12 12:53:51 +02:00
|
|
|
},
|
|
|
|
};
|