update
This commit is contained in:
44
commands/Management/DeleteApplicationCommands.js
Normal file
44
commands/Management/DeleteApplicationCommands.js
Normal file
@ -0,0 +1,44 @@
|
||||
require("dotenv").config();
|
||||
const { EmbedBuilder, REST, Routes } = require('discord.js');
|
||||
|
||||
ownerList = [
|
||||
'213966480621043712'
|
||||
];
|
||||
|
||||
const rest = new REST().setToken(process.env.TOKEN);
|
||||
|
||||
// module.exports = {
|
||||
// name: "deleteslashcommands",
|
||||
// private: true,
|
||||
// description: "Deregister guild slash commands",
|
||||
|
||||
// run: async (client, interaction) => {
|
||||
// if (ownerList.includes(interaction.user.id)) {
|
||||
|
||||
// rest.put(Routes.applicationGuildCommands(client.user.id, interaction.guild.id), { body: [] })
|
||||
// .then(() => {
|
||||
// console.log(`Successfully deleted all guild commands of guild ${interaction.guild.id}.`)
|
||||
// const embed = new EmbedBuilder()
|
||||
// .setColor("#FF0000")
|
||||
// .setTitle("Slash commands deleted successfully")
|
||||
// .setDescription(`Guild slash commands deleted successfully`)
|
||||
// .setTimestamp()
|
||||
// .setFooter({ text: `Requested by ${interaction.user.tag}`, iconURL: `${interaction.user.displayAvatarURL()}` });
|
||||
// interaction.followUp({ embeds: [embed] });
|
||||
// })
|
||||
// .catch((err) => {
|
||||
// interaction.followUp({ content: 'Something went wrong'});
|
||||
// console.log(err);
|
||||
// });
|
||||
|
||||
// } else {
|
||||
// const embed = new EmbedBuilder()
|
||||
// .setColor("#FF0000")
|
||||
// .setTitle("🐺 no perms")
|
||||
// .setDescription(`You have no perms to do this.`)
|
||||
// .setTimestamp()
|
||||
// .setFooter({ text: `Requested by ${interaction.user.tag}`, iconURL: `${interaction.user.displayAvatarURL()}` });
|
||||
// interaction.followUp({ embeds: [embed] });
|
||||
// }
|
||||
// },
|
||||
// };
|
36
commands/Management/SetStatus.js
Normal file
36
commands/Management/SetStatus.js
Normal file
@ -0,0 +1,36 @@
|
||||
const { EmbedBuilder, SlashCommandBuilder } = require('discord.js');
|
||||
const client = require('../../index.js');
|
||||
|
||||
developerList = [
|
||||
'213966480621043712',
|
||||
];
|
||||
|
||||
module.exports = {
|
||||
name: "setstatus",
|
||||
private: true,
|
||||
description: "Set status",
|
||||
|
||||
run: async (client, interaction) => {
|
||||
if (developerList.includes(interaction.user.id)) {
|
||||
|
||||
client.user.setStatus('dnd')
|
||||
|
||||
const embed = new EmbedBuilder()
|
||||
.setColor("#FF0000")
|
||||
.setTitle("Status set")
|
||||
.setDescription(`Bot status set to predefined value`)
|
||||
.setTimestamp()
|
||||
.setFooter({ text: `Requested by ${interaction.user.tag}`, iconURL: `${interaction.user.displayAvatarURL()}` });
|
||||
interaction.followUp({ embeds: [embed] });
|
||||
|
||||
} else {
|
||||
const embed = new EmbedBuilder()
|
||||
.setColor("#FF0000")
|
||||
.setTitle("🐺 no perms")
|
||||
.setDescription(`You have no perms to do this.`)
|
||||
.setTimestamp()
|
||||
.setFooter({ text: `Requested by ${interaction.user.tag}`, iconURL: `${interaction.user.displayAvatarURL()}` });
|
||||
interaction.followUp({ embeds: [embed] });
|
||||
}
|
||||
},
|
||||
};
|
49
commands/Management/resetwolfcount.js
Normal file
49
commands/Management/resetwolfcount.js
Normal file
@ -0,0 +1,49 @@
|
||||
const { EmbedBuilder } = require('discord.js');
|
||||
const wolfcount = require('../../models/wolfcount');
|
||||
const { spawn } = require("child_process");
|
||||
|
||||
ownerList = [
|
||||
'213966480621043712',
|
||||
'237542879227019264',
|
||||
'294840381080600576'
|
||||
];
|
||||
|
||||
module.exports = {
|
||||
name: "wolfcountreset",
|
||||
private: true,
|
||||
description: "Reset the wolfcount",
|
||||
|
||||
run: async (client, interaction) => {
|
||||
if (ownerList.includes(interaction.user.id)) {
|
||||
|
||||
resetcount = 0
|
||||
|
||||
// Reset the wolf count
|
||||
wolfcount.findByIdAndUpdate("6447da87681fd1bc486a4923", {count: resetcount}).then(() => {
|
||||
console.log('');
|
||||
console.log('Count reset!');
|
||||
}).catch((error) => {
|
||||
console.error(error);
|
||||
});
|
||||
|
||||
const embed = new EmbedBuilder()
|
||||
.setColor("#FF0000")
|
||||
.setTitle("🐺 count reset")
|
||||
.setDescription(`The count has been reset. (Requested by: ${interaction.user.tag})`)
|
||||
.setTimestamp()
|
||||
.setFooter({ text: `Requested by ${interaction.user.tag}`, iconURL: `${interaction.user.displayAvatarURL()}` });
|
||||
interaction.followUp({ embeds: [embed] });
|
||||
|
||||
basecount = resetcount;
|
||||
|
||||
} else {
|
||||
const embed = new EmbedBuilder()
|
||||
.setColor("#FF0000")
|
||||
.setTitle("🐺 no perms")
|
||||
.setDescription(`You have no perms to do this.`)
|
||||
.setTimestamp()
|
||||
.setFooter({ text: `Requested by ${interaction.user.tag}`, iconURL: `${interaction.user.displayAvatarURL()}` });
|
||||
interaction.followUp({ embeds: [embed] });
|
||||
}
|
||||
},
|
||||
};
|
Reference in New Issue
Block a user