store the new variables on sqlite and pgsql ( could not test)
parent
2a38210fe9
commit
f61b83b1ea
|
@ -354,7 +354,9 @@ namespace OpenSim.Data.PGSQL
|
||||||
""PassCollisions"" = :PassCollisions, ""RotationAxisLocks"" = :RotationAxisLocks, ""RezzerID"" = :RezzerID,
|
""PassCollisions"" = :PassCollisions, ""RotationAxisLocks"" = :RotationAxisLocks, ""RezzerID"" = :RezzerID,
|
||||||
""ClickAction"" = :ClickAction, ""Material"" = :Material, ""CollisionSound"" = :CollisionSound, ""CollisionSoundVolume"" = :CollisionSoundVolume, ""PassTouches"" = :PassTouches,
|
""ClickAction"" = :ClickAction, ""Material"" = :Material, ""CollisionSound"" = :CollisionSound, ""CollisionSoundVolume"" = :CollisionSoundVolume, ""PassTouches"" = :PassTouches,
|
||||||
""LinkNumber"" = :LinkNumber, ""MediaURL"" = :MediaURL, ""DynAttrs"" = :DynAttrs, ""Vehicle"" = :Vehicle,
|
""LinkNumber"" = :LinkNumber, ""MediaURL"" = :MediaURL, ""DynAttrs"" = :DynAttrs, ""Vehicle"" = :Vehicle,
|
||||||
""PhysInertia"" = :PhysInertia
|
""PhysInertia"" = :PhysInertia, ""standtargetx"" =:standtargetx, ""standtargety"" =:standtargety, ""standtargetz"" =:standtargetz,
|
||||||
|
""sitactrange"" =:sitactrange
|
||||||
|
|
||||||
WHERE ""UUID"" = :UUID ;
|
WHERE ""UUID"" = :UUID ;
|
||||||
|
|
||||||
INSERT INTO
|
INSERT INTO
|
||||||
|
@ -368,7 +370,8 @@ namespace OpenSim.Data.PGSQL
|
||||||
""OmegaY"", ""OmegaZ"", ""CameraEyeOffsetX"", ""CameraEyeOffsetY"", ""CameraEyeOffsetZ"", ""CameraAtOffsetX"", ""CameraAtOffsetY"", ""CameraAtOffsetZ"",
|
""OmegaY"", ""OmegaZ"", ""CameraEyeOffsetX"", ""CameraEyeOffsetY"", ""CameraEyeOffsetZ"", ""CameraAtOffsetX"", ""CameraAtOffsetY"", ""CameraAtOffsetZ"",
|
||||||
""ForceMouselook"", ""ScriptAccessPin"", ""AllowedDrop"", ""DieAtEdge"", ""SalePrice"", ""SaleType"", ""ColorR"", ""ColorG"", ""ColorB"", ""ColorA"",
|
""ForceMouselook"", ""ScriptAccessPin"", ""AllowedDrop"", ""DieAtEdge"", ""SalePrice"", ""SaleType"", ""ColorR"", ""ColorG"", ""ColorB"", ""ColorA"",
|
||||||
""ParticleSystem"", ""ClickAction"", ""Material"", ""CollisionSound"", ""CollisionSoundVolume"", ""PassTouches"", ""LinkNumber"", ""MediaURL"", ""DynAttrs"",
|
""ParticleSystem"", ""ClickAction"", ""Material"", ""CollisionSound"", ""CollisionSoundVolume"", ""PassTouches"", ""LinkNumber"", ""MediaURL"", ""DynAttrs"",
|
||||||
""PhysicsShapeType"", ""Density"", ""GravityModifier"", ""Friction"", ""Restitution"", ""PassCollisions"", ""RotationAxisLocks"", ""RezzerID"" , ""Vehicle"", ""PhysInertia""
|
""PhysicsShapeType"", ""Density"", ""GravityModifier"", ""Friction"", ""Restitution"", ""PassCollisions"", ""RotationAxisLocks"", ""RezzerID"" , ""Vehicle"", ""PhysInertia"",
|
||||||
|
""standtargetx"", ""standtargety"", ""standtargetz"", ""sitactrange""
|
||||||
) Select
|
) Select
|
||||||
:UUID, :CreationDate, :Name, :Text, :Description, :SitName, :TouchName, :ObjectFlags, :OwnerMask, :NextOwnerMask, :GroupMask,
|
:UUID, :CreationDate, :Name, :Text, :Description, :SitName, :TouchName, :ObjectFlags, :OwnerMask, :NextOwnerMask, :GroupMask,
|
||||||
:EveryoneMask, :BaseMask, :PositionX, :PositionY, :PositionZ, :GroupPositionX, :GroupPositionY, :GroupPositionZ, :VelocityX,
|
:EveryoneMask, :BaseMask, :PositionX, :PositionY, :PositionZ, :GroupPositionX, :GroupPositionY, :GroupPositionZ, :VelocityX,
|
||||||
|
@ -379,7 +382,8 @@ namespace OpenSim.Data.PGSQL
|
||||||
:OmegaY, :OmegaZ, :CameraEyeOffsetX, :CameraEyeOffsetY, :CameraEyeOffsetZ, :CameraAtOffsetX, :CameraAtOffsetY, :CameraAtOffsetZ,
|
:OmegaY, :OmegaZ, :CameraEyeOffsetX, :CameraEyeOffsetY, :CameraEyeOffsetZ, :CameraAtOffsetX, :CameraAtOffsetY, :CameraAtOffsetZ,
|
||||||
:ForceMouselook, :ScriptAccessPin, :AllowedDrop, :DieAtEdge, :SalePrice, :SaleType, :ColorR, :ColorG, :ColorB, :ColorA,
|
:ForceMouselook, :ScriptAccessPin, :AllowedDrop, :DieAtEdge, :SalePrice, :SaleType, :ColorR, :ColorG, :ColorB, :ColorA,
|
||||||
:ParticleSystem, :ClickAction, :Material, :CollisionSound, :CollisionSoundVolume, :PassTouches, :LinkNumber, :MediaURL, :DynAttrs,
|
:ParticleSystem, :ClickAction, :Material, :CollisionSound, :CollisionSoundVolume, :PassTouches, :LinkNumber, :MediaURL, :DynAttrs,
|
||||||
:PhysicsShapeType, :Density, :GravityModifier, :Friction, :Restitution, :PassCollisions, :RotationAxisLocks, :RezzerID, :Vehicle, :PhysInertia
|
:PhysicsShapeType, :Density, :GravityModifier, :Friction, :Restitution, :PassCollisions, :RotationAxisLocks, :RezzerID, :Vehicle, :PhysInertia,
|
||||||
|
:standtargetx, :standtargety, :standtargetz,:sitactrange
|
||||||
where not EXISTS (SELECT ""UUID"" FROM prims WHERE ""UUID"" = :UUID);
|
where not EXISTS (SELECT ""UUID"" FROM prims WHERE ""UUID"" = :UUID);
|
||||||
";
|
";
|
||||||
|
|
||||||
|
@ -1692,9 +1696,9 @@ namespace OpenSim.Data.PGSQL
|
||||||
prim.BaseMask = Convert.ToUInt32(primRow["BaseMask"]);
|
prim.BaseMask = Convert.ToUInt32(primRow["BaseMask"]);
|
||||||
// vectors
|
// vectors
|
||||||
prim.OffsetPosition = new Vector3(
|
prim.OffsetPosition = new Vector3(
|
||||||
Convert.ToSingle(primRow["PositionX"]),
|
Convert.ToSingle(primRow["PositionX"]),
|
||||||
Convert.ToSingle(primRow["PositionY"]),
|
Convert.ToSingle(primRow["PositionY"]),
|
||||||
Convert.ToSingle(primRow["PositionZ"]));
|
Convert.ToSingle(primRow["PositionZ"]));
|
||||||
|
|
||||||
prim.GroupPosition = new Vector3(
|
prim.GroupPosition = new Vector3(
|
||||||
Convert.ToSingle(primRow["GroupPositionX"]),
|
Convert.ToSingle(primRow["GroupPositionX"]),
|
||||||
|
@ -1707,9 +1711,9 @@ namespace OpenSim.Data.PGSQL
|
||||||
Convert.ToSingle(primRow["VelocityZ"]));
|
Convert.ToSingle(primRow["VelocityZ"]));
|
||||||
|
|
||||||
prim.AngularVelocity = new Vector3(
|
prim.AngularVelocity = new Vector3(
|
||||||
Convert.ToSingle(primRow["AngularVelocityX"]),
|
Convert.ToSingle(primRow["AngularVelocityX"]),
|
||||||
Convert.ToSingle(primRow["AngularVelocityY"]),
|
Convert.ToSingle(primRow["AngularVelocityY"]),
|
||||||
Convert.ToSingle(primRow["AngularVelocityZ"]));
|
Convert.ToSingle(primRow["AngularVelocityZ"]));
|
||||||
|
|
||||||
prim.Acceleration = new Vector3(
|
prim.Acceleration = new Vector3(
|
||||||
Convert.ToSingle(primRow["AccelerationX"]),
|
Convert.ToSingle(primRow["AccelerationX"]),
|
||||||
|
@ -1728,12 +1732,20 @@ namespace OpenSim.Data.PGSQL
|
||||||
Convert.ToSingle(primRow["SitTargetOffsetY"]),
|
Convert.ToSingle(primRow["SitTargetOffsetY"]),
|
||||||
Convert.ToSingle(primRow["SitTargetOffsetZ"]));
|
Convert.ToSingle(primRow["SitTargetOffsetZ"]));
|
||||||
|
|
||||||
|
|
||||||
prim.SitTargetOrientationLL = new Quaternion(
|
prim.SitTargetOrientationLL = new Quaternion(
|
||||||
Convert.ToSingle(primRow["SitTargetOrientX"]),
|
Convert.ToSingle(primRow["SitTargetOrientX"]),
|
||||||
Convert.ToSingle(primRow["SitTargetOrientY"]),
|
Convert.ToSingle(primRow["SitTargetOrientY"]),
|
||||||
Convert.ToSingle(primRow["SitTargetOrientZ"]),
|
Convert.ToSingle(primRow["SitTargetOrientZ"]),
|
||||||
Convert.ToSingle(primRow["SitTargetOrientW"]));
|
Convert.ToSingle(primRow["SitTargetOrientW"]));
|
||||||
|
|
||||||
|
prim.StandOffset = new Vector3(
|
||||||
|
Convert.ToSingle(primRow["standtargetx"]),
|
||||||
|
Convert.ToSingle(primRow["standtargety"]),
|
||||||
|
Convert.ToSingle(primRow["standtargetz"]));
|
||||||
|
|
||||||
|
prim.SitActiveRange = Convert.ToSingle(primRow["sitactrange"]);
|
||||||
|
|
||||||
prim.PayPrice[0] = Convert.ToInt32(primRow["PayPrice"]);
|
prim.PayPrice[0] = Convert.ToInt32(primRow["PayPrice"]);
|
||||||
prim.PayPrice[1] = Convert.ToInt32(primRow["PayButton1"]);
|
prim.PayPrice[1] = Convert.ToInt32(primRow["PayButton1"]);
|
||||||
prim.PayPrice[2] = Convert.ToInt32(primRow["PayButton2"]);
|
prim.PayPrice[2] = Convert.ToInt32(primRow["PayButton2"]);
|
||||||
|
@ -2162,6 +2174,13 @@ namespace OpenSim.Data.PGSQL
|
||||||
parameters.Add(_Database.CreateParameter("SitTargetOrientY", sitTargetOrient.Y));
|
parameters.Add(_Database.CreateParameter("SitTargetOrientY", sitTargetOrient.Y));
|
||||||
parameters.Add(_Database.CreateParameter("SitTargetOrientZ", sitTargetOrient.Z));
|
parameters.Add(_Database.CreateParameter("SitTargetOrientZ", sitTargetOrient.Z));
|
||||||
|
|
||||||
|
Vector3 standTargetPos = prim.StandOffset;
|
||||||
|
parameters.Add(_Database.CreateParameter("standtargetx", standTargetPos.X));
|
||||||
|
parameters.Add(_Database.CreateParameter("standtargety", standTargetPos.Y));
|
||||||
|
parameters.Add(_Database.CreateParameter("standtargetz", standTargetPos.Z));
|
||||||
|
|
||||||
|
parameters.Add(_Database.CreateParameter("sitactrange", prim.SitActiveRange));
|
||||||
|
|
||||||
parameters.Add(_Database.CreateParameter("PayPrice", prim.PayPrice[0]));
|
parameters.Add(_Database.CreateParameter("PayPrice", prim.PayPrice[0]));
|
||||||
parameters.Add(_Database.CreateParameter("PayButton1", prim.PayPrice[1]));
|
parameters.Add(_Database.CreateParameter("PayButton1", prim.PayPrice[1]));
|
||||||
parameters.Add(_Database.CreateParameter("PayButton2", prim.PayPrice[2]));
|
parameters.Add(_Database.CreateParameter("PayButton2", prim.PayPrice[2]));
|
||||||
|
|
|
@ -1232,3 +1232,13 @@ BEGIN TRANSACTION;
|
||||||
|
|
||||||
ALTER TABLE prims ADD "Vehicle" TEXT;
|
ALTER TABLE prims ADD "Vehicle" TEXT;
|
||||||
COMMIT;
|
COMMIT;
|
||||||
|
|
||||||
|
:VERSION 48 #----- Add standtarget and sit range
|
||||||
|
|
||||||
|
BEGIN;
|
||||||
|
ALTER TABLE `prims`
|
||||||
|
ADD COLUMN `standtargetx` real DEFAULT '0.0',
|
||||||
|
ADD COLUMN `standtargety` real DEFAULT '0.0',
|
||||||
|
ADD COLUMN `standtargetz` real DEFAULT '0.0',
|
||||||
|
ADD COLUMN `sitactrange` real DEFAULT '0.0';
|
||||||
|
COMMIT;
|
||||||
|
|
|
@ -377,3 +377,13 @@ COMMIT;
|
||||||
BEGIN;
|
BEGIN;
|
||||||
ALTER TABLE `prims` ADD COLUMN `PhysInertia` TEXT default NULL;
|
ALTER TABLE `prims` ADD COLUMN `PhysInertia` TEXT default NULL;
|
||||||
COMMIT;
|
COMMIT;
|
||||||
|
|
||||||
|
:VERSION 37 #----- Add standtarget and sit range
|
||||||
|
|
||||||
|
BEGIN;
|
||||||
|
ALTER TABLE `prims`
|
||||||
|
ADD COLUMN `standtargetx` float NOT NULL DEFAULT '0.0',
|
||||||
|
ADD COLUMN `standtargety` float NOT NULL DEFAULT '0.0',
|
||||||
|
ADD COLUMN `standtargetz` float NOT NULL DEFAULT '0.0',
|
||||||
|
ADD COLUMN `sitactrange` float NOT NULL DEFAULT '0.0';
|
||||||
|
COMMIT;
|
||||||
|
|
|
@ -1060,7 +1060,6 @@ namespace OpenSim.Data.SQLite
|
||||||
for (int iter = 0; iter < rowsToDelete.Count; ++iter)
|
for (int iter = 0; iter < rowsToDelete.Count; ++iter)
|
||||||
rowsToDelete[iter].Delete();
|
rowsToDelete[iter].Delete();
|
||||||
|
|
||||||
|
|
||||||
foreach (LandAccessEntry entry in parcel.LandData.ParcelAccessList)
|
foreach (LandAccessEntry entry in parcel.LandData.ParcelAccessList)
|
||||||
{
|
{
|
||||||
DataRow newAccessRow = landaccesslist.NewRow();
|
DataRow newAccessRow = landaccesslist.NewRow();
|
||||||
|
@ -1722,14 +1721,18 @@ namespace OpenSim.Data.SQLite
|
||||||
Convert.ToSingle(row["SitTargetOffsetY"]),
|
Convert.ToSingle(row["SitTargetOffsetY"]),
|
||||||
Convert.ToSingle(row["SitTargetOffsetZ"]));
|
Convert.ToSingle(row["SitTargetOffsetZ"]));
|
||||||
prim.SitTargetOrientationLL = new Quaternion(
|
prim.SitTargetOrientationLL = new Quaternion(
|
||||||
Convert.ToSingle(
|
Convert.ToSingle(row["SitTargetOrientX"]),
|
||||||
row["SitTargetOrientX"]),
|
Convert.ToSingle(row["SitTargetOrientY"]),
|
||||||
Convert.ToSingle(
|
Convert.ToSingle(row["SitTargetOrientZ"]),
|
||||||
row["SitTargetOrientY"]),
|
Convert.ToSingle(row["SitTargetOrientW"]));
|
||||||
Convert.ToSingle(
|
|
||||||
row["SitTargetOrientZ"]),
|
prim.StandOffset = new Vector3(
|
||||||
Convert.ToSingle(
|
Convert.ToSingle(row["standtargetx"]),
|
||||||
row["SitTargetOrientW"]));
|
Convert.ToSingle(row["standtargety"]),
|
||||||
|
Convert.ToSingle(row["standtargetz"])
|
||||||
|
);
|
||||||
|
|
||||||
|
prim.SitActiveRange = Convert.ToSingle(row["sitactrange"]);
|
||||||
|
|
||||||
prim.ClickAction = Convert.ToByte(row["ClickAction"]);
|
prim.ClickAction = Convert.ToByte(row["ClickAction"]);
|
||||||
prim.PayPrice[0] = Convert.ToInt32(row["PayPrice"]);
|
prim.PayPrice[0] = Convert.ToInt32(row["PayPrice"]);
|
||||||
|
@ -2172,6 +2175,14 @@ namespace OpenSim.Data.SQLite
|
||||||
row["SitTargetOrientX"] = sitTargetOrient.X;
|
row["SitTargetOrientX"] = sitTargetOrient.X;
|
||||||
row["SitTargetOrientY"] = sitTargetOrient.Y;
|
row["SitTargetOrientY"] = sitTargetOrient.Y;
|
||||||
row["SitTargetOrientZ"] = sitTargetOrient.Z;
|
row["SitTargetOrientZ"] = sitTargetOrient.Z;
|
||||||
|
|
||||||
|
Vector3 standTarget = prim.StandOffset;
|
||||||
|
row["standtargetx"] = standTarget.X;
|
||||||
|
row["standtargety"] = standTarget.Y;
|
||||||
|
row["standtargetz"] = standTarget.Z;
|
||||||
|
|
||||||
|
row["sitactrange"] = prim.SitActiveRange;
|
||||||
|
|
||||||
row["ColorR"] = Convert.ToInt32(prim.Color.R);
|
row["ColorR"] = Convert.ToInt32(prim.Color.R);
|
||||||
row["ColorG"] = Convert.ToInt32(prim.Color.G);
|
row["ColorG"] = Convert.ToInt32(prim.Color.G);
|
||||||
row["ColorB"] = Convert.ToInt32(prim.Color.B);
|
row["ColorB"] = Convert.ToInt32(prim.Color.B);
|
||||||
|
@ -2197,7 +2208,6 @@ namespace OpenSim.Data.SQLite
|
||||||
row["CameraAtOffsetY"] = prim.GetCameraAtOffset().Y;
|
row["CameraAtOffsetY"] = prim.GetCameraAtOffset().Y;
|
||||||
row["CameraAtOffsetZ"] = prim.GetCameraAtOffset().Z;
|
row["CameraAtOffsetZ"] = prim.GetCameraAtOffset().Z;
|
||||||
|
|
||||||
|
|
||||||
if ((prim.SoundFlags & 1) != 0) // Looped
|
if ((prim.SoundFlags & 1) != 0) // Looped
|
||||||
{
|
{
|
||||||
row["LoopedSound"] = prim.Sound.ToString();
|
row["LoopedSound"] = prim.Sound.ToString();
|
||||||
|
|
Loading…
Reference in New Issue