fix syncedkeybind update

This commit is contained in:
Caedis committed 2025-07-15 12:01:07 -05:00
1 parent e7086a3472
commit 73a4fda220
2 files changed
+3 -2

No files matched your search

+1 -1
View File
@@ -1,7 +1,7 @@
// Add your dependencies here
dependencies {
api("com.github.GTNewHorizons:GTNHLib:0.6.31:dev")
api("com.github.GTNewHorizons:GTNHLib:0.6.38:dev")
implementation("com.github.GTNewHorizons:NotEnoughItems:2.7.56-GTNH:dev")
testImplementation(platform('org.junit:junit-bom:5.9.2'))
@@ -113,7 +113,8 @@ public class CommonProxy {
private static final SyncedKeybind MODE_SWAP_KEY = SyncedKeybind.createConfigurable(
"item.structurelib.constructableTrigger.keys.cycleMode",
"item.structurelib.constructableTrigger.keyCategory",
0).registerGlobalListener((entityPlayerMP, syncedKeybind) -> {
0).registerGlobalListener((entityPlayerMP, syncedKeybind, isDown) -> {
if (!isDown) return;
final ItemStack held = entityPlayerMP.getHeldItem();
if (held != null && held.getItem() instanceof ItemConstructableTrigger) {
ItemConstructableTrigger.cycleMode(held);