It's probably helpful if the clone on the scene model actually clones its ObjectInfo bits.

git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@901 ed5b42cb-e716-0410-a449-f6a68f950b19
This commit is contained in:
Mike Thomas
2010-03-11 00:51:30 +00:00
parent ba3be78a51
commit 5920f44e64
2 changed files with 8 additions and 2 deletions
@@ -196,7 +196,10 @@ public class SimpleMisoSceneModel extends MisoSceneModel
model.objectTileIds = objectTileIds.clone();
model.objectXs = objectXs.clone();
model.objectYs = objectYs.clone();
model.objectInfo = objectInfo.clone();
model.objectInfo = new ObjectInfo[objectInfo.length];
for (int ii = 0; ii < objectInfo.length; ii++) {
model.objectInfo[ii] = objectInfo[ii].clone();
}
return model;
}
@@ -233,7 +233,10 @@ public class SparseMisoSceneModel extends MisoSceneModel
section.objectTileIds = objectTileIds.clone();
section.objectXs = objectXs.clone();
section.objectYs = objectYs.clone();
section.objectInfo = objectInfo.clone();
section.objectInfo = new ObjectInfo[objectInfo.length];
for (int ii = 0; ii < objectInfo.length; ii++) {
section.objectInfo[ii] = objectInfo[ii].clone();
}
return section;
} catch (CloneNotSupportedException cnse) {
throw new AssertionError(cnse);