MehVahdJukaar / polytone

Other
46 stars 5 forks source link

1.21 Sheep Wool Transparent #92

Open S33R-OF-PYR3 opened 2 months ago

S33R-OF-PYR3 commented 2 months ago

Someone using this pack of mine reported sheep always looking sheared for all wool colors including white. This person used version 1.21.1 Fabric with Polytone. Testing the resource pack in Optifine had no visual bug.

Someone else suggested there was added alpha support for some colors in 1.21, and not defining those values in my resource pack's color.properties file resulted in the wool being transparent when used with Polytone, however I couldn't find any documentation of this change in Mojang's 1.21 update summary.

MehVahdJukaar commented 2 months ago

do those colors ARGB integer values have an alpha channel that is not 0?

n0proxy commented 2 months ago

I'm having this issue - and the colors listed in the color.properties file are hex values, not ARGB values, as that's what Optifine requires there.

For example, the red sheep color in the color.properties of this pack is listed as 8e3536. The equivalent ARGB with 0 alpha would be ff8e3536 (adding 'ff' to the beginning turns it into ARGB with 0 alpha), and using that number does seem to make red sheep wool not invisible. But it DOESN'T use the stated color, it seems to just use the default color.

But having to list all colors in color.properties as ARGB values for Polytone essentially makes any pack using the color.properties file NOT compatible with both Polytone and Optifine (as Optifine asks for hex values here).

S33R-OF-PYR3 commented 2 months ago

do those colors ARGB integer values have an alpha channel that is not 0?

They're hex, and changing them to ARGB values causes them to use the default sheep color in Optifine 1.21, so it seems like Optifine does not support alpha channels for those colors. n0proxy's tests confirms this is the same case in Polytone, however they also confirmed it is an issue with Polytone's color.properties as putting in an invalid color (ARGB instead of hex) causes it to default to vanilla color and fix the wool being invisible.

MehVahdJukaar commented 2 months ago

So using something like 0xff6655ff does not work?

n0proxy commented 2 months ago

0xff6655ff causes the sheep wool to be visible (good) but it also causes Minecraft/Polytone to use the default dye color, not the value specified. Which makes me think it's an entirely invalid color value, hence the reverting to default.

For example - I set the BLUE sheep/collar/dye line in color.properties to 0xff8e3536 (ff8e3536 being a red ARGB value with 0 alpha, which is 8e3536 in the hex format that Optifine says color.properties requires), and I see blue-dyed sheep looking wooly and blue. Not a reddish 8e3536 as specified in color.properties.

So far I haven't found ANY color format that Polytone will process correctly in color.properties as of 1.21. Optifine works with hex in color.properties, so ideally for compatibility with Optifine-intended packs Polytone should also work with hex values there.

MehVahdJukaar commented 1 month ago

so i think i force set all those colors to have alpha of 1 regardless of what one has set