Team specific hat skins?

  • If you're asking a question make sure to set the thread type to be a question!

honeymustard

L9: Fashionable Member
Oct 26, 2009
698
573
I've made a hat for the scout, but I'm having trouble getting different skins for each team. I copied the qc settings from the batter's helmet, but I end up with this:

16lw9bp.jpg


As you can see, it blends the two skins, rather than choosing a specific one based on the team. Any idea how to do this properly?
 
Last edited:

YM

LVL100 YM
aa
Dec 5, 2007
7,135
6,056
$texturegroup skinfamilies
{
{ "models/weapons/w_medigun/w_medigun01.vmt" }
{ "w_medigun01_Blue.vmt" }
}
$hboxset "default"

in the qc


Also, next time dont waste one and a half million pixels to show us a hat that only uses 1,000
 

honeymustard

L9: Fashionable Member
Oct 26, 2009
698
573
$texturegroup skinfamilies
{
{ "models/player/items/scout/catchers_helmet_red.vmt" }
{ "catchers_helmet_blue.vmt" }
}
$hboxset "default"

That's in the qc file. So it must be something else.

Sorry about that large image. Fortunately the forum resizes them, so it really isn't a problem for anyone without a 56k modem.

edit: do you have to apply both textures when working in 3Ds Max? Or just the one? Because I only applied the red texture.
 
Last edited:

YM

LVL100 YM
aa
Dec 5, 2007
7,135
6,056
no thats what the QC is for, it finds the texture you've applied (hopefully catchers_helmet_red) and will replace it with the second line in the second skin.

The problem with the picture isn't that its huge, its the fact the subject is tiny, it's smaller than your avatar, how am I supposed to see what is going on?
I can't tell what is happening and do not know what kind of "blend" its doing.
 

Nutomic

L11: Posh Member
Feb 7, 2009
888
177
Sorry about that large image. Fortunately the forum resizes them, so it really isn't a problem for anyone without a 56k modem.

Yeah it resizes them, which means everyone still has to download the whole image, it is just displayed smaller.
 

honeymustard

L9: Fashionable Member
Oct 26, 2009
698
573
no thats what the QC is for, it finds the texture you've applied (hopefully catchers_helmet_red) and will replace it with the second line in the second skin.

The problem with the picture isn't that its huge, its the fact the subject is tiny, it's smaller than your avatar, how am I supposed to see what is going on?
I can't tell what is happening and do not know what kind of "blend" its doing.

Just enlarge it ;) It's not like it's a big file. Anyway I will double check what's applied in Max. I definitely only applied the red texture, though, so do I have to apply both textures? Should I do multi/sub-object in Max?

edit: I changed the picture, how lovely.

1pytc6.png


There's one more picture, showing the blend a bit clearer.
 
Last edited:
Feb 18, 2009
640
629
As far as I know (Blender at least) you must assign BOTH textures as alternate textures.

EDIT: I think what's happening to your model is that the model is rendering the RED skin but the QC (rather the MDL from the compile, using information from the QC) is trying to render the BLUE texture. Hence z-fighting. Assign both textures and it should work.
 
Last edited:

YM

LVL100 YM
aa
Dec 5, 2007
7,135
6,056
Well I made all the models in the original swamp pack with loads of skins and I never did anything of the sort.

Only ever applied one texture then simply used the QC code I gave to get the other skins.

=/
 

Acumen

Annoyer
aa
Jun 11, 2009
704
628
no, you don't two textures applied. that can't be the issue.
you don't accidentally happen to have the model duplicated, do you ;)
how does it work in the model viewer ?
can you swap between the 2 skins without problems ?
can you show the entire qc file in here, please ?

what if you write this instead of your qc-content (the part about your skinfamilies) - since the folder is already stated above:

$texturegroup skinfamilies
{
{ "soldier_viking.vmt" }
{ "soldier_viking_blue.vmt" }
}

maybe that link helps ?
http://developer.valvesoftware.com/wiki/Multiple_Skins_for_a_Single_Model
 
Last edited:

honeymustard

L9: Fashionable Member
Oct 26, 2009
698
573
The model isn't duplicated - that had me worried though, lol.
When I load the model in the model viewer, it crashes, saying there was an error loading the model.
Will try changing the vmt's.
 

Acumen

Annoyer
aa
Jun 11, 2009
704
628
also don't forget to post the entire qc in here, not just the texture part.
could be within the qc file or some model export/import problem still :)
 

honeymustard

L9: Fashionable Member
Oct 26, 2009
698
573
Ok, I tried with the soldier skins, and it shows up one skin in game, without the blending. But when I switch teams, it doesn't switch skins. And when I load it in the model viewer, it comes up blank (but doesn't crash). Weird.

edit: here's the QC:

$cd "C:\Users\Mark\Documents\Hat\"
$modelname "player\items\scout\scout_domination.mdl"
$model "Body" "catchers_helmet.smd"
$cdmaterials "\models\player\items\scout\"
$cdmaterials ""
$texturegroup skinfamilies
{
{ "catchers_helmet.vmt" }
{ "catchers_helmet_blue.vmt" }
}
$hboxset "default"
$hbox 0 "bip_head" -4.316 -8.881 -8.195 4.525 0.000 4.860
// Model uses material "models/player/items/scout/catchers_helmet.vmt"
// Model uses material "catchers_helmet_blue.vmt"
$surfaceprop "plastic"
$illumposition 0.728 0.353 77.731
$sequence idle "idle.smd" loop fps 30.00


also to be clear, I've always used catchers_helmet as the red skin, not catchers_helmet_red, so there's no mismatch.

edit: something I just thought of, does it matter if some UVs are overlapping or inverted? edit: nevermind, fixed those and it still doesn't work :(
 
Last edited:

honeymustard

L9: Fashionable Member
Oct 26, 2009
698
573
I've managed to narrow it down to a problem with the vtf files. The vmts are fine, as they're identical to the batter/bonk helms. When I preview the vtfs in Hammer, the bottom sections are blue and blocky, so they must be corrupt somehow. I think the problem lies in vtfedit, though I haven't changed anything in the way that I import tga files and save them as vtf.

edit: I decided the cheat and use the bonk helm materials (as they are pretty much the same anyway). Now it works fine. Bleh. I blame vtfedit. Wish the Photoshop plugin would work in 64bit.
 
Last edited: