Kinecraft is a library for the Kotlin language designed to work within the Minecraft environment. It provides powerful tools for serialization and deserialization of core game objects, including NBT tags, chat components, and ByteBuf, with support for working with any serializable objects.
Core Functionality:
The NBT serialization system allows describing tags with correct data types instead of using strings. This ensures proper encoding and decoding according to the formats being used.
Integration:
repositories {
exclusiveContent {
forRepository {
maven("https://api.modrinth.com/maven") {
name = "Modrinth"
}
}
filter {
includeGroup("maven.modrinth")
}
}
}
dependencies {
val kinecraftVersion = "1.6.7"
compileOnly("maven.modrinth:kinecraft:$kinecraftVersion:common")
// Fabric Loom
runtimeOnly("maven.modrinth:kinecraft:$kinecraftVersion:fabric")
include("maven.modrinth:kinecraft:$kinecraftVersion")
// NeoGradle
runtimeOnly("maven.modrinth:kinecraft:$kinecraftVersion:neoforge")
jarInJar("maven.modrinth:kinecraft:$kinecraftVersion")
}
The key class MinecraftTag handles the transformation between custom data classes and standard Minecraft tag classes.