mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-21 12:42:57 +00:00
Lots of integration. Graphics n stuff. Items. Everything.
This commit is contained in:
1 parent
4bb32da4c8
commit
0bdf31912b
48 files changed
+119
-384
No files matched your search
@@ -0,0 +1,29 @@
|
||||
package tconstruct.weaponry.client.entity;
|
||||
|
||||
import tconstruct.weaponry.entity.JavelinEntity;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
|
||||
public class JavelinEntityRenderer extends ProjectileBaseRenderer<JavelinEntity> {
|
||||
@Override
|
||||
public void customRendering(JavelinEntity entity, double x, double y, double z, float p_76986_8_, float p_76986_9_) {
|
||||
|
||||
// rotate it into the direction we threw it
|
||||
GL11.glRotatef(entity.rotationYaw, 0f, 1f, 0f);
|
||||
GL11.glRotatef(-entity.rotationPitch, 1f, 0f, 0f);
|
||||
|
||||
// rotate it so it faces forward
|
||||
GL11.glRotatef(90f, 1f, 0f, 0f);
|
||||
|
||||
// roll it all aroun
|
||||
GL11.glRotated(entity.roll, 0, 1, 0);
|
||||
|
||||
// make it looooong
|
||||
GL11.glScalef(1.5F, 3.0F, 1.5F);
|
||||
GL11.glTranslatef(0f, -0.5f, 0f);
|
||||
|
||||
// rotate the projectile it so it faces upwards (because the graphic itself is rotated by 45°)
|
||||
GL11.glRotatef(45, 0f, 0f, 1f);
|
||||
|
||||
toolCoreRenderer.setDepth(1/16f);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user