Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/1.19' into 1.19
Browse files Browse the repository at this point in the history
  • Loading branch information
Thelnfamous1 committed Feb 10, 2024
2 parents 075049f + 036e344 commit 698ae81
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ public void deserializeNBT(CompoundTag nbt) {

public static void attach(final AttachCapabilitiesEvent<ItemStack> event) {
final AttacherBuiltInEnchantments.BuiltInEnchantmentsProvider provider = new AttacherBuiltInEnchantments.BuiltInEnchantmentsProvider(event.getObject());
event.addCapability(AttacherBuiltInEnchantments.BuiltInEnchantmentsProvider.IDENTIFIER, provider);

if ( event.getObject().isEnchantable() && event.getObject().getMaxStackSize() == 1 ) {
event.addCapability(AttacherBuiltInEnchantments.BuiltInEnchantmentsProvider.IDENTIFIER, provider);
}
}
}

0 comments on commit 698ae81

Please sign in to comment.