Bug: Using "$basealphaenvmapmask" 1 with "$ssbump" enabled completely breaks the Lightmappedgeneric shader
Describe the bug
Materials with $ssbump enabled seem to only allow using the envmapmask from the bump/normal texture. attempting to use $basealphaenvmapmask 1 to use the basetexture's alpha as the envmapmask instead results in the shader self-combusting.
In-editor, the shader seems to be directly showing world coordinates through the envmapmask:
https://github.com/StrataSource/Engine/assets/33504404/f51d87ec-487a-4916-a755-a6cd45121822
(The one on the right is a functional copy of the material without envmaps)
In-game, the shader seems to completely break down and draws nothing to the screen depending on the visleaf you are in:
https://github.com/StrataSource/Engine/assets/33504404/740206e3-9562-4cdd-aa3f-86c113a7f93b
(Once again, one of the slabs is a functional copy of the material for demonstration purposes)
To Reproduce
- Install example materials into custom folder
- Open provided VMF in hammer, or open provided .bsp in-engine
- Observe the visual effects listed above
Issue Map
EXAMPLE MAP (.vmf + .bsp) texturebugmap.zip
EXAMPLE MATERIALS (should be installed when trying to view the .vmf) materialbug.zip
Expected Behavior
Ideally, materials with $ssbump and $basealphaenvmapmask should take the bump data from the bump texture, and the envmapmask from the basetexture's alpha, rather than doing whatever this is.
Operating System
Windows 11