https://github.com/solid-resourcepack/binder
A gradle plugin that generates bindings for blocks and items from a resource pack.
https://github.com/solid-resourcepack/binder
generation gradle gradle-plugin gradle-plugin-kotlin minecraft minecraft-server plugin resourcepack
Last synced: 11 months ago
JSON representation
A gradle plugin that generates bindings for blocks and items from a resource pack.
- Host: GitHub
- URL: https://github.com/solid-resourcepack/binder
- Owner: solid-resourcepack
- License: apache-2.0
- Created: 2025-02-09T21:49:17.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-02-28T15:35:13.000Z (11 months ago)
- Last Synced: 2025-02-28T20:49:45.809Z (11 months ago)
- Topics: generation, gradle, gradle-plugin, gradle-plugin-kotlin, minecraft, minecraft-server, plugin, resourcepack
- Language: Kotlin
- Homepage:
- Size: 69.3 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# binder 
A gradle plugin that generates bindings for blocks and items of a specified minecraft resource pack.
This aims to create a typesafe experience through enum classes when creating everything related to resource packs
(see [example implementation](/test-plugin)).
## Setup
```kotlin
// build.gradle.kts
plugins {
id("io.github.solid-resourcepack.binder") version "VERSION"
}
sourceSets.main {
kotlin.srcDir("build/generated") //Include the destination dir
}
dependencies {
api("io.github.solid-resourcepack.binder:api:VERSION")
}
packBinder {
packPath.from(layout.projectDirectory.dir("pack-sample")) //Define paths where your resource packs are
nameDepth = 1 //How much depth of the model namespace should be included
namespaces.add("example") // Add namespaces you want to generate
dest.set(layout.buildDirectory.dir("generated")) //Set the destination dir
packageName.set("com.example.generated") //Set the package of the generated classes
className.set("PackBindings") //Set the class name of the resulting enum
}
```