* Fixes#4508: Correctly construct the sparse lists.
Also renamed all uncondensed getters to sparse and all condensed to the simple ones.
* Apply suggestions from code review
Co-authored-by: shartte <shartte@users.noreply.github.com>
* Streamlined collapsing the sparse lists
* Extracted helper to condense stacks
* Sort lists desc by stack size
Co-authored-by: shartte <shartte@users.noreply.github.com>
* Deduplicate crafting patterns internals
This should save a bit memory for duplicate patterns as well as speed up
loading new patterns on reloading chunks.
* Encode recipe id in pattern
* Use the recipe id directly for looking it up
* Slightly refactored how patterns encode whether they are crafting patterns or not.
* Renamed PatternHelper.
* Added APIs to encode patterns. (#4463)
* Removed ICraftingPatternItem.
* Renamed isCrafting to isCraftable
Co-authored-by: shartte <shartte@users.noreply.github.com>