From 60d68ee3122a974007adec6e651fad461d8abda4 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Sun, 19 Feb 2012 18:10:00 +0000 Subject: Vehicle XML serialization more complete. Inactived by coments in SceneObjectSerializar.cs until proper testing --- OpenSim/Region/Framework/Scenes/SOPVehicle.cs | 223 ++++++++++++++++++++- OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | 13 ++ .../Scenes/Serialization/SceneObjectSerializer.cs | 28 +++ 3 files changed, 260 insertions(+), 4 deletions(-) diff --git a/OpenSim/Region/Framework/Scenes/SOPVehicle.cs b/OpenSim/Region/Framework/Scenes/SOPVehicle.cs index 39786bd..b462867 100644 --- a/OpenSim/Region/Framework/Scenes/SOPVehicle.cs +++ b/OpenSim/Region/Framework/Scenes/SOPVehicle.cs @@ -26,6 +26,7 @@ */ using System; +using System.Collections.Generic; using OpenMetaverse; using OpenSim.Framework; using OpenSim.Region.Physics.Manager; @@ -33,6 +34,7 @@ using System.Xml; using OpenSim.Framework.Serialization; using OpenSim.Framework.Serialization.External; using OpenSim.Region.Framework.Scenes.Serialization; +using OpenSim.Region.Framework.Scenes.Serialization; namespace OpenSim.Region.Framework.Scenes { @@ -44,7 +46,7 @@ namespace OpenSim.Region.Framework.Scenes { get { return vd.m_type; } } - + public SOPVehicle() { vd = new VehicleData(); @@ -116,8 +118,6 @@ namespace OpenSim.Region.Framework.Scenes vd.m_linearDeflectionTimescale = pValue; break; case Vehicle.LINEAR_MOTOR_DECAY_TIMESCALE: - // if (pValue < timestep) pValue = timestep; - // try to make impulses to work a bit better if (pValue < timestep) pValue = timestep; else if (pValue > 120) pValue = 120; vd.m_linearMotorDecayTimescale = pValue; @@ -439,7 +439,7 @@ namespace OpenSim.Region.Framework.Scenes public void ToXml2(XmlTextWriter twriter) { writer = twriter; - writer.WriteStartElement("SOGVehicle"); + writer.WriteStartElement("Vehicle"); XWint("TYPE", (int)vd.m_type); XWint("FLAGS", (int)vd.m_flags); @@ -483,5 +483,220 @@ namespace OpenSim.Region.Framework.Scenes writer.WriteEndElement(); writer = null; } + + private int XRint(XmlTextReader reader, string name) + { + return reader.ReadElementContentAsInt(name, String.Empty); + } + + private float XRfloat(XmlTextReader reader, string name) + { + return reader.ReadElementContentAsFloat(name, String.Empty); + } + + public Vector3 XRvector(XmlTextReader reader, string name) + { + Vector3 vec; + reader.ReadStartElement(name); + vec.X = reader.ReadElementContentAsFloat(reader.Name, String.Empty); // X or x + vec.Y = reader.ReadElementContentAsFloat(reader.Name, String.Empty); // Y or y + vec.Z = reader.ReadElementContentAsFloat(reader.Name, String.Empty); // Z or z + reader.ReadEndElement(); + return vec; + } + + public Quaternion XRquat(XmlTextReader reader, string name) + { + Quaternion q; + reader.ReadStartElement(name); + q.X = reader.ReadElementContentAsFloat(reader.Name, String.Empty); + q.Y = reader.ReadElementContentAsFloat(reader.Name, String.Empty); + q.Z = reader.ReadElementContentAsFloat(reader.Name, String.Empty); + q.W = reader.ReadElementContentAsFloat(reader.Name, String.Empty); + reader.ReadEndElement(); + return q; + } + + public void FromXml2(XmlTextReader reader, out bool errors) + { + errors = false; + + Dictionary> m_VehicleXmlProcessors + = new Dictionary>(); + + m_VehicleXmlProcessors.Add("TYPE", ProcessXR_type); + m_VehicleXmlProcessors.Add("FLAGS", ProcessXR_flags); + + // Linear properties + m_VehicleXmlProcessors.Add("LMDIR", ProcessXR_linearMotorDirection); + m_VehicleXmlProcessors.Add("LMFTIME", ProcessXR_linearFrictionTimescale); + m_VehicleXmlProcessors.Add("LMDTIME", ProcessXR_linearMotorDecayTimescale); + m_VehicleXmlProcessors.Add("LMTIME", ProcessXR_linearMotorTimescale); + m_VehicleXmlProcessors.Add("LMOFF", ProcessXR_linearMotorOffset); + + //Angular properties + m_VehicleXmlProcessors.Add("AMDIR", ProcessXR_angularMotorDirection); + m_VehicleXmlProcessors.Add("AMTIME", ProcessXR_angularMotorTimescale); + m_VehicleXmlProcessors.Add("AMDTIME", ProcessXR_angularMotorDecayTimescale); + m_VehicleXmlProcessors.Add("AMFTIME", ProcessXR_angularFrictionTimescale); + + //Deflection properties + m_VehicleXmlProcessors.Add("ADEFF", ProcessXR_angularDeflectionEfficiency); + m_VehicleXmlProcessors.Add("ADTIME", ProcessXR_angularDeflectionTimescale); + m_VehicleXmlProcessors.Add("LDEFF", ProcessXR_linearDeflectionEfficiency); + m_VehicleXmlProcessors.Add("LDTIME", ProcessXR_linearDeflectionTimescale); + + //Banking properties + m_VehicleXmlProcessors.Add("BEFF", ProcessXR_bankingEfficiency); + m_VehicleXmlProcessors.Add("BMIX", ProcessXR_bankingMix); + m_VehicleXmlProcessors.Add("BTIME", ProcessXR_bankingTimescale); + + //Hover and Buoyancy properties + m_VehicleXmlProcessors.Add("HHEI", ProcessXR_VhoverHeight); + m_VehicleXmlProcessors.Add("HEFF", ProcessXR_VhoverEfficiency); + m_VehicleXmlProcessors.Add("HTIME", ProcessXR_VhoverTimescale); + + m_VehicleXmlProcessors.Add("VBUO", ProcessXR_VehicleBuoyancy); + + //Attractor properties + m_VehicleXmlProcessors.Add("VAEFF", ProcessXR_verticalAttractionEfficiency); + m_VehicleXmlProcessors.Add("VATIME", ProcessXR_verticalAttractionTimescale); + + m_VehicleXmlProcessors.Add("REF_FRAME", ProcessXR_referenceFrame); + + vd = new VehicleData(); + + reader.ReadStartElement("Vehicle", String.Empty); + + errors = ExternalRepresentationUtils.ExecuteReadProcessors( + vd, + m_VehicleXmlProcessors, + reader, + (o, nodeName, e) + => + { + } + ); + + reader.ReadEndElement(); + } + + private void ProcessXR_type(VehicleData obj, XmlTextReader reader) + { + vd.m_type = (Vehicle)XRint(reader, "TYPE"); + } + private void ProcessXR_flags(VehicleData obj, XmlTextReader reader) + { + vd.m_flags = (VehicleFlag)XRint(reader, "FLAGS"); + } + // Linear properties + private void ProcessXR_linearMotorDirection(VehicleData obj, XmlTextReader reader) + { + vd.m_linearMotorDirection = XRvector(reader, "LMDIR"); + } + + private void ProcessXR_linearFrictionTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_linearFrictionTimescale = XRvector(reader, "LMFTIME"); + } + + private void ProcessXR_linearMotorDecayTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_linearMotorDecayTimescale = XRfloat(reader, "LMDTIME"); + } + private void ProcessXR_linearMotorTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_linearMotorTimescale = XRfloat(reader, "LMTIME"); + } + private void ProcessXR_linearMotorOffset(VehicleData obj, XmlTextReader reader) + { + vd.m_linearMotorOffset = XRvector(reader, "LMOFF"); + } + + + //Angular properties + private void ProcessXR_angularMotorDirection(VehicleData obj, XmlTextReader reader) + { + vd.m_angularMotorDirection = XRvector(reader, "AMDIR"); + } + private void ProcessXR_angularMotorTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_angularMotorTimescale = XRfloat(reader, "AMTIME"); + } + private void ProcessXR_angularMotorDecayTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_angularMotorDecayTimescale = XRfloat(reader, "AMDTIME"); + } + private void ProcessXR_angularFrictionTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_angularFrictionTimescale = XRvector(reader, "AMFTIME"); + } + + //Deflection properties + private void ProcessXR_angularDeflectionEfficiency(VehicleData obj, XmlTextReader reader) + { + vd.m_angularDeflectionEfficiency = XRfloat(reader, "ADEFF"); + } + private void ProcessXR_angularDeflectionTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_angularDeflectionTimescale = XRfloat(reader, "ADTIME"); + } + private void ProcessXR_linearDeflectionEfficiency(VehicleData obj, XmlTextReader reader) + { + vd.m_linearDeflectionEfficiency = XRfloat(reader, "LDEFF"); + } + private void ProcessXR_linearDeflectionTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_linearDeflectionTimescale = XRfloat(reader, "LDTIME"); + } + + //Banking properties + private void ProcessXR_bankingEfficiency(VehicleData obj, XmlTextReader reader) + { + vd.m_bankingEfficiency = XRfloat(reader, "BEFF"); + } + private void ProcessXR_bankingMix(VehicleData obj, XmlTextReader reader) + { + vd.m_bankingMix = XRfloat(reader, "BMIX"); + } + private void ProcessXR_bankingTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_bankingTimescale = XRfloat(reader, "BTIME"); + } + + //Hover and Buoyancy properties + private void ProcessXR_VhoverHeight(VehicleData obj, XmlTextReader reader) + { + vd.m_VhoverHeight = XRfloat(reader, "HHEI"); + } + private void ProcessXR_VhoverEfficiency(VehicleData obj, XmlTextReader reader) + { + vd.m_VhoverEfficiency = XRfloat(reader, "HEFF"); + } + private void ProcessXR_VhoverTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_VhoverTimescale = XRfloat(reader, "HTIME"); + } + + private void ProcessXR_VehicleBuoyancy(VehicleData obj, XmlTextReader reader) + { + vd.m_VehicleBuoyancy = XRfloat(reader, "VBUO"); + } + + //Attractor properties + private void ProcessXR_verticalAttractionEfficiency(VehicleData obj, XmlTextReader reader) + { + vd.m_verticalAttractionEfficiency = XRfloat(reader, "VAEFF"); + } + private void ProcessXR_verticalAttractionTimescale(VehicleData obj, XmlTextReader reader) + { + vd.m_verticalAttractionTimescale = XRfloat(reader, "VATIME"); + } + + private void ProcessXR_referenceFrame(VehicleData obj, XmlTextReader reader) + { + vd.m_referenceFrame = XRquat(reader, "REF_FRAME"); + + } } } \ No newline at end of file diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index eb59ffd..4cd5183 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs @@ -3177,6 +3177,18 @@ namespace OpenSim.Region.Framework.Scenes } } + public SOPVehicle sopVehicle + { + get + { + return m_vehicle; + } + set + { + m_vehicle = value; + } + } + public int VehicleType { @@ -3196,6 +3208,7 @@ namespace OpenSim.Region.Framework.Scenes public void SetVehicleType(int type) { m_vehicle = null; + if (type == (int)Vehicle.TYPE_NONE) { if (_parentID ==0 && PhysActor != null) diff --git a/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs b/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs index 4b80e37..eaf32b8 100644 --- a/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs +++ b/OpenSim/Region/Framework/Scenes/Serialization/SceneObjectSerializer.cs @@ -349,6 +349,11 @@ namespace OpenSim.Region.Framework.Scenes.Serialization m_SOPXmlProcessors.Add("Buoyancy", ProcessBuoyancy); m_SOPXmlProcessors.Add("VolumeDetectActive", ProcessVolumeDetectActive); + + //Ubit comented until proper testing + // m_SOPXmlProcessors.Add("Vehicle", ProcessVehicle); + + #endregion #region TaskInventoryXmlProcessors initialization @@ -571,6 +576,25 @@ namespace OpenSim.Region.Framework.Scenes.Serialization obj.ClickAction = (byte)reader.ReadElementContentAsInt("ClickAction", String.Empty); } + private static void ProcessVehicle(SceneObjectPart obj, XmlTextReader reader) + { + bool errors = false; + SOPVehicle _vehicle = new SOPVehicle(); + + _vehicle.FromXml2(reader, out errors); + + if (errors) + { + obj.sopVehicle = null; + m_log.DebugFormat( + "[SceneObjectSerializer]: Parsing Vehicle for object part {0} {1} encountered errors. Please see earlier log entries.", + obj.Name, obj.UUID); + } + else + obj.sopVehicle = _vehicle; + } + + private static void ProcessShape(SceneObjectPart obj, XmlTextReader reader) { bool errors = false; @@ -1231,6 +1255,10 @@ namespace OpenSim.Region.Framework.Scenes.Serialization writer.WriteElementString("Buoyancy", sop.Buoyancy.ToString()); writer.WriteElementString("VolumeDetectActive", sop.VolumeDetectActive.ToString().ToLower()); + //Ubit comented until proper testing + // if (sop.sopVehicle != null) + // sop.sopVehicle.ToXml2(writer); + writer.WriteEndElement(); } -- cgit v1.1 From 3c9b7f2c0c40e6a976be708763ab166fcdee66b1 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Sun, 19 Feb 2012 19:27:01 +0000 Subject: simplified vehicle fromXml. Use still comented on SceneObjectSerialized.cs --- OpenSim/Region/Framework/Scenes/SOPVehicle.cs | 194 ++++++++++++++++---------- 1 file changed, 117 insertions(+), 77 deletions(-) diff --git a/OpenSim/Region/Framework/Scenes/SOPVehicle.cs b/OpenSim/Region/Framework/Scenes/SOPVehicle.cs index b462867..d3c2d27 100644 --- a/OpenSim/Region/Framework/Scenes/SOPVehicle.cs +++ b/OpenSim/Region/Framework/Scenes/SOPVehicle.cs @@ -484,45 +484,91 @@ namespace OpenSim.Region.Framework.Scenes writer = null; } - private int XRint(XmlTextReader reader, string name) + + + XmlTextReader reader; + + private int XRint() { - return reader.ReadElementContentAsInt(name, String.Empty); + return reader.ReadElementContentAsInt(); } - private float XRfloat(XmlTextReader reader, string name) + private float XRfloat() { - return reader.ReadElementContentAsFloat(name, String.Empty); + return reader.ReadElementContentAsFloat(); } - public Vector3 XRvector(XmlTextReader reader, string name) + public Vector3 XRvector() { Vector3 vec; - reader.ReadStartElement(name); - vec.X = reader.ReadElementContentAsFloat(reader.Name, String.Empty); // X or x - vec.Y = reader.ReadElementContentAsFloat(reader.Name, String.Empty); // Y or y - vec.Z = reader.ReadElementContentAsFloat(reader.Name, String.Empty); // Z or z + reader.ReadStartElement(); + vec.X = reader.ReadElementContentAsFloat(); + vec.Y = reader.ReadElementContentAsFloat(); + vec.Z = reader.ReadElementContentAsFloat(); reader.ReadEndElement(); return vec; } - public Quaternion XRquat(XmlTextReader reader, string name) + public Quaternion XRquat() { Quaternion q; - reader.ReadStartElement(name); - q.X = reader.ReadElementContentAsFloat(reader.Name, String.Empty); - q.Y = reader.ReadElementContentAsFloat(reader.Name, String.Empty); - q.Z = reader.ReadElementContentAsFloat(reader.Name, String.Empty); - q.W = reader.ReadElementContentAsFloat(reader.Name, String.Empty); + reader.ReadStartElement(); + q.X = reader.ReadElementContentAsFloat(); + q.Y = reader.ReadElementContentAsFloat(); + q.Z = reader.ReadElementContentAsFloat(); + q.W = reader.ReadElementContentAsFloat(); reader.ReadEndElement(); return q; } - public void FromXml2(XmlTextReader reader, out bool errors) + public static bool EReadProcessors( + Dictionary processors, + XmlTextReader xtr) + { + bool errors = false; + + string nodeName = string.Empty; + while (xtr.NodeType != XmlNodeType.EndElement) + { + nodeName = xtr.Name; + + // m_log.DebugFormat("[ExternalRepresentationUtils]: Processing: {0}", nodeName); + + Action p = null; + if (processors.TryGetValue(xtr.Name, out p)) + { + // m_log.DebugFormat("[ExternalRepresentationUtils]: Found {0} processor, nodeName); + + try + { + p(); + } + catch (Exception e) + { + errors = true; + if (xtr.NodeType == XmlNodeType.EndElement) + xtr.Read(); + } + } + else + { + // m_log.DebugFormat("[LandDataSerializer]: caught unknown element {0}", nodeName); + xtr.ReadOuterXml(); // ignore + } + } + + return errors; + } + + + + public void FromXml2(XmlTextReader _reader, out bool errors) { errors = false; + reader = _reader; - Dictionary> m_VehicleXmlProcessors - = new Dictionary>(); + Dictionary m_VehicleXmlProcessors + = new Dictionary(); m_VehicleXmlProcessors.Add("TYPE", ProcessXR_type); m_VehicleXmlProcessors.Add("FLAGS", ProcessXR_flags); @@ -568,135 +614,129 @@ namespace OpenSim.Region.Framework.Scenes reader.ReadStartElement("Vehicle", String.Empty); - errors = ExternalRepresentationUtils.ExecuteReadProcessors( - vd, + errors = EReadProcessors( m_VehicleXmlProcessors, - reader, - (o, nodeName, e) - => - { - } - ); + reader); reader.ReadEndElement(); + reader = null; } - private void ProcessXR_type(VehicleData obj, XmlTextReader reader) + private void ProcessXR_type() { - vd.m_type = (Vehicle)XRint(reader, "TYPE"); + vd.m_type = (Vehicle)XRint(); } - private void ProcessXR_flags(VehicleData obj, XmlTextReader reader) + private void ProcessXR_flags() { - vd.m_flags = (VehicleFlag)XRint(reader, "FLAGS"); + vd.m_flags = (VehicleFlag)XRint(); } // Linear properties - private void ProcessXR_linearMotorDirection(VehicleData obj, XmlTextReader reader) + private void ProcessXR_linearMotorDirection() { - vd.m_linearMotorDirection = XRvector(reader, "LMDIR"); + vd.m_linearMotorDirection = XRvector(); } - private void ProcessXR_linearFrictionTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_linearFrictionTimescale() { - vd.m_linearFrictionTimescale = XRvector(reader, "LMFTIME"); + vd.m_linearFrictionTimescale = XRvector(); } - private void ProcessXR_linearMotorDecayTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_linearMotorDecayTimescale() { - vd.m_linearMotorDecayTimescale = XRfloat(reader, "LMDTIME"); + vd.m_linearMotorDecayTimescale = XRfloat(); } - private void ProcessXR_linearMotorTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_linearMotorTimescale() { - vd.m_linearMotorTimescale = XRfloat(reader, "LMTIME"); + vd.m_linearMotorTimescale = XRfloat(); } - private void ProcessXR_linearMotorOffset(VehicleData obj, XmlTextReader reader) + private void ProcessXR_linearMotorOffset() { - vd.m_linearMotorOffset = XRvector(reader, "LMOFF"); + vd.m_linearMotorOffset = XRvector(); } //Angular properties - private void ProcessXR_angularMotorDirection(VehicleData obj, XmlTextReader reader) + private void ProcessXR_angularMotorDirection() { - vd.m_angularMotorDirection = XRvector(reader, "AMDIR"); + vd.m_angularMotorDirection = XRvector(); } - private void ProcessXR_angularMotorTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_angularMotorTimescale() { - vd.m_angularMotorTimescale = XRfloat(reader, "AMTIME"); + vd.m_angularMotorTimescale = XRfloat(); } - private void ProcessXR_angularMotorDecayTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_angularMotorDecayTimescale() { - vd.m_angularMotorDecayTimescale = XRfloat(reader, "AMDTIME"); + vd.m_angularMotorDecayTimescale = XRfloat(); } - private void ProcessXR_angularFrictionTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_angularFrictionTimescale() { - vd.m_angularFrictionTimescale = XRvector(reader, "AMFTIME"); + vd.m_angularFrictionTimescale = XRvector(); } //Deflection properties - private void ProcessXR_angularDeflectionEfficiency(VehicleData obj, XmlTextReader reader) + private void ProcessXR_angularDeflectionEfficiency() { - vd.m_angularDeflectionEfficiency = XRfloat(reader, "ADEFF"); + vd.m_angularDeflectionEfficiency = XRfloat(); } - private void ProcessXR_angularDeflectionTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_angularDeflectionTimescale() { - vd.m_angularDeflectionTimescale = XRfloat(reader, "ADTIME"); + vd.m_angularDeflectionTimescale = XRfloat(); } - private void ProcessXR_linearDeflectionEfficiency(VehicleData obj, XmlTextReader reader) + private void ProcessXR_linearDeflectionEfficiency() { - vd.m_linearDeflectionEfficiency = XRfloat(reader, "LDEFF"); + vd.m_linearDeflectionEfficiency = XRfloat(); } - private void ProcessXR_linearDeflectionTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_linearDeflectionTimescale() { - vd.m_linearDeflectionTimescale = XRfloat(reader, "LDTIME"); + vd.m_linearDeflectionTimescale = XRfloat(); } //Banking properties - private void ProcessXR_bankingEfficiency(VehicleData obj, XmlTextReader reader) + private void ProcessXR_bankingEfficiency() { - vd.m_bankingEfficiency = XRfloat(reader, "BEFF"); + vd.m_bankingEfficiency = XRfloat(); } - private void ProcessXR_bankingMix(VehicleData obj, XmlTextReader reader) + private void ProcessXR_bankingMix() { - vd.m_bankingMix = XRfloat(reader, "BMIX"); + vd.m_bankingMix = XRfloat(); } - private void ProcessXR_bankingTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_bankingTimescale() { - vd.m_bankingTimescale = XRfloat(reader, "BTIME"); + vd.m_bankingTimescale = XRfloat(); } //Hover and Buoyancy properties - private void ProcessXR_VhoverHeight(VehicleData obj, XmlTextReader reader) + private void ProcessXR_VhoverHeight() { - vd.m_VhoverHeight = XRfloat(reader, "HHEI"); + vd.m_VhoverHeight = XRfloat(); } - private void ProcessXR_VhoverEfficiency(VehicleData obj, XmlTextReader reader) + private void ProcessXR_VhoverEfficiency() { - vd.m_VhoverEfficiency = XRfloat(reader, "HEFF"); + vd.m_VhoverEfficiency = XRfloat(); } - private void ProcessXR_VhoverTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_VhoverTimescale() { - vd.m_VhoverTimescale = XRfloat(reader, "HTIME"); + vd.m_VhoverTimescale = XRfloat(); } - private void ProcessXR_VehicleBuoyancy(VehicleData obj, XmlTextReader reader) + private void ProcessXR_VehicleBuoyancy() { - vd.m_VehicleBuoyancy = XRfloat(reader, "VBUO"); + vd.m_VehicleBuoyancy = XRfloat(); } //Attractor properties - private void ProcessXR_verticalAttractionEfficiency(VehicleData obj, XmlTextReader reader) + private void ProcessXR_verticalAttractionEfficiency() { - vd.m_verticalAttractionEfficiency = XRfloat(reader, "VAEFF"); + vd.m_verticalAttractionEfficiency = XRfloat(); } - private void ProcessXR_verticalAttractionTimescale(VehicleData obj, XmlTextReader reader) + private void ProcessXR_verticalAttractionTimescale() { - vd.m_verticalAttractionTimescale = XRfloat(reader, "VATIME"); + vd.m_verticalAttractionTimescale = XRfloat(); } - private void ProcessXR_referenceFrame(VehicleData obj, XmlTextReader reader) + private void ProcessXR_referenceFrame() { - vd.m_referenceFrame = XRquat(reader, "REF_FRAME"); - + vd.m_referenceFrame = XRquat(); } } } \ No newline at end of file -- cgit v1.1