Begin work on a properly working setnick

This commit is contained in:
Anthony M 2021-03-04 22:33:44 -06:00 committed by GitHub
parent 6fd891b636
commit 2f705a3003
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 23 additions and 11 deletions

View File

@ -18,6 +18,17 @@ module.exports = {
var answer = (answers[index]);
console.log(args);
if (!question) {
const embed = {
"title": "<:AnitroxError:809651936563429416> Well that happened...",
"description": "You need to specify a question!",
"color": 13632027,
"footer": {
"icon_url": "https://images-ext-2.discordapp.net/external/-qaO3jaZLojhEnjrHiKABdXD7gLWqFvdUqHdskNGWhE/https/media.discordapp.net/attachments/549707869138714635/793524910172667964/Screenshot_26.png",
"text": "Made with ❤ in Illinois | Anitrox © 2018-2021 IDeletedSystem64"
}
}
}
const embed = {
"title": ":8ball: Anitrox 8 Ball",
"description": "Your question: **" + question + "**",
@ -35,5 +46,6 @@ module.exports = {
]
};
message.channel.send({ embed });
}
}

View File

@ -1,13 +1,13 @@
const { DiscordAPIError } = require("discord.js")
module.exports = {
name: "setnick",
description: "Set yours or another users nickname.",
execute(client, message, args) {
const guild = guild.fetch
const member = guild.member(message.author)
if (guild.member.hasPermission('CHANGE_NICKNAME')) {
message.channel.send("yes")
name: 'setnick',
description: 'Sets yours or another users nickname',
execute(client, message, args,) {
new Discord.GuildMember(data, guild);
const guild = guild.fetch
const member = guild.member(message.author)
if (message.channel.permissionsFor(message.author).has("CHANGE_NICKNAME")){
} else {
message.channel.send("no")
}}}
message.channel.send("no permission")
}
}}