diff options
author | dr scofield (aka dirk husemann) | 2009-10-01 15:03:16 +0200 |
---|---|---|
committer | dr scofield (aka dirk husemann) | 2009-10-01 15:03:16 +0200 |
commit | 133a4a9906e55b20ff8780ebe5f59df87d5523ee (patch) | |
tree | ead45aa414d6fcf61ace87f873512250ec4a3f20 /OpenSim/Framework/Serialization/External/LandDataSerializer.cs | |
parent | fixing LandDataSerializer (yeah! for testcases) (diff) | |
download | opensim-SC-133a4a9906e55b20ff8780ebe5f59df87d5523ee.zip opensim-SC-133a4a9906e55b20ff8780ebe5f59df87d5523ee.tar.gz opensim-SC-133a4a9906e55b20ff8780ebe5f59df87d5523ee.tar.bz2 opensim-SC-133a4a9906e55b20ff8780ebe5f59df87d5523ee.tar.xz |
- adding new LandDataSerializer testcase to "test-xml" target as well
- adding another LandDataSerializer testcase
Diffstat (limited to 'OpenSim/Framework/Serialization/External/LandDataSerializer.cs')
-rw-r--r-- | OpenSim/Framework/Serialization/External/LandDataSerializer.cs | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/OpenSim/Framework/Serialization/External/LandDataSerializer.cs b/OpenSim/Framework/Serialization/External/LandDataSerializer.cs index e980945..a3bc5d1 100644 --- a/OpenSim/Framework/Serialization/External/LandDataSerializer.cs +++ b/OpenSim/Framework/Serialization/External/LandDataSerializer.cs | |||
@@ -99,7 +99,7 @@ namespace OpenSim.Framework.Serialization.External | |||
99 | { | 99 | { |
100 | while (xtr.Read() && xtr.NodeType != XmlNodeType.EndElement) | 100 | while (xtr.Read() && xtr.NodeType != XmlNodeType.EndElement) |
101 | { | 101 | { |
102 | ParcelManager.ParcelAccessEntry pae; | 102 | ParcelManager.ParcelAccessEntry pae = new ParcelManager.ParcelAccessEntry(); |
103 | 103 | ||
104 | xtr.ReadStartElement("ParcelAccessEntry"); | 104 | xtr.ReadStartElement("ParcelAccessEntry"); |
105 | pae.AgentID = UUID.Parse( xtr.ReadElementString("AgentID")); | 105 | pae.AgentID = UUID.Parse( xtr.ReadElementString("AgentID")); |
@@ -112,14 +112,14 @@ namespace OpenSim.Framework.Serialization.External | |||
112 | } | 112 | } |
113 | xtr.Read(); | 113 | xtr.Read(); |
114 | 114 | ||
115 | landData.PassHours = Convert.ToSingle( xtr.ReadElementString("PassHours")); | 115 | landData.PassHours = Convert.ToSingle( xtr.ReadElementString("PassHours")); |
116 | landData.PassPrice = Convert.ToInt32( xtr.ReadElementString("PassPrice")); | 116 | landData.PassPrice = Convert.ToInt32( xtr.ReadElementString("PassPrice")); |
117 | landData.SalePrice = Convert.ToInt32( xtr.ReadElementString("SalePrice")); | 117 | landData.SalePrice = Convert.ToInt32( xtr.ReadElementString("SalePrice")); |
118 | landData.SnapshotID = UUID.Parse( xtr.ReadElementString("SnapshotID")); | 118 | landData.SnapshotID = UUID.Parse( xtr.ReadElementString("SnapshotID")); |
119 | landData.UserLocation = Vector3.Parse( xtr.ReadElementString("UserLocation")); | 119 | landData.UserLocation = Vector3.Parse( xtr.ReadElementString("UserLocation")); |
120 | landData.UserLookAt = Vector3.Parse( xtr.ReadElementString("UserLookAt")); | 120 | landData.UserLookAt = Vector3.Parse( xtr.ReadElementString("UserLookAt")); |
121 | landData.Dwell = Convert.ToInt32( xtr.ReadElementString("Dwell")); | 121 | landData.Dwell = Convert.ToInt32( xtr.ReadElementString("Dwell")); |
122 | landData.OtherCleanTime = Convert.ToInt32( xtr.ReadElementString("OtherCleanTime")); | 122 | landData.OtherCleanTime = Convert.ToInt32( xtr.ReadElementString("OtherCleanTime")); |
123 | 123 | ||
124 | xtr.ReadEndElement(); | 124 | xtr.ReadEndElement(); |
125 | 125 | ||
@@ -165,8 +165,8 @@ namespace OpenSim.Framework.Serialization.External | |||
165 | { | 165 | { |
166 | xtw.WriteStartElement("ParcelAccessEntry"); | 166 | xtw.WriteStartElement("ParcelAccessEntry"); |
167 | xtw.WriteElementString("AgentID", pal.AgentID.ToString()); | 167 | xtw.WriteElementString("AgentID", pal.AgentID.ToString()); |
168 | xtw.WriteElementString("Time", Convert.ToString(pal.Time)); | 168 | xtw.WriteElementString("Time", pal.Time.ToString("s")); |
169 | xtw.WriteElementString("AccessList", Convert.ToString(pal.Flags)); | 169 | xtw.WriteElementString("AccessList", Convert.ToString((uint)pal.Flags)); |
170 | xtw.WriteEndElement(); | 170 | xtw.WriteEndElement(); |
171 | } | 171 | } |
172 | xtw.WriteEndElement(); | 172 | xtw.WriteEndElement(); |