Increase Z value of GUIs
This commit is contained in:
parent
c45435a6b0
commit
fd3f22da29
@ -455,7 +455,7 @@ public abstract class MatteryScreen<T extends MatteryMenu> extends AbstractConta
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
float depth = -900f;
|
float depth = -400f;
|
||||||
|
|
||||||
for (var panel : panels) {
|
for (var panel : panels) {
|
||||||
panel.set3DDepth(depth);
|
panel.set3DDepth(depth);
|
||||||
|
@ -10,6 +10,9 @@ import javax.annotation.Nullable;
|
|||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import static org.lwjgl.opengl.GL11.GL_ALWAYS;
|
||||||
|
import static org.lwjgl.opengl.GL11.GL_LESS;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Superclass of all panels
|
* Superclass of all panels
|
||||||
* This panel represent part of GMod's Panels API
|
* This panel represent part of GMod's Panels API
|
||||||
@ -152,8 +155,21 @@ public class EditablePanel implements GuiEventListener {
|
|||||||
}
|
}
|
||||||
|
|
||||||
stack.pushPose();
|
stack.pushPose();
|
||||||
|
|
||||||
|
/*if (parent == null) {
|
||||||
|
RenderSystem.depthFunc(GL_ALWAYS);
|
||||||
|
RenderSystem.depthMask(true);
|
||||||
|
stack.translate(parent_x, parent_y, 0);
|
||||||
|
} else {*/
|
||||||
stack.translate(parent_x, parent_y, accumulated_depth);
|
stack.translate(parent_x, parent_y, accumulated_depth);
|
||||||
|
//}
|
||||||
|
|
||||||
innerRender(stack, mouse_x, mouse_y, flag);
|
innerRender(stack, mouse_x, mouse_y, flag);
|
||||||
|
|
||||||
|
/*if (parent == null) {
|
||||||
|
RenderSystem.depthFunc(GL_LESS);
|
||||||
|
}*/
|
||||||
|
|
||||||
stack.popPose();
|
stack.popPose();
|
||||||
|
|
||||||
var most_depth = accumulated_depth;
|
var most_depth = accumulated_depth;
|
||||||
|
Loading…
Reference in New Issue
Block a user