Skip to content

Commit

Permalink
fix: GUIHeadItem meta not applying (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
DebitCardz authored Jan 27, 2024
1 parent 65b2669 commit 66741ab
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ val githubActor = project.findProperty("gpr.user") as String? ?: System.getenv("
val githubToken = project.findProperty("gpr.key") as String? ?: System.getenv("GITHUB_TOKEN")

group = "me.tech"
version = "1.4.5"
version = "1.4.6"

repositories {
mavenCentral()
Expand Down
4 changes: 2 additions & 2 deletions development/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ repositories {
}

dependencies {
compileOnly("io.papermc.paper:paper-api:1.20.2-R0.1-SNAPSHOT")
compileOnly("io.papermc.paper:paper-api:1.20.4-R0.1-SNAPSHOT")
implementation(rootProject)
}

Expand All @@ -28,7 +28,7 @@ tasks.jar {
}

tasks.withType<RunServer> {
minecraftVersion("1.20.2")
minecraftVersion("1.20.4")
}

bukkit {
Expand Down
4 changes: 2 additions & 2 deletions src/main/kotlin/me/tech/mcchestui/item/GUIHeadItem.kt
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class GUIHeadItem : GUIItem(Material.PLAYER_HEAD) {
var skullOwner: OfflinePlayer?
get() = itemMeta.owningPlayer
set(value) {
stack.editMeta(SkullMeta::class.java) {
itemStack.editMeta(SkullMeta::class.java) {
it.owningPlayer = value
}
}
Expand All @@ -54,7 +54,7 @@ class GUIHeadItem : GUIItem(Material.PLAYER_HEAD) {
var playerProfile: PlayerProfile?
get() = itemMeta.playerProfile
set(value) {
stack.editMeta(SkullMeta::class.java) {
itemStack.editMeta(SkullMeta::class.java) {
it.playerProfile = value
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/main/kotlin/me/tech/mcchestui/item/GUIItem.kt
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ fun guiItem(


open class GUIItem constructor(
private val itemStack: ItemStack
protected val itemStack: ItemStack
) {
constructor(type: Material)
: this(ItemStack(type, 1))
Expand Down

0 comments on commit 66741ab

Please sign in to comment.