summaryrefslogtreecommitdiffstats
path: root/o3d/samples/o3djs/serialization.js
diff options
context:
space:
mode:
Diffstat (limited to 'o3d/samples/o3djs/serialization.js')
-rw-r--r--o3d/samples/o3djs/serialization.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/o3d/samples/o3djs/serialization.js b/o3d/samples/o3djs/serialization.js
index 51e751d..c300023 100644
--- a/o3d/samples/o3djs/serialization.js
+++ b/o3d/samples/o3djs/serialization.js
@@ -289,10 +289,12 @@ o3djs.serialization.Deserializer = function(pack, json) {
'o3d.Skin': function(deserializer, object, json) {
if ('custom' in json) {
- var rawData = deserializer.archiveInfo.getFileByURI('skins.bin');
- object.set(rawData,
- json.custom.binaryRange[0],
- json.custom.binaryRange[1] - json.custom.binaryRange[0]);
+ if ('binaryRange' in json.custom) {
+ var rawData = deserializer.archiveInfo.getFileByURI('skins.bin');
+ object.set(rawData,
+ json.custom.binaryRange[0],
+ json.custom.binaryRange[1] - json.custom.binaryRange[0]);
+ }
}
},