【发布时间】:2021-05-22 06:14:12
【问题描述】:
我已经为我的 nuke commad 编写了一个代码
const { MessageEmbed } = require('discord.js')
module.exports = {
name: "nuke",
description: "Nukes a given channel",
run: async(client, message, args) => {
if(!message.member.hasPermission("ADMINISTRATOR")) {
return message.reply("You do not have the perms to use this cmd!")
}
let reason = args.join(" ") || "No Reason"
if(!message.channel.deletable) {
return message.reply("This channel cannot be nuked!")
}
let newchannel = await message.channel.clone()
await message.channel.delete()
let embed = new MessageEmbed()
.setTitle("Channel Nuked")
.setDescription(reason)
.setImage('https://media0.giphy.com/media/oe33xf3B50fsc/200.gif')
await newchannel.send(embed)
}
}
但我想要它,所以克隆频道并将其位置设置为与已被核弹但没有发生的频道相同
【问题讨论】:
-
这个命令不会把频道放到正确的位置,请帮忙
标签: command discord.js nuke