mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
44 lines
1.5 KiB
Java
44 lines
1.5 KiB
Java
package com.hbm.render.entity;
|
|
|
|
import org.lwjgl.opengl.GL11;
|
|
|
|
import com.hbm.entity.missile.EntityMissileTaint;
|
|
import com.hbm.lib.RefStrings;
|
|
import com.hbm.main.ResourceManager;
|
|
|
|
import net.minecraft.client.renderer.entity.Render;
|
|
import net.minecraft.entity.Entity;
|
|
import net.minecraft.util.ResourceLocation;
|
|
import net.minecraftforge.client.model.AdvancedModelLoader;
|
|
import net.minecraftforge.client.model.IModelCustom;
|
|
|
|
public class RenderMissileTaint extends Render {
|
|
|
|
public RenderMissileTaint() {
|
|
}
|
|
|
|
@Override
|
|
public void doRender(Entity p_76986_1_, double p_76986_2_, double p_76986_4_, double p_76986_6_, float p_76986_8_, float p_76986_9_) {
|
|
|
|
GL11.glPushMatrix();
|
|
GL11.glTranslatef((float)p_76986_2_, (float)p_76986_4_, (float)p_76986_6_);
|
|
GL11.glRotatef(p_76986_1_.prevRotationYaw + (p_76986_1_.rotationYaw - p_76986_1_.prevRotationYaw) * p_76986_9_ - 90.0F, 0.0F, 1.0F, 0.0F);
|
|
GL11.glRotatef(p_76986_1_.prevRotationPitch + (p_76986_1_.rotationPitch - p_76986_1_.prevRotationPitch) * p_76986_9_, 0.0F, 0.0F, 1.0F);
|
|
GL11.glScalef(2F, 2F, 2F);
|
|
|
|
GL11.glDisable(GL11.GL_CULL_FACE);
|
|
bindTexture(getEntityTexture(p_76986_1_));
|
|
ResourceManager.missileTaint.renderAll();
|
|
GL11.glEnable(GL11.GL_CULL_FACE);
|
|
GL11.glPopMatrix();
|
|
}
|
|
|
|
@Override
|
|
protected ResourceLocation getEntityTexture(Entity p_110775_1_) {
|
|
if(p_110775_1_ instanceof EntityMissileTaint)
|
|
return ResourceManager.missileTaint_tex;
|
|
|
|
return ResourceManager.missileMicro_tex;
|
|
}
|
|
}
|