Skip to content

1.0.1 (1.20.2) - Optimisation Rewrite!

Choose a tag to compare

@axialeaa axialeaa released this 01 Nov 21:40
· 7 commits to master since this release

This release doesn't obviously change anything about how these blocks behave, but the code has been drastically improved in almost every way.

  • The blocks now copy the behaviours of the vanilla (non-hollow) counterparts, reducing the amount of custom logic. This will make it easier to add hollow counterparts to logs from other mods or vanilla updates in the future. Consequently, hollow logs now share the mining speed of their non-hollow counterparts instead of being insta-mineable.
  • The collision, outline and raycast geometry logic has been totally rewritten which is now far simpler and faster to run. Instead of, for each possible orientation of the block, stitching 4 sides together from a list of possible 6, it calculates the dimensions of the hole in each orientation and subtracts them from the fullCube() shape.
  • The biomes the hollow log decorations can place in are now hardcoded. This sounds like a bad thing, but it totally removes the need for a built-in datapack and should now be compatible with datapacks that modify biome .json files.
  • Improved general code readability, by renaming certain methods and classes, adding comments and indents, and separating if expressions from their returns.

Enjoy! :D