mirror of
https://github.com/mamoe/mirai.git
synced 2025-01-09 18:00:33 +08:00
Inlined replies
This commit is contained in:
parent
679f1c3d4d
commit
7b0175e8c7
@ -12,14 +12,14 @@ import net.mamoe.mirai.message.defaults.MessageChain
|
|||||||
class GroupMessageEvent(bot: Bot, group: Group, val sender: QQ, val message: MessageChain) : GroupEvent(bot, group) {
|
class GroupMessageEvent(bot: Bot, group: Group, val sender: QQ, val message: MessageChain) : GroupEvent(bot, group) {
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: Message) = group.sendMessage(message)
|
suspend inline fun reply(message: Message) = group.sendMessage(message)
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: String) = group.sendMessage(message)
|
suspend inline fun reply(message: String) = group.sendMessage(message)
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: List<Message>) = group.sendMessage(message)
|
suspend inline fun reply(message: List<Message>) = group.sendMessage(message)
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: MessageChain) = group.sendMessage(message)
|
suspend inline fun reply(message: MessageChain) = group.sendMessage(message)
|
||||||
}
|
}
|
||||||
|
@ -11,14 +11,14 @@ import net.mamoe.mirai.message.defaults.MessageChain
|
|||||||
class FriendMessageEvent(bot: Bot, sender: QQ, val message: MessageChain) : FriendEvent(bot, sender) {
|
class FriendMessageEvent(bot: Bot, sender: QQ, val message: MessageChain) : FriendEvent(bot, sender) {
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: Message) = sender.sendMessage(message)
|
suspend inline fun reply(message: Message) = sender.sendMessage(message)
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: String) = sender.sendMessage(message)
|
suspend inline fun reply(message: String) = sender.sendMessage(message)
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: List<Message>) = sender.sendMessage(message)
|
suspend inline fun reply(message: List<Message>) = sender.sendMessage(message)
|
||||||
|
|
||||||
@JvmSynthetic
|
@JvmSynthetic
|
||||||
suspend fun reply(message: MessageChain) = sender.sendMessage(message)
|
suspend inline fun reply(message: MessageChain) = sender.sendMessage(message)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user