mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-18 04:35:03 +00:00
Added parameters for texture translation when the NPC is powered, namely npc.display.poweredTranslateX, poweredTranslateY, and poweredTranslateZ, which can all be changed by setPoweredXYZ(x,y,z), and gotten with getPoweredX(), getPoweredY(), and getPoweredZ().
This commit is contained in:
1 parent
9560228ba8
commit
b7d2dab905
5 files changed
+50
-10
No files matched your search
@@ -258,14 +258,17 @@ public class RenderNPCInterface extends RenderLiving{
|
||||
this.bindTexture(poweredNPCTexture);
|
||||
GL11.glMatrixMode(GL11.GL_TEXTURE);
|
||||
GL11.glLoadIdentity();
|
||||
float f2 = f1 * 0.01F;
|
||||
float f3 = f1 * 0.01F;
|
||||
GL11.glTranslatef(f2, f3, 0.0F);
|
||||
|
||||
float f2 = f1 * npc.display.poweredTranslateX;
|
||||
float f3 = f1 * npc.display.poweredTranslateY;
|
||||
float f4 = f1 * npc.display.poweredTranslateZ;
|
||||
GL11.glTranslatef(f2, f3, f4);
|
||||
|
||||
this.setRenderPassModel(this.originalModel);
|
||||
GL11.glMatrixMode(GL11.GL_MODELVIEW);
|
||||
GL11.glEnable(GL11.GL_BLEND);
|
||||
float f4 = 0.5F;
|
||||
GL11.glColor4f(f4, f4, f4, 1.0F);
|
||||
float f5 = 0.5F;
|
||||
GL11.glColor4f(f5, f5, f5, 1.0F);
|
||||
GL11.glDisable(GL11.GL_LIGHTING);
|
||||
GL11.glBlendFunc(GL11.GL_ONE, GL11.GL_ONE);
|
||||
|
||||
|
||||
Reference in new issue
Block a user