aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs
diff options
context:
space:
mode:
authorDiva Canto2013-06-05 20:20:22 -0700
committerDiva Canto2013-06-05 20:20:22 -0700
commit25fa647a74194db5b20155ac6d8a34cc231996e8 (patch)
tree5dce1f838e05c2bb8562cd039e229210d99b1c5c /OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs
parentStrengthen some assumptions. (diff)
parentDatabase persistence for keyframes. Contains a Migration. (diff)
downloadopensim-SC-25fa647a74194db5b20155ac6d8a34cc231996e8.zip
opensim-SC-25fa647a74194db5b20155ac6d8a34cc231996e8.tar.gz
opensim-SC-25fa647a74194db5b20155ac6d8a34cc231996e8.tar.bz2
opensim-SC-25fa647a74194db5b20155ac6d8a34cc231996e8.tar.xz
Merge branch 'master' of ssh://opensimulator.org/var/git/opensim
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs16
1 files changed, 16 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs b/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs
index 39420a6..3882b45 100644
--- a/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs
+++ b/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs
@@ -262,6 +262,12 @@ namespace OpenSim.Region.Framework.Scenes.Serialization
262 sr.Close(); 262 sr.Close();
263 } 263 }
264 264
265 XmlNodeList keymotion = doc.GetElementsByTagName("KeyframeMotion");
266 if (keymotion.Count > 0)
267 sceneObject.RootPart.KeyframeMotion = KeyframeMotion.FromData(sceneObject, Convert.FromBase64String(keymotion[0].InnerText));
268 else
269 sceneObject.RootPart.KeyframeMotion = null;
270
265 // Script state may, or may not, exist. Not having any, is NOT 271 // Script state may, or may not, exist. Not having any, is NOT
266 // ever a problem. 272 // ever a problem.
267 sceneObject.LoadScriptState(doc); 273 sceneObject.LoadScriptState(doc);
@@ -1182,6 +1188,16 @@ namespace OpenSim.Region.Framework.Scenes.Serialization
1182 }); 1188 });
1183 1189
1184 writer.WriteEndElement(); 1190 writer.WriteEndElement();
1191
1192 if (sog.RootPart.KeyframeMotion != null)
1193 {
1194 Byte[] data = sog.RootPart.KeyframeMotion.Serialize();
1195
1196 writer.WriteStartElement(String.Empty, "KeyframeMotion", String.Empty);
1197 writer.WriteBase64(data, 0, data.Length);
1198 writer.WriteEndElement();
1199 }
1200
1185 writer.WriteEndElement(); 1201 writer.WriteEndElement();
1186 } 1202 }
1187 1203