Skip to content
Snippets Groups Projects
Commit 10c0ffb2 authored by Amanda Ghassaei's avatar Amanda Ghassaei
Browse files

debugging

parent 66f346ef
No related branches found
No related tags found
No related merge requests found
......@@ -21,9 +21,9 @@ DMASuperCell.prototype = Object.create(DMACell.prototype);
DMASuperCell.prototype._makeChildCells = function(index, range){
var cells = [];//todo make cells a 3d array?
for (var x=0;i<range.x;x++){
for (var x=0;x<range.x;x++){
for (var y=0;y<range.y;y++){
for (var z=0;i<range.z;z++){
for (var z=0;z<range.z;z++){
cells.push(this._makeSubCellForIndex({x:x, y:y, z:z}));
}
}
......@@ -60,7 +60,8 @@ DMASuperCell.prototype.setMode = function(mode){
};
DMASuperCell.prototype.getLength = function(){
return this.cells.length-1;
if (this.cells) return this.cells.length-1;
return globals.lattice.get("superCellRange").x;
};
DMASuperCell.prototype.destroy = function(){
......
......@@ -47,7 +47,7 @@ GIKSuperCell.prototype._rotateCell = function(object3D){
};
GIKSuperCell.prototype._buildMesh = function(){
var length = globals.lattice.get("gikLength");
var length = globals.lattice.get("superCellRange").x;
var meshes = [];
var superCellGeo = new THREE.BoxGeometry(1,1,1.28);
superCellGeo.applyMatrix(new THREE.Matrix4().makeScale(length, 1, 1));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment