PGSQL: store vehicle data
parent
c14209e362
commit
650cef67d1
|
@ -1806,6 +1806,13 @@ namespace OpenSim.Data.PGSQL
|
||||||
prim.Restitution = Convert.ToSingle(primRow["Restitution"]);
|
prim.Restitution = Convert.ToSingle(primRow["Restitution"]);
|
||||||
prim.RotationAxisLocks = Convert.ToByte(primRow["RotationAxisLocks"]);
|
prim.RotationAxisLocks = Convert.ToByte(primRow["RotationAxisLocks"]);
|
||||||
|
|
||||||
|
SOPVehicle vehicle = null;
|
||||||
|
if (!(primRow["Vehicle"] is System.DBNull))
|
||||||
|
{
|
||||||
|
vehicle = SOPVehicle.FromXml2(primRow["Vehicle"].ToString());
|
||||||
|
if (vehicle != null)
|
||||||
|
prim.VehicleParams = vehicle;
|
||||||
|
}
|
||||||
|
|
||||||
PhysicsInertiaData pdata = null;
|
PhysicsInertiaData pdata = null;
|
||||||
if (!(primRow["PhysInertia"] is System.DBNull))
|
if (!(primRow["PhysInertia"] is System.DBNull))
|
||||||
|
@ -2215,7 +2222,6 @@ namespace OpenSim.Data.PGSQL
|
||||||
parameters.Add(_Database.CreateParameter("PassTouches", (bool)prim.PassTouches));
|
parameters.Add(_Database.CreateParameter("PassTouches", (bool)prim.PassTouches));
|
||||||
parameters.Add(_Database.CreateParameter("PassCollisions", (bool)prim.PassCollisions));
|
parameters.Add(_Database.CreateParameter("PassCollisions", (bool)prim.PassCollisions));
|
||||||
|
|
||||||
|
|
||||||
if (prim.PassTouches)
|
if (prim.PassTouches)
|
||||||
parameters.Add(_Database.CreateParameter("PassTouches", true));
|
parameters.Add(_Database.CreateParameter("PassTouches", true));
|
||||||
else
|
else
|
||||||
|
@ -2229,12 +2235,16 @@ namespace OpenSim.Data.PGSQL
|
||||||
parameters.Add(_Database.CreateParameter("LinkNumber", prim.LinkNum));
|
parameters.Add(_Database.CreateParameter("LinkNumber", prim.LinkNum));
|
||||||
parameters.Add(_Database.CreateParameter("MediaURL", prim.MediaUrl));
|
parameters.Add(_Database.CreateParameter("MediaURL", prim.MediaUrl));
|
||||||
|
|
||||||
|
if (prim.VehicleParams != null)
|
||||||
|
parameters.Add(_Database.CreateParameter("Vehicle", prim.VehicleParams.ToXml2()));
|
||||||
|
else
|
||||||
|
parameters.Add(_Database.CreateParameter("Vehicle", String.Empty));
|
||||||
|
|
||||||
if (prim.PhysicsInertia != null)
|
if (prim.PhysicsInertia != null)
|
||||||
parameters.Add(_Database.CreateParameter("PhysInertia", prim.PhysicsInertia.ToXml2()));
|
parameters.Add(_Database.CreateParameter("PhysInertia", prim.PhysicsInertia.ToXml2()));
|
||||||
else
|
else
|
||||||
parameters.Add(_Database.CreateParameter("PhysInertia", String.Empty));
|
parameters.Add(_Database.CreateParameter("PhysInertia", String.Empty));
|
||||||
|
|
||||||
|
|
||||||
if (prim.DynAttrs.CountNamespaces > 0)
|
if (prim.DynAttrs.CountNamespaces > 0)
|
||||||
parameters.Add(_Database.CreateParameter("DynAttrs", prim.DynAttrs.ToXml()));
|
parameters.Add(_Database.CreateParameter("DynAttrs", prim.DynAttrs.ToXml()));
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue