maybe this will help

pull/12/head
SuperCoder7979 2020-02-28 07:21:42 -05:00
parent 58e580a497
commit e28ae9233a
2 changed files with 4 additions and 3 deletions

View File

@ -37,8 +37,7 @@ public class BlockRenderer extends Renderer implements WorldGenConstants
public void prepareModel(TexturedModel model)
{
RawModel rawModel = model.getRawModel();
GL30.glBindVertexArray(rawModel.getVaoID());
GL30.glBindVertexArray(model.getRawModel().getVaoID());
GL20.glEnableVertexAttribArray(0);
GL20.glEnableVertexAttribArray(1);
GL20.glEnableVertexAttribArray(2);

View File

@ -42,10 +42,12 @@ public class Maths
private static final Vector3f XVEC = new Vector3f(1, 0, 0);
private static final Vector3f YVEC = new Vector3f(0, 1, 0);
private static final Vector3f ZVEC = new Vector3f(0, 0, 1);
private static final Matrix4f matrix = new Matrix4f();
public static Matrix4f createTransformationMatrix(Vector3f translation, float rx, float ry, float rz, Vector3f scale)
{
Matrix4f matrix = new Matrix4f();
matrix.zero();
matrix.identity();
matrix.translate(translation, matrix);
matrix.rotate((float) Math.toRadians(rx), XVEC, matrix);