1
0
forked from Clones/Controlify

Take screenshot + pick block with nbt bindings

This commit is contained in:
isXander
2023-08-19 19:58:18 +01:00
parent f2e8fc1187
commit b38f392bd7
8 changed files with 90 additions and 6 deletions

View File

@ -241,6 +241,11 @@ public class InGameButtonGuide implements IngameGuideRegistry {
return Optional.of(Component.translatable("controlify.guide.ingame.pick_block"));
return Optional.empty();
});
registerGuideAction(controller.bindings().PICK_BLOCK_NBT, ActionLocation.RIGHT, (ctx) -> {
if (ctx.hitResult().getType() == HitResult.Type.BLOCK && ctx.player().isCreative())
return Optional.of(Component.translatable("controlify.binding.controlify.pick_block_nbt"));
return Optional.empty();
});
}
private HitResult calculateHitResult() {