Dynamic Trees

Dynamic Trees

25M Downloads

ArithmeticException in TextureUtils

kierajreed opened this issue ยท 2 comments

commented

This crash happens if a texture is processed where no pixel has an alpha value greater than or equal to 128. This causes count to never be incremented, causing division by zero later in the method.

https://github.com/ferreusveritas/DynamicTrees/blob/3b20e6bffaab2ff251bea0d85212e17ffac13ded/src/main/java/com/ferreusveritas/dynamictrees/client/TextureUtils.java#L174-L196

commented

Fixed as mentioned in #345.

commented

Hi, I can confirm this crash.
I'm using some older textures for BOP (from Minecraft 1.7.2 Resource Pack) in my current installation (MC 1.12.2) and it crashes on start.

Not sure if something is not correct with the old PNG files... Will have a check on them.