mirror of
https://github.com/alexcrea/CustomAnvil.git
synced 2026-08-28 08:25:56 +02:00
expose more enchantment function to API & use them
Some checks are pending
Java CI with Gradle / build (push) Waiting to run
Some checks are pending
Java CI with Gradle / build (push) Waiting to run
This commit is contained in:
parent
72a7860d93
commit
1e2acb6f48
6 changed files with 107 additions and 72 deletions
|
|
@ -13,6 +13,7 @@ import org.bukkit.inventory.meta.Repairable;
|
|||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.junit.jupiter.api.Assertions;
|
||||
import xyz.alexcrea.cuanvil.api.EnchantmentApi;
|
||||
import xyz.alexcrea.cuanvil.data.AnvilClickTestData;
|
||||
import xyz.alexcrea.cuanvil.data.AnvilFuseTestData;
|
||||
import xyz.alexcrea.cuanvil.enchant.CAEnchantment;
|
||||
|
|
@ -47,7 +48,7 @@ public class AnvilFuseTestUtil {
|
|||
}
|
||||
|
||||
ItemStack item = new ItemStack(material);
|
||||
ItemUtil.INSTANCE.setEnchantmentsUnsafe(item, enchantmentMap);
|
||||
EnchantmentApi.setEnchantments(item, enchantmentMap);
|
||||
|
||||
ItemMeta meta = item.getItemMeta();
|
||||
((Repairable) meta).setRepairCost(repairCost);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue