For the most part you just need to enable the ALTERNATIVE_PROJECTION_MODE shader keyword.
All existing working sights already have this enabled, and the 3 problematic sights all use the Unlit/HolographicSight_3Layers shader, so we limit our modifications to materials that use it.
The Drekker and Klust look ok out of the box, but the reticle size and distance have been modified to resemble what they look like when playing in pancake.
The Arbalist, however, is completely broken out of the box, and required some more significant tweaks.
The final crosshair texture is centered, but the other two reticle textures are not, so they do not line up. The crosshair is also upside down. You cannot adjust the shader to compensate for this, so instead we make a copy of the texture., flip it, and shift it a bit to match the others. Maybe a bit overkill but this only happens once per launch so should be ok.
The what
This PR fixes the sights of a few weapons that are currently broken in VR
Gtfosights-1.webm
The how
For the most part you just need to enable the
ALTERNATIVE_PROJECTION_MODE
shader keyword. All existing working sights already have this enabled, and the 3 problematic sights all use theUnlit/HolographicSight_3Layers
shader, so we limit our modifications to materials that use it.The Drekker and Klust look ok out of the box, but the reticle size and distance have been modified to resemble what they look like when playing in pancake.
The Arbalist, however, is completely broken out of the box, and required some more significant tweaks. The final crosshair texture is centered, but the other two reticle textures are not, so they do not line up. The crosshair is also upside down. You cannot adjust the shader to compensate for this, so instead we make a copy of the texture., flip it, and shift it a bit to match the others. Maybe a bit overkill but this only happens once per launch so should be ok.