nyx/commands/Economy/work.js

26 lines
701 B
JavaScript
Raw Normal View History

2021-06-12 12:53:51 +02:00
const { Client, Message, MessageEmbed } = require("discord.js");
module.exports = {
name: "work",
description: "Work to earn money",
category: "Economy",
timeout: 1000 * 60 * 10,
run: async (client, message, args) => {
const job = [
"Software engineer",
"Programmer",
"Teacher",
"YouTuber",
"Student",
"Desginer",
"Editor",
"Banker",
];
const earning = client.function.rndint(5000, 3000);
const jobs = job[Math.floor(Math.random() * job.length)];
2021-07-13 05:17:39 +02:00
await client.add(message.author.id, earning, message);
2021-09-06 12:38:25 +02:00
return message.reply(
2021-07-13 05:17:39 +02:00
`You worked as a **${jobs}** and earned **${earning}${client.currency}**`
);
2021-06-12 12:53:51 +02:00
},
};