v1.3.0 - Sonic Breaks
We have sonic breaking his own speed limit with this release!
Severe performance improvements this release
Improved - Performance
- MenuLayoutBuilderImpl row() reworked; much faster
- BaseMenu has a fixed "addItem" method; instead of doing it the way triumph-gui (my base, thanks bro), instead there's a while loop that increments the slot when the integer exists, much faster than looping through every slot.
- Internalize menu item action clicking; removing 1 need for the getClickAction getter.
- recreateItems reworked; now it's a simple for each, also removed unnecessary checks, significantly improving update() and even open()
- Instead of naturally looping through Lists (iterator()), we manually use listIterator() which is a better, faster alternative to iterator(), improving any case of updating (updateTitle, update)
- Inline most methods in MenuIterator (not significant but oh well)
- when executing ItemEditor#editor, the raw field of "itemStack" is used instead of getItemStack().
- Much more.
Improved - Generic
- Error handling improved; generic fixes can be found in some confusing errors
- MenuIterator#nextNotNull does a better job at going through not null values
I know, wow, I literally had to separate "Improved" to modules.
Fixed
- While testing, Actions and Modifiers wouldn't work because the listener wasn't properly registered.
This fix requires you to use "Menus.init(Plugin)" at onEnable() - Fix addItem
Added
- New Result API, non-close-able menus now exist.