mirror of
https://github.com/refactorinqq/SLC-1.8.9.git
synced 2024-11-10 07:01:32 +01:00
Always Render Nametag
This commit is contained in:
parent
eb960ab990
commit
cfa86cd8ce
@ -71,18 +71,23 @@ public class RendererLivingEntityMixin<T extends EntityLivingBase> {
|
||||
event.call();
|
||||
if(event.isCancelable()) {
|
||||
ci.cancel();
|
||||
return;
|
||||
}
|
||||
|
||||
final float entityDistance = entity.getDistanceToEntity(Minecraft.getMinecraft().thePlayer);
|
||||
if (EntityCulling.shouldPerformCulling) {
|
||||
if (entity instanceof IMob && entityDistance > Client.getInstance().getSettingsManager().getSettingByClass(FPSBoostMod.class, "Hostile Entity Render Distance").getValInt()) {
|
||||
ci.cancel();
|
||||
return;
|
||||
} else if ((entity instanceof EntityAnimal || entity instanceof EntityAmbientCreature || entity instanceof EntityWaterMob) && entityDistance > Client.getInstance().getSettingsManager().getSettingByClass(FPSBoostMod.class, "Passive Entity Render Distance").getValInt()) {
|
||||
ci.cancel();
|
||||
return;
|
||||
} else if (entity instanceof EntityPlayer && entityDistance > Client.getInstance().getSettingsManager().getSettingByClass(FPSBoostMod.class, "Player Render Distance").getValInt()) {
|
||||
ci.cancel();
|
||||
return;
|
||||
} else if (entityDistance > Client.getInstance().getSettingsManager().getSettingByClass(FPSBoostMod.class, "Misc. Entity Render Distance").getValInt()) {
|
||||
ci.cancel();
|
||||
return;
|
||||
}
|
||||
}
|
||||
if(entity instanceof EntityArmorStand && Client.getInstance().getSettingsManager().getSettingByClass(FPSBoostMod.class, "Hide Armor Stands").getValBoolean()) {
|
||||
|
@ -1,18 +1,5 @@
|
||||
package net.silentclient.client.utils.culling;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
import net.silentclient.client.mixin.accessors.RenderManagerAccessor;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.opengl.GL15;
|
||||
import org.lwjgl.opengl.GL33;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.entity.EntityPlayerSP;
|
||||
import net.minecraft.client.multiplayer.WorldClient;
|
||||
@ -33,7 +20,15 @@ import net.silentclient.client.event.EventTarget;
|
||||
import net.silentclient.client.event.impl.ClientTickEvent;
|
||||
import net.silentclient.client.event.impl.RenderLivingEvent;
|
||||
import net.silentclient.client.event.impl.RenderTickEvent;
|
||||
import net.silentclient.client.mixin.accessors.RenderManagerAccessor;
|
||||
import net.silentclient.client.mods.settings.FPSBoostMod;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.opengl.GL15;
|
||||
import org.lwjgl.opengl.GL33;
|
||||
|
||||
import java.util.*;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
public class EntityCulling {
|
||||
private static final Minecraft mc = Minecraft.getMinecraft();
|
||||
@ -191,22 +186,19 @@ public class EntityCulling {
|
||||
return;
|
||||
}
|
||||
|
||||
if (entity instanceof EntityPlayer) {
|
||||
//#if MC==10809
|
||||
double x = event.x;
|
||||
double y = event.y;
|
||||
double z = event.z;
|
||||
RendererLivingEntity<EntityLivingBase> renderer = event.getRenderer();
|
||||
//#else
|
||||
//$$ double x = event.getX();
|
||||
//$$ double y = event.getY();
|
||||
//$$ double z = event.getZ();
|
||||
//$$ RenderLivingBase<EntityLivingBase> renderer = event.getRenderer();
|
||||
//#endif
|
||||
|
||||
//#if MC==10809
|
||||
double x = event.x;
|
||||
double y = event.y;
|
||||
double z = event.z;
|
||||
RendererLivingEntity<EntityLivingBase> renderer = event.getRenderer();
|
||||
//#else
|
||||
//$$ double x = event.getX();
|
||||
//$$ double y = event.getY();
|
||||
//$$ double z = event.getZ();
|
||||
//$$ RenderLivingBase<EntityLivingBase> renderer = event.getRenderer();
|
||||
//#endif
|
||||
|
||||
renderer.renderName(entity, x, y, z);
|
||||
}
|
||||
renderer.renderName(entity, x, y, z);
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user