-
-
Save izzyaxel/28c217e9469ed8cf9697 to your computer and use it in GitHub Desktop.
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
public class IrisRender extends ModelBiped implements IItemRenderer | |
{ | |
IModelCustom CrownOfIris; | |
ResourceLocation CrownTexture; | |
int time; | |
public IrisRender() | |
{ | |
super(); | |
this.CrownOfIris = AdvancedModelLoader.loadModel(new ResourceLocation(AAReference.MODID, "models/CrownOfIris.obj")); | |
this.CrownTexture = new ResourceLocation(AAReference.MODID, ":textures/models/armor/crownOfIris.png"); | |
this.time = 0; | |
} | |
@Override | |
public void render(Entity entity, float time, float armsLegs, float headAngleY, float headAngleX, float p_78088_6_, float p_78088_7_) | |
{ | |
if(entity instanceof EntityPlayer) | |
{ | |
if(this.time == 360) | |
{ | |
this.time = 0; | |
} | |
++this.time; | |
float sineMotionY = (float) (0.1 * Math.sin(this.time * 0.5)); | |
GL11.glPushMatrix(); | |
//GL11.glRotatef(time, 0.0f, 1.0f, 0.0f); | |
GL11.glTranslatef(0.0f, 0.5f, 0.0f); | |
this.CrownOfIris.renderAll(); | |
GL11.glPopMatrix(); | |
} | |
} | |
@Override | |
public boolean shouldUseRenderHelper(ItemRenderType type, ItemStack item, ItemRendererHelper helper) | |
{ | |
return false; | |
} | |
@Override | |
public boolean handleRenderType(ItemStack item, ItemRenderType type) | |
{ | |
return false; | |
} | |
@Override | |
public void renderItem(ItemRenderType type, ItemStack item, Object... data) | |
{ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment