Add basic sack util
[no changelog]
This commit is contained in:
@@ -4,7 +4,9 @@ import com.mojang.brigadier.CommandDispatcher
|
||||
import com.mojang.brigadier.arguments.StringArgumentType.string
|
||||
import io.ktor.client.statement.bodyAsText
|
||||
import net.fabricmc.fabric.api.client.command.v2.FabricClientCommandSource
|
||||
import net.minecraft.nbt.NbtOps
|
||||
import net.minecraft.text.Text
|
||||
import net.minecraft.text.TextCodecs
|
||||
import moe.nea.firmament.apis.UrsaManager
|
||||
import moe.nea.firmament.events.CommandEvent
|
||||
import moe.nea.firmament.events.FirmamentEventBus
|
||||
@@ -24,6 +26,7 @@ import moe.nea.firmament.util.MC
|
||||
import moe.nea.firmament.util.SBData
|
||||
import moe.nea.firmament.util.ScreenUtil
|
||||
import moe.nea.firmament.util.SkyblockId
|
||||
import moe.nea.firmament.util.accessors.messages
|
||||
import moe.nea.firmament.util.collections.InstanceList
|
||||
import moe.nea.firmament.util.collections.WeakCache
|
||||
|
||||
@@ -205,6 +208,14 @@ fun firmamentCommand() = literal("firmament") {
|
||||
}
|
||||
}
|
||||
}
|
||||
thenLiteral("dumpchat") {
|
||||
thenExecute {
|
||||
MC.inGameHud.chatHud.messages.forEach {
|
||||
val nbt = TextCodecs.CODEC.encodeStart(NbtOps.INSTANCE, it.content).orThrow
|
||||
println(nbt)
|
||||
}
|
||||
}
|
||||
}
|
||||
thenLiteral("sbdata") {
|
||||
thenExecute {
|
||||
source.sendFeedback(Text.stringifiedTranslatable("firmament.sbinfo.profile", SBData.profileId))
|
||||
|
||||
Reference in New Issue
Block a user