Unique Enchantments - Utils

Unique Enchantments - Utils

4M Downloads

[1.16.5] Compatibility Issue - Crashes checking arrow enchantment level if the AbstractArrowEntity was provided null enchantment level

Kaleidio opened this issue ยท 6 comments

commented

An mcreator mod called Not Enough Tridents used bad coding practice which resulted in any attributes of the entity they did not believe needed changed to contain nulls. However, it should be possible in your code, to add failsafes if any of your arrow attribute checks return null to work around this. Considering this is more their fault than yours I don't mind if you don't fix this, just wanted to make you aware it did happen.

Note also that it only ended up crashing after I threw the trident exactly twice, the first trident behaved normally. So I'm not 100% sure on all the details of this besides what my initial research found.

https://pastebin.com/qVKQNGRU

commented

I am sorry, but we are not going to support this mods rule breaking.
This is like one of the cardinal rules of minecraft and if we can't trust even these then nothing is trustable in code.

What I suggest is you report this to the dev directly and ask him to fix this issue.
In general, nothing against the mod creator, but using MC Creator to create logic of any form is a terrible idea.
I have seen the code it creates, and for logic of any kind its the worst tool you can use.

Now if it is only for decoration then MCCreator is fine, the code looks ugly but since there is no logic being executed in the background there is no performance problems with said mods.

(XKDeko is a great example of a good MCCreator mod in terms of performance)

commented

No problem. I cannot get in touch as the developer does not accept issue requests in a manner that is easy to reach out for. Closing issue.

commented

He has a discord server advertised in his curseforge page. Or write a comment on curseforge.

commented

Said discord and curseforge page are both extremely inactive and heavily overmoderated. This will be difficult to even get their attention, or even be allowed to talk to them. I have attempted a post and we'll see if that works.

commented

Developer has expressed they cannot fix it as they don't know enough about coding. The probable cause is because their "trident" extends an Arrow entity rather than a Trident entity which can cause many problems.

commented

Good to know.
But no this is not correct. Their implementation explicitly returns null while vanillas returns ItemStack.EMPTY