public static void drawRect(PoseStack matrices, float x, float y, float width, float height, Color c) {
Tesselator tesselator = Tesselator.getInstance();
BufferBuilder bufferBuilder = tesselator.begin(VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION_COLOR);
Matrix4f matrix = matrices.last().pose();
RenderSystem.setShader(GameRenderer::getPositionColorShader);
int color = c.getRGB();
bufferBuilder.addVertex(matrix, x, y + height, 0.0F).setColor((color >> 16) & 0xFF, (color >> 8) & 0xFF, color & 0xFF, (color >> 24) & 0xFF);
bufferBuilder.addVertex(matrix, x + width, y + height, 0.0F).setColor((color >> 16) & 0xFF, (color >> 8) & 0xFF, color & 0xFF, (color >> 24) & 0xFF);
bufferBuilder.addVertex(matrix, x + width, y, 0.0F).setColor((color >> 16) & 0xFF, (color >> 8) & 0xFF, color & 0xFF, (color >> 24) & 0xFF);
bufferBuilder.addVertex(matrix, x, y, 0.0F).setColor((color >> 16) & 0xFF, (color >> 8) & 0xFF, color & 0xFF, (color >> 24) & 0xFF);
tesselator.draw(bufferBuilder);
}