diff options
author | hwc487 | 2012-03-16 15:17:53 -0700 |
---|---|---|
committer | hwc487 | 2012-03-16 15:17:53 -0700 |
commit | 55b2231d7badec16990b63ef1b6c770ef1e6fc25 (patch) | |
tree | 62d555dc627d30be8d7aec49e36935baca4e7fc3 /js/lib/drawing | |
parent | 2ac5db3bb1bcee887d6dd742e6c0273abb5366bd (diff) | |
download | ninja-55b2231d7badec16990b63ef1b6c770ef1e6fc25.tar.gz |
Supporting new and old GL data formats.
Diffstat (limited to 'js/lib/drawing')
-rwxr-xr-x | js/lib/drawing/world.js | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/js/lib/drawing/world.js b/js/lib/drawing/world.js index 4b117242..0ee66abe 100755 --- a/js/lib/drawing/world.js +++ b/js/lib/drawing/world.js | |||
@@ -754,7 +754,14 @@ World.prototype.exportJSON = function() | |||
754 | // convert the object to a string | 754 | // convert the object to a string |
755 | var jStr = JSON.stringify( worldObj ); | 755 | var jStr = JSON.stringify( worldObj ); |
756 | 756 | ||
757 | // the RDGE export function corrupts the data. | 757 | // prepend some version information to the string. |
758 | // this string is also used to differentiate between JSON | ||
759 | // and pre-JSON versions of fileIO. | ||
760 | // the ending ';' in the version string is necessary | ||
761 | jStr = "v1.0;" + jStr; | ||
762 | |||
763 | // You would think that the RDGE export function | ||
764 | // would not change the data. You would be wrong... | ||
758 | // rebuild the tree | 765 | // rebuild the tree |
759 | var root = this._rootNode; | 766 | var root = this._rootNode; |
760 | root.children = new Array(); | 767 | root.children = new Array(); |