-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
285 additions
and
133 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,5 @@ | ||
dependencies { | ||
api("com.google.inject", "guice", Versions.GUICE) | ||
|
||
compileOnlyApi("net.kyori", "adventure-api", Versions.ADVENTURE) | ||
compileOnlyApi("net.kyori", "adventure-text-minimessage", Versions.ADVENTURE) | ||
|
||
api("net.kyori", "event-api", Versions.EVENT) | ||
} | ||
api(libs.guice.core) | ||
api(libs.minimessage) | ||
api(libs.event.api) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
api/src/main/java/broccolai/tags/api/model/tag/TagDisplayInformation.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
package broccolai.tags.api.model.tag; | ||
|
||
import org.checkerframework.checker.nullness.qual.NonNull; | ||
|
||
public final class TagDisplayInformation { | ||
private final @NonNull String material; | ||
private final int customModelData; | ||
|
||
public TagDisplayInformation( | ||
@NonNull String material, | ||
int customModelData | ||
) { | ||
this.material = material; | ||
this.customModelData = customModelData; | ||
} | ||
|
||
public @NonNull String material() { | ||
return this.material; | ||
} | ||
|
||
public int customModelData() { | ||
return this.customModelData; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
import com.github.jengelman.gradle.plugins.shadow.ShadowPlugin | ||
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar | ||
import org.gradle.api.Project | ||
import org.gradle.kotlin.dsl.apply | ||
import org.gradle.kotlin.dsl.invoke | ||
import org.gradle.kotlin.dsl.withType | ||
|
||
fun Project.setupShadowJar() { | ||
apply<ShadowPlugin>() | ||
|
||
tasks { | ||
withType<ShadowJar> { | ||
|
||
dependencies { | ||
exclude(dependency("com.google.guava:")) | ||
exclude(dependency("com.google.errorprone:")) | ||
exclude(dependency("org.checkerframework:")) | ||
} | ||
|
||
relocate( | ||
rootProject.group, | ||
"com.github.benmanes.caffeine", | ||
"com.typesafe.config", | ||
"com.zaxxer.hikari", | ||
"com.google.inject", | ||
"org.antlr", | ||
"org.jdbi", | ||
"org.aopalliance", | ||
"org.spongepowered.configurate", | ||
"io.leangen.geantyref", | ||
"cloud.commandframework", | ||
"net.kyori.event", | ||
"net.kyori.coffee", | ||
"org.objectweb.asm", | ||
"org.flyway", | ||
"broccolai.corn" | ||
) | ||
|
||
archiveFileName.set(project.name + ".jar") | ||
minimize() | ||
} | ||
|
||
getByName("build") { | ||
dependsOn(withType<ShadowJar>()) | ||
} | ||
} | ||
} | ||
|
||
private fun ShadowJar.relocate(group: Any, vararg dependencies: String) { | ||
dependencies.forEach { | ||
val split = it.split('.') | ||
val name = split.last() | ||
relocate(it, "$group.dependencies.$name") | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,71 +1,22 @@ | ||
import com.github.jengelman.gradle.plugins.shadow.ShadowPlugin | ||
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar | ||
import org.gradle.kotlin.dsl.apply | ||
import org.gradle.kotlin.dsl.invoke | ||
import org.gradle.kotlin.dsl.withType | ||
|
||
plugins { | ||
id("com.github.johnrengelman.shadow") version "7.1.2" | ||
id("xyz.jpenilla.run-paper") version "2.0.0" | ||
} | ||
|
||
apply<ShadowPlugin>() | ||
|
||
tasks { | ||
withType<ShadowJar> { | ||
|
||
dependencies { | ||
exclude(dependency("com.google.guava:")) | ||
exclude(dependency("com.google.errorprone:")) | ||
exclude(dependency("org.checkerframework:")) | ||
} | ||
|
||
relocate( | ||
rootProject.group, | ||
"com.github.benmanes.caffeine", | ||
"com.typesafe.config", | ||
"com.zaxxer.hikari", | ||
"com.google.inject", | ||
"org.antlr", | ||
"org.slf4j", | ||
"org.jdbi", | ||
"org.aopalliance", | ||
"org.spongepowered.configurate", | ||
"io.leangen.geantyref", | ||
"cloud.commandframework", | ||
"net.kyori.event", | ||
"net.kyori.coffee", | ||
"org.objectweb.asm", | ||
"broccolai.corn" | ||
) | ||
|
||
archiveFileName.set(project.name + ".jar") | ||
} | ||
|
||
getByName("build") { | ||
dependsOn(withType<ShadowJar>()) | ||
} | ||
|
||
runServer { | ||
minecraftVersion("1.19.2") | ||
} | ||
id("xyz.jpenilla.run-paper") version "2.2.0" | ||
} | ||
|
||
fun ShadowJar.relocate(group: Any, vararg dependencies: String) { | ||
dependencies.forEach { | ||
val split = it.split('.') | ||
val name = split.last() | ||
relocate(it, "$group.dependencies.$name") | ||
} | ||
} | ||
setupShadowJar() | ||
|
||
dependencies { | ||
api(project(":tags-core")) | ||
|
||
compileOnly("io.papermc.paper", "paper-api", Versions.SPIGOT) | ||
compileOnly("me.clip", "placeholderapi", Versions.PAPI) | ||
compileOnly("com.github.MilkBowl", "VaultAPI", Versions.VAULT) | ||
compileOnly(libs.paper.api) | ||
compileOnly(libs.papi) | ||
compileOnly(libs.vault) | ||
|
||
api("cloud.commandframework", "cloud-paper", Versions.CLOUD) | ||
api("cloud.commandframework", "cloud-minecraft-extras", Versions.CLOUD) | ||
api(libs.cloud.paper) | ||
api(libs.cloud.extras) | ||
} | ||
|
||
tasks { | ||
runServer { | ||
minecraftVersion("1.20") | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,21 @@ | ||
dependencies { | ||
api(project(":tags-api")) | ||
compileOnlyApi("com.google.guava", "guava", Versions.GUAVA) | ||
compileOnly("net.luckperms", "api", Versions.LUCKPERMS) | ||
compileOnlyApi(libs.guava) | ||
compileOnly(libs.luckperms) | ||
|
||
implementation("com.google.inject.extensions", "guice-assistedinject", Versions.GUICE) { | ||
implementation(libs.guice.assisted) { | ||
isTransitive = false | ||
} | ||
|
||
api("org.jdbi", "jdbi3-core", Versions.JDBI) | ||
implementation("com.zaxxer", "HikariCP", Versions.HIKARI) | ||
implementation("org.flywaydb", "flyway-core", Versions.FLYWAY) | ||
api(libs.jdbi.core) | ||
implementation(libs.hikari) | ||
implementation(libs.flyway) | ||
|
||
implementation("org.spongepowered", "configurate-hocon", Versions.CONFIGURATE) | ||
implementation(libs.configurate) | ||
|
||
api("broccolai.corn", "corn-core", Versions.CORN) | ||
api(libs.corn.misc) | ||
|
||
api("cloud.commandframework", "cloud-core", Versions.CLOUD) | ||
api("net.kyori", "coffee-functional", Versions.COFFEE) | ||
|
||
api("net.kyori", "event-method-asm", Versions.EVENT) | ||
|
||
implementation( "com.h2database", "h2", "2.1.214") | ||
} | ||
api(libs.cloud.core) | ||
api(libs.event.asm) | ||
api(libs.coffee) | ||
} |
Oops, something went wrong.