Posted October 2, 20223 yr How to check that Creative Mode is off or on in this version? public class ArmorHudOverlay { private static final ResourceLocation EMPTY_ARMOR = new ResourceLocation(HardLife.MODID, "textures/armor/empty_armor.png"); public static final IGuiOverlay HUD_ARMOR = ((gui, poseStack, partialTick, width, height) -> { int x = width / 2; int y = height; RenderSystem.setShader(GameRenderer::getPositionTexShader); RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); RenderSystem.setShaderTexture(0, EMPTY_ARMOR); for (int i = 0; i < 10; i++) { GuiComponent.blit(poseStack, x - 91 + (i * 8), y - 39, 0, 0, 9, 9, 9, 9); } }); } I need to do that only if CreativeMode == false, but I can't find how to do that in 1.19.2
October 2, 20223 yr Minecraft.getInstance().player.isCreative() Although depending upon what you are doing, you might want to use cameraEntity instead of player (for if the user is spectating another player)? Boilerplate: If you don't post your logs/debug.log we can't help you. For curseforge you need to enable the forge debug.log in its minecraft settings. You should also post your crash report if you have one. If there is no error in the log file and you don't have a crash report then post the launcher_log.txt from the minecraft folder. Again for curseforge this will be in your curseforge/minecraft/Install Large files should be posted to a file sharing site like https://gist.github.com You should also read the support forum sticky post.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.