Skip to content

Commit f20e98d

Browse files
committed
merged 1.20.1 changes
1 parent f303fa6 commit f20e98d

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

Diff for: src/main/java/com/solegendary/reignofnether/cursor/CursorClientEvents.java

+2
Original file line numberDiff line numberDiff line change
@@ -169,13 +169,15 @@ public static void onDrawScreen(ScreenEvent.Render evt) {
169169
RenderSystem.setShaderTexture(0, TEXTURE_CURSOR);
170170
texture = TEXTURE_CURSOR;
171171
}
172+
evt.getGuiGraphics().pose().translate(0,0,1000);
172173
evt.getGuiGraphics().blit(texture,
173174
cursorDrawX, cursorDrawY,
174175
16,
175176
16, 16,
176177
16, 16,
177178
16, 16
178179
);
180+
evt.getGuiGraphics().pose().translate(0,0,-1000);
179181

180182
// ***********************************************
181183
// Convert cursor on-screen 2d pos to world 3d pos

Diff for: src/main/java/com/solegendary/reignofnether/util/MiscUtil.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -183,8 +183,8 @@ public static Vector3d screenPosToWorldPos(Minecraft MC, int mouseX, int mouseY)
183183
// for some reason position is off by some y coord so just move it down manually
184184
return new Vector3d(
185185
MC.player.xo - XZRotated.x,
186-
MC.player.yo + y + 1.5,
187-
MC.player.zo - XZRotated.y
186+
MC.player.yo + y,
187+
MC.player.zo - XZRotated.y - 2.0f
188188
);
189189
}
190190

Diff for: src/main/java/com/solegendary/reignofnether/util/MyRenderer.java

+2
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,9 @@ public static void renderTooltip(GuiGraphics guiGraphics, List<FormattedCharSequ
383383
if (MC.screen != null && tooltipLines != null && tooltipLines.size() > 0) {
384384
if (mouseY < MC.screen.height / 2)
385385
mouseY += (tooltipLines.size() * 10);
386+
guiGraphics.pose().translate(0,0,100);
386387
guiGraphics.renderTooltip(MC.font, tooltipLines, mouseX, mouseY - (9 * (tooltipLines.size() - 1)));
388+
guiGraphics.pose().translate(0,0,-100);
387389
}
388390
}
389391
}

0 commit comments

Comments
 (0)