-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix xaero's minimap player entity dot rendering when it shouldn't
- Loading branch information
Showing
5 changed files
with
45 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
src/main/java/com/mitchej123/hodgepodge/mixins/late/xaerominimap/MixinMinimapRenderer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package com.mitchej123.hodgepodge.mixins.late.xaerominimap; | ||
|
||
import net.minecraft.entity.Entity; | ||
import net.minecraft.entity.player.EntityPlayer; | ||
|
||
import org.spongepowered.asm.mixin.Mixin; | ||
import org.spongepowered.asm.mixin.injection.At; | ||
|
||
import com.llamalad7.mixinextras.injector.v2.WrapWithCondition; | ||
|
||
import xaero.common.minimap.MinimapProcessor; | ||
import xaero.common.minimap.MinimapRadar; | ||
import xaero.common.minimap.render.MinimapFBORenderer; | ||
import xaero.common.minimap.render.MinimapRenderer; | ||
import xaero.common.settings.ModSettings; | ||
|
||
@Mixin(value = MinimapRenderer.class, remap = false) | ||
public abstract class MixinMinimapRenderer { | ||
|
||
@WrapWithCondition( | ||
method = "renderMinimap", | ||
at = @At( | ||
value = "INVOKE", | ||
target = "Lxaero/common/minimap/render/MinimapFBORenderer;renderMainEntityDot(Lxaero/common/minimap/MinimapProcessor;Lnet/minecraft/entity/player/EntityPlayer;Lnet/minecraft/entity/Entity;DDDDFLxaero/common/minimap/MinimapRadar;ZIZZZDLxaero/common/settings/ModSettings;)V")) | ||
private boolean hodgepodge$fixPlayerDotRenderCheck(MinimapFBORenderer instance, MinimapProcessor minimap, | ||
EntityPlayer p, Entity renderEntity, double ps, double pc, double playerX, double playerZ, float partial, | ||
MinimapRadar minimapRadar, boolean lockedNorth, int style, boolean smooth, boolean debug, boolean cave, | ||
double dotNameScale, ModSettings settings) { | ||
return !lockedNorth && settings.mainEntityAs == 1; | ||
} | ||
} |