scopeWith

fun Contact?.scopeWith(vararg others: Contact?): MessageScope
inline fun <R> Contact?.scopeWith(vararg others: Contact?, action: MessageScope.() -> R): R
inline fun <R> Contact?.scopeWith(vararg others: CommandSender?, action: MessageScope.() -> R): R
inline fun <R> Contact?.scopeWith(vararg others: MessageScope?, action: MessageScope.() -> R): R
inline fun <R> CommandSender?.scopeWith(vararg others: Contact?, action: MessageScope.() -> R): R
inline fun <R> CommandSender?.scopeWith(vararg others: CommandSender?, action: MessageScope.() -> R): R
inline fun <R> CommandSender?.scopeWith(vararg others: MessageScope?, action: MessageScope.() -> R): R
inline fun <R> MessageScope?.scopeWith(vararg others: Contact?, action: MessageScope.() -> R): R
inline fun <R> MessageScope?.scopeWith(vararg others: CommandSender?, action: MessageScope.() -> R): R
inline fun <R> MessageScope?.scopeWith(vararg others: MessageScope?, action: MessageScope.() -> R): R


Deprecated

Senseless scopeWith. Use asMessageScope.

Replace with

import net.mamoe.mirai.console.util.asMessageScope
this.asMessageScope()

inline fun <R> Contact.scopeWith(action: MessageScope.() -> R): R
inline fun <R> CommandSender.scopeWith(action: MessageScope.() -> R): R
inline fun <R> MessageScope.scopeWith(action: MessageScope.() -> R): R

Deprecated

Senseless scopeWith. Use .asMessageScope().invoke.

Replace with

import net.mamoe.mirai.console.util.asMessageScope
import net.mamoe.mirai.console.util.invoke
this.asMessageScope()(action)