Ayfri / Kore

A Kotlin library to generate Datapacks for Minecraft Java.

Home Page:https://kore.ayfri.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[BUG] Inappropriate argument in setEnchantments item modifier builder

MushroomMif opened this issue · comments

Library version

1.0.0

What module does this bug apply to?

DSL

What happened?

I tried to use setEnchantments item modifier with its builder, but when i tried to add an enchantment to it I noticed that I cant do it. I looked at the source code and seen that in second parameter of function there is a Map instead of MutableMap and because of that it's impossible to add any enchantments.
image

How can we reproduce this issue?

  1. Create an item modifier
  2. Try to add setEnchantments item modifier to it
  3. Notice that you cant put any enchantments to the map of enchants

Extra information

No response

My issue is not duplicated

  • This is not a duplicate

This bug has been fixed on my computer, you can still create a SetEnchantments instance with the values you want as a temporary workaround until the next release.