Skip to content

Commit

Permalink
Minor edge cases on the hud
Browse files Browse the repository at this point in the history
  • Loading branch information
Vazkii committed Oct 2, 2023
1 parent 258568d commit 901747e
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -173,14 +173,14 @@ public static BlockState modifyBlockPlacementState(BlockState state, BlockPlaceC
@SubscribeEvent
@OnlyIn(Dist.CLIENT)
public void onRender(RenderGuiOverlayEvent.Pre event) {
if(event.getOverlay() == VanillaGuiOverlay.CROSSHAIR.type())
if(event.getOverlay() != VanillaGuiOverlay.CROSSHAIR.type())
return;

Minecraft mc = Minecraft.getInstance();
Player player = mc.player;
String savedVariant = getSavedVariant(player);

if(savedVariant != null && !savedVariant.isEmpty()) {
if(savedVariant != null) {
ItemStack mainHand = player.getMainHandItem();
ItemStack displayLeft = mainHand.copy();

Expand Down

0 comments on commit 901747e

Please sign in to comment.