• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

A problem with a texture

Status
Not open for further replies.
Level 15
Joined
Sep 6, 2015
Messages
576
I wanted to make parts of a model texture transparent, so I edited it to be so, but when I imported the file, the texture won't show in game, only the Replaceable ID for the team color shows. I had checked the texture in game just after I had started editing, when I had only made some little parts of it transparent, and it had worked back then. Anybody know what's wrong with this? I did nothing but erased some parts to make them transparent. I've searched for the answer, but to no avail.

I found out what was bugging it and fixed it. It seems that upon the removal of the jaw the texture stops working. Pretty strange.
 
Last edited by a moderator:

Dr Super Good

Spell Reviewer
Level 63
Joined
Jan 18, 2005
Messages
27,178
Something that is transparent is invisible, the very definition of "won't show up in game".

This might be due to how the WC3 render handles blending with team colour textures. If the texel is not opaque then it performs a blend on top of the team color. If a texel is opaque then it is always shown. If a pixel is not opaque and not on top of a team colour to blend with then the result is completely transparent. Even if a pixel has opaque value of 254, then it will still be completely transparent (invisible) if not above team colour.

This means that some models do now allow transparent texture detail out of team colour areas. An example is the Blood Mage.

This will be a big problem if you are using JPEG BLP compression. This is because the alpha channel is subject to lossy compression like the BGR channels. With any decent compression this means there is a very high chance that having a transparent pixel anywhere within a block will bleed value changes into all other pixels, enough to change 255 (opaque) to 254 or less (completely transparent unless above team colour). This is why many models have team colour meshes that are considerably bigger than what can be seen.

If you want a ghostly model you probably need to alter what blending is performed. I am guessing transparent models like ghost Antanidos and ghostly keep of the grove use a different blend that does allow alpha detail everywhere.
 

Dr Super Good

Spell Reviewer
Level 63
Joined
Jan 18, 2005
Messages
27,178
No clue what you are talking about, any alpha works, it simply depends on the blend mode.
Seeing how he is using standard models he is limited to whatever blending they use. It is quite possible the Crypt Lord model uses similar blending to Blood Mage which does suffer the problem that any non-opaque pixel is only visible if above team colour.
 
Level 15
Joined
Sep 6, 2015
Messages
576
I took a look at the Keeper of the Grove ghost and Antonidas ghost. Both of them have opaque textures (not transparent), so their transparency was probably dealt with in their models' configuration. KotG has the same texture for the ghost as for the living form. Antonidas has different texture for the ghost, although they look completely the same, so maybe only that blending was changed. Another thing I noticed is that KotG ghost has the team colour texture (Replaceable ID 1), while the Antonidas ghost doesn't have it and only has the team glow (Replaceable ID 2), although the living Antonidas has the team colour texture.
The question is how to change, alter or set the blending type of any texture, either base or custom, with the image editing programs, like GIMP, or is it done differently?
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
The blending mode isn't related to the textures directly. It is a property of material layers.
If you open a material layer in Magos, you can see (and set) the blend mode at the bottom.

Either way, non of this is related to the original problem. You say that upon editing a texture (and even a specific part of a texture), it stopped working.
This is impossible.
What is possible, is that the texture isn't saved properly for some reason, and thus gets corrupted.
Can't say anything else, since you didn't mention your pipeline (programs? formats?)

Attaching your resources will probably be the fastest way to get actual help.
 
Level 15
Joined
Sep 6, 2015
Messages
576
Can't say anything else, since you didn't mention your pipeline (programs? formats?)

Attaching your resources will probably be the fastest way to get actual help.
I'm using GIMP to edit the texture in .tga format, then I convert it to .blp. For the conversion between .tga and .blp I'm using BLP <-> TGA Converter.
I already linked the resource:
That's the working version of the texture. I no longer have the one that doesn't show in-game.
 
Status
Not open for further replies.
Top