Skip to content

Commit

Permalink
Fix jetpack attachment positioning
Browse files Browse the repository at this point in the history
  • Loading branch information
NichtStudioCode committed Mar 9, 2024
1 parent a8b8d94 commit a854aaf
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package xyz.xenondevs.nova.addon.jetpacks.registry

import org.joml.Vector3f
import xyz.xenondevs.nova.addon.jetpacks.Jetpacks
import xyz.xenondevs.nova.addon.registry.AttachmentTypeRegistry
import xyz.xenondevs.nova.initialize.Init
Expand All @@ -12,7 +13,13 @@ import xyz.xenondevs.nova.player.attachment.HideDownItemAttachment
object Attachments : AttachmentTypeRegistry by Jetpacks.registry {

private fun registerJetpackAttachment(name: String, material: NovaItem): AttachmentType<*> =
registerAttachmentType(name) { HideDownItemAttachment(40f, it, material.clientsideProvider.get()) }
registerAttachmentType(name) { player ->
HideDownItemAttachment(
40f, player,
material.clientsideProvider.get(),
Vector3f(0f, -0.5f, -0.15f)
)
}

val BASIC_JETPACK = registerJetpackAttachment("basic_jetpack", Items.BASIC_JETPACK)
val ADVANCED_JETPACK = registerJetpackAttachment("advanced_jetpack", Items.ADVANCED_JETPACK)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,6 @@
"rotation": [20, 35, 0],
"translation": [0, 2.5, 0]
},
"head": {
"translation": [0, -45.25, 5.75],
"scale": [1.7, 1.7, 1.7]
},
"fixed": {
"rotation": [0, -180, 0],
"translation": [0, 2.5, 0]
Expand Down

0 comments on commit a854aaf

Please sign in to comment.