Skip to content

Commit 58a8a4e

Browse files
committed
Fix UI text no longer renders over everything:
- Fix UI text no longer renders over everything without having to enter Play mode Suggested by ScruffyRuffles
1 parent 0295ea5 commit 58a8a4e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Assets/Hai/LightboxViewer/Scripts/Editor/LightboxViewerEditorWindow.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -287,6 +287,11 @@ private void Enable()
287287
ProjectRenderQueue.LoadLightbox(lightboxScene);
288288
_enabled = true;
289289
Realign();
290+
291+
// Fix UI text rendering over everything.
292+
// This normally fixes itself when entering Play mode, but this will allow not needing to enter Play mode.
293+
var LessEqual = 4;
294+
Shader.SetGlobalInt("unity_GUIZTestMode", LessEqual);
290295
}
291296

292297
private void Realign()

0 commit comments

Comments
 (0)