Removed unnecessary method and restructured code

This commit is contained in:
bluefireoly
2020-07-15 15:29:01 +02:00
parent 48499bc1fe
commit c23940ea0c
2 changed files with 14 additions and 42 deletions

View File

@@ -0,0 +1,14 @@
@file:Suppress("MemberVisibilityCanBePrivate")
package net.axay.kspigot.chat
import net.md_5.bungee.api.chat.BaseComponent
import org.bukkit.command.CommandSender
fun CommandSender.sendMessage(vararg components: BaseComponent) {
this.spigot().sendMessage(*components)
}
fun CommandSender.sendMessage(builder: KSpigotComponentBuilder.() -> Unit) {
this.spigot().sendMessage(*KSpigotComponentBuilder().apply(builder).create())
}