Skip to content

Commit

Permalink
Source Engine: Fix disappearing overlays
Browse files Browse the repository at this point in the history
  • Loading branch information
magcius committed Nov 10, 2024
1 parent 8c19870 commit e6e451c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/SourceEngine/BSPFile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1820,6 +1820,9 @@ export class BSPFile {
vec3.set(overlayInfo.basis[0], vecUVPoint0Z, vecUVPoint1Z, vecUVPoint2Z);
vec3.cross(overlayInfo.basis[1], overlayInfo.normal, overlayInfo.basis[0]);

if (vecUVPoint3Z == 1.0)
vec3.negate(overlayInfo.basis[1], overlayInfo.basis[1]);

vec2.set(overlayInfo.planePoints[0], vecUVPoint0X, vecUVPoint0Y);
vec2.set(overlayInfo.planePoints[1], vecUVPoint1X, vecUVPoint1Y);
vec2.set(overlayInfo.planePoints[2], vecUVPoint2X, vecUVPoint2Y);
Expand Down

0 comments on commit e6e451c

Please sign in to comment.