diff --git a/api/src/main/java/com/seibel/lod/api/items/objects/math/DhApiMat4f.java b/api/src/main/java/com/seibel/lod/api/items/objects/math/DhApiMat4f.java index 89dd5dc90..1d63ee6f1 100644 --- a/api/src/main/java/com/seibel/lod/api/items/objects/math/DhApiMat4f.java +++ b/api/src/main/java/com/seibel/lod/api/items/objects/math/DhApiMat4f.java @@ -19,6 +19,8 @@ package com.seibel.lod.api.items.objects.math; +import com.seibel.lod.core.objects.math.Mat4f; + /** * A simple way to store a 4x4 array * of floats without having to worry @@ -96,6 +98,11 @@ public class DhApiMat4f m33 = values[15]; } + public DhApiMat4f(Mat4f sourceMatrix) + { + this(sourceMatrix.getValuesAsArray()); + } + /** Returns the values of this matrix in row major order (AKA rows then columns) */ diff --git a/core/src/main/java/com/seibel/lod/core/objects/math/Mat4f.java b/core/src/main/java/com/seibel/lod/core/objects/math/Mat4f.java index 2447f9f02..537d14925 100644 --- a/core/src/main/java/com/seibel/lod/core/objects/math/Mat4f.java +++ b/core/src/main/java/com/seibel/lod/core/objects/math/Mat4f.java @@ -448,7 +448,7 @@ public class Mat4f //==================// /** Returns the values of this matrix in row major order (AKA rows then columns) */ - private float[] getValuesAsArray() + public float[] getValuesAsArray() { return new float[] { this.m00,