HammerAddons icon indicating copy to clipboard operation
HammerAddons copied to clipboard

Auto-packing fails to consider textures in conditional VMT statements

Open piqey opened this issue 4 months ago • 2 comments

I have a VMT that reads as follows:

"VertexLitGeneric"
{
//	$basetexture		"piqey/thebel/skybox/thebel_skybox/roof"	// This is loaded by another VMT in the project, that's why you'll see it still get packed in the compile log below
	$basetexture		"piqey/thebel/skybox/thebel_skybox/roof_lightmappable"
	$surfaceprop		"concrete"

	"ldr?$lightmap"		"piqey/thebel/skybox/thebel_skybox/roof_lightmap"
	"hdr?$lightmap"		"piqey/thebel/skybox/thebel_skybox/roof_lightmap_hdr"
}

However, as you can see from the following compile log excerpt, the $lightmaps specified by the ldr? and hdr? conditional statements were not packed by the postcompiler:

[...]
 | materials\piqey\thebel\skybox\thebel_skybox\pillars_normal.vtf
 | materials\piqey\thebel\skybox\thebel_skybox\roof.(vmt/vtf)
 | materials\piqey\thebel\skybox\thebel_skybox\roof_lightmappable.vtf
 | materials\piqey\thebel\skybox\thebel_skybox\roof_side.(vmt/vtf)
 | materials\skybox\piqey\blackbk.vmt
[...]

I could include in-game screenshots but I think that's somewhat unnecessary as it's just... not there. A missing texture. If you want it, here is the full compile log (I only ran vbsp.exe and postcompiler.exe to keep it concise).

Just a side note, I know the textures work fine. I've been using them for about a week now, and it was only today that I unmounted all my content to test the auto-packing and noticed postcompiler.exe wasn't doing its job on those particular textures.

piqey avatar Oct 23 '24 17:10 piqey