launch

infix fun launch(block: suspend CoroutineScope.() -> Unit): TaskHandle

Launches a coroutine on the Bukkit main thread.

Return

a TaskHandle that can be used to cancel the coroutine

Parameters

block

the coroutine code