Skip to content

Commit

Permalink
✏️ 优化戳一戳命令牌为群号
Browse files Browse the repository at this point in the history
  • Loading branch information
kanrichan authored Dec 7, 2021
1 parent b9ddcfc commit ca4a682
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugin_chat/chat.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,11 @@ func init() { // 插件主体
Handle(func(ctx *zero.Ctx) {
var nickname = zero.BotConfig.NickName[0]
switch {
case poke.Load(ctx.Event.UserID).AcquireN(3):
case poke.Load(ctx.Event.GroupID).AcquireN(3):
// 5分钟共8块命令牌 一次消耗3块命令牌
time.Sleep(time.Second * 1)
ctx.SendChain(message.Text("请不要戳", nickname, " >_<"))
case poke.Load(ctx.Event.UserID).Acquire():
case poke.Load(ctx.Event.GroupID).Acquire():
// 5分钟共8块命令牌 一次消耗1块命令牌
time.Sleep(time.Second * 1)
ctx.SendChain(message.Text("喂(#`O′) 戳", nickname, "干嘛!"))
Expand Down

0 comments on commit ca4a682

Please sign in to comment.