Likely due to the fact that IViewRotMat is the same in gui as in the world, the fix is simple.
Change line 79 in the vertex shader from:
if (dim.x != 64 || dim.y != 64) {
To:
if (ProjMat[3][2] == -2.0 || dim.x != 64 || dim.y != 64) {
This fixed the issue on my end and doesn't appear to cause any additional bugs.
Likely due to the fact that IViewRotMat is the same in gui as in the world, the fix is simple. Change line 79 in the vertex shader from:
if (dim.x != 64 || dim.y != 64) {
To:if (ProjMat[3][2] == -2.0 || dim.x != 64 || dim.y != 64) {
This fixed the issue on my end and doesn't appear to cause any additional bugs.