Posted May 19, 20205 yr What I have: @SubscribeEvent public static void onRenderCrosshair(RenderGameOverlayEvent.Pre event) { if (event.getType() == RenderGameOverlayEvent.ElementType.CROSSHAIRS) { event.setCanceled(true); int screenHeight = event.getWindow().getScaledHeight(); int screenWidth = event.getWindow().getScaledWidth(); minecraft.getTextureManager().bindTexture(REC); Tessellator tessellator = Tessellator.getInstance(); BufferBuilder bufferbuilder = tessellator.getBuffer(); bufferbuilder.begin(7, DefaultVertexFormats.POSITION_TEX); bufferbuilder.pos(screenWidth / 2.0D - 1, screenHeight / 2.0D, -90.0D).tex(0.0F, 1.0F).endVertex(); bufferbuilder.pos(screenWidth / 2.0D - 1, screenHeight / - 5, -90.0D).tex(0.0F, 0.0F).endVertex(); bufferbuilder.pos(screenWidth / 2.0D + 30, screenHeight /, -90.0D).tex(1.0F, 1.0F).endVertex(); bufferbuilder.pos(screenWidth / 2.0D + 30, screenHeight / - 5, -90.0D).tex(1.0F, 0.0F).endVertex(); tessellator.draw(); } } What it shows: Any ideas? (the texture is a pure green 16x16 png file)
May 19, 20205 yr 4 hours ago, poopoodice said: screenWidth / 2.0D + 30, screenHeight /, -90.0D Looks like there's a typo there
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.