Don't foolishly blow away a perfectly good set of object tile ids and

actions unless we're actually loaded into the editor and turned into a
real editable scene.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1315 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
Michael Bayne
2002-04-28 03:14:15 +00:00
parent d107dd790f
commit dc5d23e3e4
@@ -1,5 +1,5 @@
// //
// $Id: EditableMisoSceneImpl.java,v 1.17 2002/04/27 18:41:14 mdb Exp $ // $Id: EditableMisoSceneImpl.java,v 1.18 2002/04/28 03:14:15 mdb Exp $
package com.threerings.miso.scene.tools; package com.threerings.miso.scene.tools;
@@ -187,6 +187,9 @@ public class EditableMisoSceneImpl
// we need to flush the object layer to the model prior to // we need to flush the object layer to the model prior to
// returning it // returning it
int ocount = _objects.size(); int ocount = _objects.size();
// but only do it if we've actually got some objects
if (ocount > 0) {
int[] otids = new int[ocount*3]; int[] otids = new int[ocount*3];
String[] actions = new String[ocount]; String[] actions = new String[ocount];
@@ -202,6 +205,7 @@ public class EditableMisoSceneImpl
// stuff the new arrays into the model // stuff the new arrays into the model
_model.objectTileIds = otids; _model.objectTileIds = otids;
_model.objectActions = actions; _model.objectActions = actions;
}
// and we're ready to roll // and we're ready to roll
return _model; return _model;