簡體   English   中英

我不明白代碼應該做什么?

[英]I don't understand what the code is suppose to do?

module.exports = (client, message, args) => { 
  message.reply("Pong!");
}

它在回復什么? 我真的不明白代碼應該做什么,因為它說的是“message.reply”,但它應該回復什么消息?

在通道中發送的消息字符串,

例如,如果您發送“嘿,我正在這個 discord 頻道發送此消息”,則message

module.exports = (client, "message", args) => { 
...
}

message.reply()中的message變量就是上面module.exports function 中的message變量。

當您將所有這些放在一起時, message.reply("")將使用您放在.reply(""); .

例子:

message.reply("Replying to this message"); 將回復頻道中發送的消息,字符串為"Replying to this message"

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM