Skip to content

Commit

Permalink
feat(api): IEnchantmentAttachableObject
Browse files Browse the repository at this point in the history
  • Loading branch information
WakelessSloth56 committed Sep 16, 2022
1 parent 91c8378 commit 81b8715
Showing 1 changed file with 18 additions and 0 deletions.
@@ -0,0 +1,18 @@
package org.auioc.mcmod.arnicalib.api.game.enchantment;

import java.util.Map;
import javax.annotation.Nullable;
import net.minecraft.world.item.enchantment.Enchantment;

public interface IEnchantmentAttachableObject {

@Nullable
default Map<Enchantment, Integer> getEnchantments() {
return null;
}

default void addEnchantment(Enchantment ench, int lvl) {
throw new UnsupportedOperationException("Adding enchantment is not supported by default");
}

}

0 comments on commit 81b8715

Please sign in to comment.