2021-11-18 18:56:42 +01:00
|
|
|
module.exports = {
|
2022-01-31 20:13:11 +01:00
|
|
|
name: "economy",
|
2021-11-18 18:56:42 +01:00
|
|
|
category: "Owner",
|
2022-01-31 20:13:11 +01:00
|
|
|
description: "Add/Remove coins from someone",
|
2021-11-18 18:56:42 +01:00
|
|
|
Owner: true,
|
|
|
|
options: [
|
|
|
|
{
|
2022-02-04 13:07:17 +01:00
|
|
|
type: "SUB_COMMAND",
|
2022-01-31 20:13:11 +01:00
|
|
|
name: "add",
|
|
|
|
description: "Remove coins from someone",
|
|
|
|
options: [
|
|
|
|
{
|
|
|
|
type: 6,
|
|
|
|
name: "user",
|
|
|
|
description: "The user you want to add",
|
|
|
|
required: true,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
type: 4,
|
|
|
|
name: "cp",
|
|
|
|
description: "The amount of CP you want to add",
|
|
|
|
required: true,
|
|
|
|
},
|
|
|
|
],
|
2021-11-18 18:56:42 +01:00
|
|
|
},
|
|
|
|
{
|
2022-02-04 13:07:17 +01:00
|
|
|
type: "SUB_COMMAND",
|
2022-01-31 20:13:11 +01:00
|
|
|
name: "rmv",
|
|
|
|
description: "Remove coins from someone",
|
|
|
|
options: [
|
|
|
|
{
|
|
|
|
type: 6,
|
|
|
|
name: "user",
|
|
|
|
description: "The user you want to remove",
|
|
|
|
required: true,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
type: 4,
|
|
|
|
name: "cp",
|
|
|
|
description: "The amount of CP you want to remove",
|
|
|
|
required: true,
|
|
|
|
},
|
|
|
|
],
|
2021-11-18 18:56:42 +01:00
|
|
|
},
|
|
|
|
],
|
|
|
|
run: async (client, interaction, args) => {
|
2022-01-31 20:13:11 +01:00
|
|
|
if (args[0] === "add") {
|
|
|
|
await client.add(args[0], args[1], interaction);
|
|
|
|
interaction.followUp({
|
|
|
|
content: `<a:nyx_checkmark:897240322411724841> Successfully added **${interaction.options.getInteger(
|
|
|
|
"cp"
|
|
|
|
)}** ${client.currency} in **${
|
|
|
|
interaction.options.getUser("user").username
|
|
|
|
}**'s balance`,
|
|
|
|
});
|
|
|
|
}
|
|
|
|
if (args[0] === "rmv") {
|
|
|
|
await client.rmv(args[0], args[1]);
|
|
|
|
interaction.followUp({
|
|
|
|
content: `<a:nyx_checkmark:897240322411724841> Successfully removed **${interaction.options.getInteger(
|
|
|
|
"cp"
|
|
|
|
)}** ${client.currency} from **${
|
|
|
|
interaction.options.getUser("user").username
|
|
|
|
}**'s balance`,
|
|
|
|
});
|
|
|
|
}
|
2021-11-18 18:56:42 +01:00
|
|
|
},
|
|
|
|
};
|