diff --git a/javascript/ultra32/app.js b/javascript/ultra32/app.js index b9849ea..e7dad04 100644 --- a/javascript/ultra32/app.js +++ b/javascript/ultra32/app.js @@ -42,3 +42,10 @@ function rotate(vector) { return vector; } exports.rotate = rotate; +function clone(vector) { + const newVec = new Float32Array(vector.length); + for (let i = 0; i < vector.length; i++) { + newVec[i] = vector[i]; + } + return newVec; +}