Im new to modding and java and i cant find anything about this problem so if someone can help that would be nice
private void renderinputerror(PoseStack pPoseStack){
int x = (width - imageWidth) / 2;
int y = (height - imageHeight) / 2;
boolean inputinslot = getMenu().blockEntity.itemHandler.getStackInSlot(1).getCount() > 0 || getMenu().blockEntity.itemHandler.getStackInSlot(3).getCount() > 0;
int bgcolor = new Color(198, 198, 198).getRGB();
if(inputinslot){
fill(pPoseStack,x + 9,y + 16,x + 49,y + 31, bgcolor);
}
}