Hello, I am a staff member on an equestrian (horse) server on version 1.12.2.
We have our own custom texture pack with our custom horse textures. Although, with vanilla Minecraft, we can only have a certain amount of textures and patterns.
We are looking to expand the amount of textures for horses we can have using Optifine. We do not want to use the renaming method as players can custom name their horses as part of our custom plugins.
We were looking to use the health factor as a way to allow dozens of different horse textures to be used. This worked to an extent, although we have run into an issue:
Even though each texture is inputed the same, it seems that some textures work based on health and some don't at completely random. Does anyone know a fix to this? Or a better factor to use that is not renaming or biomes? Thanks!
Interesting. I'm honestly surprised it works at all. When last I checked the creator of Optifine had deemed the vanilla random horse system too troublesome to hook into at all and so just made it so that Random Entities didn't work with horses at all.
Moreover, Random Entities on servers has always had certain problems. I suppose keying it off of a horse's health is about as good as you can possibly get since normally Optifine re-randomizes mobs for every individual client upon loading the world. Your server won't save Optifine's variant data, after all, so Optifine has to re-roll it. But if they're all keyed off of a completely unique circumstance then that could theoretically function as long as there's no overlap.
More than likely what you're experiencing is a bug one way or the other. If so there's not much that can be done about it. But assuming that's not the case, it might be necessary to go through by trial and error and try to find a pattern about what's functioning. If any texture works predictably and continuously then there IS a pattern, just not one that's evident to you. However without examining and extensively working through the issue, I wouldn't even have the slightest clue how to solve this one.
I guess what I'm saying is that I don't have a solution but I admire your problem. Or, rather, I admire that you managed to get it functioning at all and would love to see you get it all working. I'm just not entirely sure what to contribute beyond the little information that I have.
We actually know it works- as we know another server who has managed to do it, but not with health. But they've hid it behind format code.
Well now you've got me wondering how anyone can successfully obfuscate something, anything, in a Resource Pack!
Regardless, if they're using a different method it doesn't preclude the idea that what you're experiencing is just an Optifine bug.
Run an experiment. What happens when you remove all of the textures that aren't working properly. Do they remain working if they're put in a different position in the variant ordering, or do they stop working just by being in a different number position? How about if you substitute them for different conditions? Does re-ordering the conditions in the .properties file affect anything?
The more information you can give, the clearer the picture will be about what the cause could be. It might be a long and arduous process, but if there are any consistencies that show up, any pattern that can be discerned, it's possible to find a solution.
Or at least pull together enough information to file a really in-depth bug report. One or the other.