mirror of
https://github.com/fumiama/NanoBot.git
synced 2026-06-09 04:30:24 +08:00
finish
This commit is contained in:
5
bot.go
5
bot.go
@@ -143,6 +143,11 @@ func (bot *Bot) Authorization() string {
|
||||
return "Bot " + bot.AppID + "." + bot.Token
|
||||
}
|
||||
|
||||
// AtMe 返回 "<@!"+bot.ready.User.ID+">"
|
||||
func (bot *Bot) AtMe() string {
|
||||
return "<@!" + bot.ready.User.ID + ">"
|
||||
}
|
||||
|
||||
// receive 收一个 payload
|
||||
func (bot *Bot) reveive() (payload WebsocketPayload, err error) {
|
||||
err = bot.conn.ReadJSON(&payload)
|
||||
|
||||
Reference in New Issue
Block a user