Apply RoofOverlay per-grid not per-map + fix lighting quality (#35207)

* Apply RoofOverlay per-grid not per-map

* Fix light render scales
This commit is contained in:
metalgearsloth
2025-02-17 00:29:03 +11:00
committed by GitHub
parent a9f900c397
commit ead32b5770
4 changed files with 71 additions and 42 deletions

View File

@@ -33,7 +33,8 @@ public sealed class AfterLightTargetOverlay : Overlay
var bounds = args.WorldBounds;
// at 1-1 render scale it's mostly fine but at 4x4 it's way too fkn big
var newScale = viewport.RenderScale / 2f;
var lightScale = viewport.LightRenderTarget.Size / (Vector2) viewport.Size;
var newScale = viewport.RenderScale / (Vector2.One / lightScale);
var localMatrix =
viewport.LightRenderTarget.GetWorldToLocalMatrix(viewport.Eye, newScale);