Advertisement
Guest User

Render

a guest
Jul 4th, 2015
252
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.25 KB | None | 0 0
  1. package me.yamakaja.PrCraft.Render;
  2.  
  3. import org.lwjgl.opengl.GL11;
  4.  
  5. import me.yamakaja.PrCraft.Reference;
  6. import me.yamakaja.PrCraft.TileEntitys.TileEntityIronProcessor;
  7. import net.minecraft.client.renderer.GlStateManager;
  8. import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
  9. import net.minecraft.entity.Entity;
  10. import net.minecraft.tileentity.TileEntity;
  11. import net.minecraft.util.ResourceLocation;
  12.  
  13. public class TileEntityIronProcessorRenderer extends TileEntitySpecialRenderer{
  14.  
  15. private final TileEntityIronProcessorModel ironProcessorModel;
  16.  
  17. public TileEntityIronProcessorRenderer(){
  18.  
  19. this.ironProcessorModel = new TileEntityIronProcessorModel();
  20.  
  21.  
  22. }
  23.  
  24. @Override
  25. public void renderTileEntityAt(TileEntity te, double posX, double posY, double posZ, float p_180535_8_, int p_180535_9_) {
  26.  
  27. if(te instanceof TileEntityIronProcessor){
  28.  
  29. this.bindTexture(new ResourceLocation(Reference.MOD_ID + "textures/blocks/iron_processor_texture.png"));
  30.  
  31. GL11.glPushMatrix();
  32.  
  33. GL11.glTranslated(posX + 0.5D ,posY + 0.0D, posZ + 0.5D);
  34. GL11.glRotatef(0, 0, 0, 0);
  35.  
  36. ironProcessorModel.render((Entity) null, 1.0F, 0.0F, 0.0F, 0.0F, 0.0F, 0.0F);
  37.  
  38. GL11.glPopMatrix();
  39.  
  40. }
  41.  
  42. }
  43.  
  44. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement