2024-09-08 19:29:21 +08:00
|
|
|
/*
|
|
|
|
|
* Copyright © 2024 RTAkland
|
|
|
|
|
* Author: RTAkland
|
|
|
|
|
* Date: 2024/9/8
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
2024-09-20 16:30:33 +08:00
|
|
|
package cn.rtast.fancybot.commands.misc
|
2024-09-08 19:29:21 +08:00
|
|
|
|
2024-09-26 05:20:10 +08:00
|
|
|
import cn.rtast.fancybot.annotations.CommandDescription
|
2024-10-24 16:55:14 +08:00
|
|
|
import cn.rtast.fancybot.instance
|
2024-09-08 19:29:21 +08:00
|
|
|
import cn.rtast.rob.entity.GroupMessage
|
|
|
|
|
import cn.rtast.rob.util.BaseCommand
|
|
|
|
|
import cn.rtast.rob.util.ob.MessageChain
|
2024-09-19 11:06:40 +08:00
|
|
|
import cn.rtast.rob.util.ob.OneBotListener
|
2024-09-08 19:29:21 +08:00
|
|
|
|
2024-09-26 05:20:10 +08:00
|
|
|
@CommandDescription("资料卡点赞")
|
2024-10-01 18:54:25 +08:00
|
|
|
class SendLikeCommand : BaseCommand() {
|
2024-09-08 19:29:21 +08:00
|
|
|
override val commandNames = listOf("赞我")
|
|
|
|
|
|
2024-09-19 11:06:40 +08:00
|
|
|
override suspend fun executeGroup(listener: OneBotListener, message: GroupMessage, args: List<String>) {
|
2024-10-24 16:55:14 +08:00
|
|
|
instance.action.sendLike(message.sender.userId, 10)
|
2024-09-08 19:29:21 +08:00
|
|
|
val msg = MessageChain.Builder()
|
|
|
|
|
.addReply(message.messageId)
|
|
|
|
|
.addText("👍了你十下~~😁")
|
|
|
|
|
.build()
|
2024-10-24 16:55:14 +08:00
|
|
|
message.reply(msg)
|
2024-09-08 19:29:21 +08:00
|
|
|
}
|
|
|
|
|
}
|