diff options
author | hwc487 | 2012-03-23 14:59:51 -0700 |
---|---|---|
committer | hwc487 | 2012-03-23 14:59:51 -0700 |
commit | 86770d0dba6b137e651cbf5c8d240856be65857c (patch) | |
tree | c480e35abe9065733be9dd6326b91b46896b9e3a /js/lib | |
parent | 51478dbad8290f55eeab9efdfb8c2cbe24b12b10 (diff) | |
download | ninja-86770d0dba6b137e651cbf5c8d240856be65857c.tar.gz |
Fixed a problem switching from 3D to 2D and back to 3D.
Diffstat (limited to 'js/lib')
-rwxr-xr-x | js/lib/drawing/world.js | 2 | ||||
-rwxr-xr-x | js/lib/geom/geom-obj.js | 2 | ||||
-rwxr-xr-x | js/lib/geom/rectangle.js | 4 |
3 files changed, 6 insertions, 2 deletions
diff --git a/js/lib/drawing/world.js b/js/lib/drawing/world.js index b87c6272..73273adc 100755 --- a/js/lib/drawing/world.js +++ b/js/lib/drawing/world.js | |||
@@ -736,6 +736,8 @@ World.prototype.getShapeFromPoint = function( offsetX, offsetY ) { | |||
736 | } | 736 | } |
737 | }; | 737 | }; |
738 | 738 | ||
739 | |||
740 | |||
739 | World.prototype.exportJSON = function() | 741 | World.prototype.exportJSON = function() |
740 | { | 742 | { |
741 | // world properties | 743 | // world properties |
diff --git a/js/lib/geom/geom-obj.js b/js/lib/geom/geom-obj.js index dbef4859..a87bdbf5 100755 --- a/js/lib/geom/geom-obj.js +++ b/js/lib/geom/geom-obj.js | |||
@@ -248,7 +248,7 @@ var GeomObj = function GLGeomObj() { | |||
248 | this.exportMaterialsJSON = function() | 248 | this.exportMaterialsJSON = function() |
249 | { | 249 | { |
250 | var jObj; | 250 | var jObj; |
251 | if (this._materialArray && this._materialNodeArray) | 251 | if (this._materialArray && this._materialNodeArray && this.getWorld().isWebGL()) |
252 | { | 252 | { |
253 | var nMats = this._materialArray.length; | 253 | var nMats = this._materialArray.length; |
254 | if (nMats > 0) | 254 | if (nMats > 0) |
diff --git a/js/lib/geom/rectangle.js b/js/lib/geom/rectangle.js index 38e428bd..e511d5f4 100755 --- a/js/lib/geom/rectangle.js +++ b/js/lib/geom/rectangle.js | |||
@@ -187,7 +187,8 @@ var Rectangle = function GLRectangle() { | |||
187 | /////////////////////////////////////////////////////////////////////// | 187 | /////////////////////////////////////////////////////////////////////// |
188 | // Methods | 188 | // Methods |
189 | /////////////////////////////////////////////////////////////////////// | 189 | /////////////////////////////////////////////////////////////////////// |
190 | this.export = function() { | 190 | /* |
191 | this.export = function() { | ||
191 | var rtnStr = "type: " + this.geomType() + "\n"; | 192 | var rtnStr = "type: " + this.geomType() + "\n"; |
192 | 193 | ||
193 | ///////////////////////////////////////////////////////////////////////// | 194 | ///////////////////////////////////////////////////////////////////////// |
@@ -243,6 +244,7 @@ var Rectangle = function GLRectangle() { | |||
243 | 244 | ||
244 | return rtnStr; | 245 | return rtnStr; |
245 | }; | 246 | }; |
247 | */ | ||
246 | 248 | ||
247 | // JSON export | 249 | // JSON export |
248 | this.exportJSON = function() | 250 | this.exportJSON = function() |