aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/PGSQL
diff options
context:
space:
mode:
authorGeir Nøklebye2017-04-13 11:54:25 +0200
committerMichael Cerquoni2017-04-19 14:04:54 -0400
commit28125202cc320dee3f4908f07eb4fbc04a134d6e (patch)
tree0e6dbe3b28da69b865c60d92cfd37fe64680f507 /OpenSim/Data/PGSQL
parentPGSQL: Fixed a failing query in GroupsData for deleting groups messages older... (diff)
downloadopensim-SC_OLD-28125202cc320dee3f4908f07eb4fbc04a134d6e.zip
opensim-SC_OLD-28125202cc320dee3f4908f07eb4fbc04a134d6e.tar.gz
opensim-SC_OLD-28125202cc320dee3f4908f07eb4fbc04a134d6e.tar.bz2
opensim-SC_OLD-28125202cc320dee3f4908f07eb4fbc04a134d6e.tar.xz
update for The new Constant: integer OBJECT_REZZER_KEY = 32 + adding missing support for fields in the prims table.
Signed-off-by: Michael Cerquoni <nebadon2025@gmail.com>
Diffstat (limited to 'OpenSim/Data/PGSQL')
-rwxr-xr-xOpenSim/Data/PGSQL/PGSQLSimulationData.cs33
-rw-r--r--OpenSim/Data/PGSQL/Resources/RegionStore.migrations9
2 files changed, 37 insertions, 5 deletions
diff --git a/OpenSim/Data/PGSQL/PGSQLSimulationData.cs b/OpenSim/Data/PGSQL/PGSQLSimulationData.cs
index 33d12bd..3e08dd6 100755
--- a/OpenSim/Data/PGSQL/PGSQLSimulationData.cs
+++ b/OpenSim/Data/PGSQL/PGSQLSimulationData.cs
@@ -350,7 +350,8 @@ namespace OpenSim.Data.PGSQL
350 ""CameraEyeOffsetY"" = :CameraEyeOffsetY, ""CameraEyeOffsetZ"" = :CameraEyeOffsetZ, ""CameraAtOffsetX"" = :CameraAtOffsetX, 350 ""CameraEyeOffsetY"" = :CameraEyeOffsetY, ""CameraEyeOffsetZ"" = :CameraEyeOffsetZ, ""CameraAtOffsetX"" = :CameraAtOffsetX,
351 ""CameraAtOffsetY"" = :CameraAtOffsetY, ""CameraAtOffsetZ"" = :CameraAtOffsetZ, ""ForceMouselook"" = :ForceMouselook, 351 ""CameraAtOffsetY"" = :CameraAtOffsetY, ""CameraAtOffsetZ"" = :CameraAtOffsetZ, ""ForceMouselook"" = :ForceMouselook,
352 ""ScriptAccessPin"" = :ScriptAccessPin, ""AllowedDrop"" = :AllowedDrop, ""DieAtEdge"" = :DieAtEdge, ""SalePrice"" = :SalePrice, 352 ""ScriptAccessPin"" = :ScriptAccessPin, ""AllowedDrop"" = :AllowedDrop, ""DieAtEdge"" = :DieAtEdge, ""SalePrice"" = :SalePrice,
353 ""SaleType"" = :SaleType, ""ColorR"" = :ColorR, ""ColorG"" = :ColorG, ""ColorB"" = :ColorB, ""ColorA"" = :ColorA, ""ParticleSystem"" = :ParticleSystem, 353 ""PhysicsShapeType"" = :PhysicsShapeType, ""Density"" = :Density, ""GravityModifier"" = :GravityModifier, ""Friction"" = :Friction, ""Restitution"" = :Restitution,
354+ ""PassCollisions"" = :PassCollisions, ""RotationAxisLocks"" = :RotationAxisLocks, ""RezzerID"" = :RezzerID
354 ""ClickAction"" = :ClickAction, ""Material"" = :Material, ""CollisionSound"" = :CollisionSound, ""CollisionSoundVolume"" = :CollisionSoundVolume, ""PassTouches"" = :PassTouches, 355 ""ClickAction"" = :ClickAction, ""Material"" = :Material, ""CollisionSound"" = :CollisionSound, ""CollisionSoundVolume"" = :CollisionSoundVolume, ""PassTouches"" = :PassTouches,
355 ""LinkNumber"" = :LinkNumber, ""MediaURL"" = :MediaURL, ""DynAttrs"" = :DynAttrs, 356 ""LinkNumber"" = :LinkNumber, ""MediaURL"" = :MediaURL, ""DynAttrs"" = :DynAttrs,
356 ""PhysicsShapeType"" = :PhysicsShapeType, ""Density"" = :Density, ""GravityModifier"" = :GravityModifier, ""Friction"" = :Friction, ""Restitution"" = :Restitution 357 ""PhysicsShapeType"" = :PhysicsShapeType, ""Density"" = :Density, ""GravityModifier"" = :GravityModifier, ""Friction"" = :Friction, ""Restitution"" = :Restitution
@@ -367,7 +368,7 @@ namespace OpenSim.Data.PGSQL
367 ""OmegaY"", ""OmegaZ"", ""CameraEyeOffsetX"", ""CameraEyeOffsetY"", ""CameraEyeOffsetZ"", ""CameraAtOffsetX"", ""CameraAtOffsetY"", ""CameraAtOffsetZ"", 368 ""OmegaY"", ""OmegaZ"", ""CameraEyeOffsetX"", ""CameraEyeOffsetY"", ""CameraEyeOffsetZ"", ""CameraAtOffsetX"", ""CameraAtOffsetY"", ""CameraAtOffsetZ"",
368 ""ForceMouselook"", ""ScriptAccessPin"", ""AllowedDrop"", ""DieAtEdge"", ""SalePrice"", ""SaleType"", ""ColorR"", ""ColorG"", ""ColorB"", ""ColorA"", 369 ""ForceMouselook"", ""ScriptAccessPin"", ""AllowedDrop"", ""DieAtEdge"", ""SalePrice"", ""SaleType"", ""ColorR"", ""ColorG"", ""ColorB"", ""ColorA"",
369 ""ParticleSystem"", ""ClickAction"", ""Material"", ""CollisionSound"", ""CollisionSoundVolume"", ""PassTouches"", ""LinkNumber"", ""MediaURL"", ""DynAttrs"", 370 ""ParticleSystem"", ""ClickAction"", ""Material"", ""CollisionSound"", ""CollisionSoundVolume"", ""PassTouches"", ""LinkNumber"", ""MediaURL"", ""DynAttrs"",
370 ""PhysicsShapeType"", ""Density"", ""GravityModifier"", ""Friction"", ""Restitution"" 371 ""PhysicsShapeType"", ""Density"", ""GravityModifier"", ""Friction"", ""Restitution"", ""PassCollisions"", ""RotationAxisLocks"", ""RezzerID""
371 ) Select 372 ) Select
372 :UUID, :CreationDate, :Name, :Text, :Description, :SitName, :TouchName, :ObjectFlags, :OwnerMask, :NextOwnerMask, :GroupMask, 373 :UUID, :CreationDate, :Name, :Text, :Description, :SitName, :TouchName, :ObjectFlags, :OwnerMask, :NextOwnerMask, :GroupMask,
373 :EveryoneMask, :BaseMask, :PositionX, :PositionY, :PositionZ, :GroupPositionX, :GroupPositionY, :GroupPositionZ, :VelocityX, 374 :EveryoneMask, :BaseMask, :PositionX, :PositionY, :PositionZ, :GroupPositionX, :GroupPositionY, :GroupPositionZ, :VelocityX,
@@ -378,7 +379,7 @@ namespace OpenSim.Data.PGSQL
378 :OmegaY, :OmegaZ, :CameraEyeOffsetX, :CameraEyeOffsetY, :CameraEyeOffsetZ, :CameraAtOffsetX, :CameraAtOffsetY, :CameraAtOffsetZ, 379 :OmegaY, :OmegaZ, :CameraEyeOffsetX, :CameraEyeOffsetY, :CameraEyeOffsetZ, :CameraAtOffsetX, :CameraAtOffsetY, :CameraAtOffsetZ,
379 :ForceMouselook, :ScriptAccessPin, :AllowedDrop, :DieAtEdge, :SalePrice, :SaleType, :ColorR, :ColorG, :ColorB, :ColorA, 380 :ForceMouselook, :ScriptAccessPin, :AllowedDrop, :DieAtEdge, :SalePrice, :SaleType, :ColorR, :ColorG, :ColorB, :ColorA,
380 :ParticleSystem, :ClickAction, :Material, :CollisionSound, :CollisionSoundVolume, :PassTouches, :LinkNumber, :MediaURL, :DynAttrs, 381 :ParticleSystem, :ClickAction, :Material, :CollisionSound, :CollisionSoundVolume, :PassTouches, :LinkNumber, :MediaURL, :DynAttrs,
381 :PhysicsShapeType, :Density, :GravityModifier, :Friction, :Restitution 382 :PhysicsShapeType, :Density, :GravityModifier, :Friction, :Restitution, :PassCollisions, :RotationAxisLocks, :RezzerID
382 where not EXISTS (SELECT ""UUID"" FROM prims WHERE ""UUID"" = :UUID); 383 where not EXISTS (SELECT ""UUID"" FROM prims WHERE ""UUID"" = :UUID);
383 "; 384 ";
384 385
@@ -1678,6 +1679,12 @@ namespace OpenSim.Data.PGSQL
1678 prim.OwnerID = new UUID((Guid)primRow["OwnerID"]); 1679 prim.OwnerID = new UUID((Guid)primRow["OwnerID"]);
1679 prim.GroupID = new UUID((Guid)primRow["GroupID"]); 1680 prim.GroupID = new UUID((Guid)primRow["GroupID"]);
1680 prim.LastOwnerID = new UUID((Guid)primRow["LastOwnerID"]); 1681 prim.LastOwnerID = new UUID((Guid)primRow["LastOwnerID"]);
1682
1683 if (primRow["RezzerID"] != DBNull.Value)
1684 prim.RezzerID = new UUID((Guid)primRow["RezzerID"]);
1685 else
1686 prim.RezzerID = UUID.Zero;
1687
1681 prim.OwnerMask = Convert.ToUInt32(primRow["OwnerMask"]); 1688 prim.OwnerMask = Convert.ToUInt32(primRow["OwnerMask"]);
1682 prim.NextOwnerMask = Convert.ToUInt32(primRow["NextOwnerMask"]); 1689 prim.NextOwnerMask = Convert.ToUInt32(primRow["NextOwnerMask"]);
1683 prim.GroupMask = Convert.ToUInt32(primRow["GroupMask"]); 1690 prim.GroupMask = Convert.ToUInt32(primRow["GroupMask"]);
@@ -1796,6 +1803,8 @@ namespace OpenSim.Data.PGSQL
1796 prim.GravityModifier = Convert.ToSingle(primRow["GravityModifier"]); 1803 prim.GravityModifier = Convert.ToSingle(primRow["GravityModifier"]);
1797 prim.Friction = Convert.ToSingle(primRow["Friction"]); 1804 prim.Friction = Convert.ToSingle(primRow["Friction"]);
1798 prim.Restitution = Convert.ToSingle(primRow["Restitution"]); 1805 prim.Restitution = Convert.ToSingle(primRow["Restitution"]);
1806 prim.RotationAxisLocks = Convert.ToByte(primRow["RotationAxisLocks"]);
1807
1799 1808
1800 return prim; 1809 return prim;
1801 } 1810 }
@@ -2097,6 +2106,7 @@ namespace OpenSim.Data.PGSQL
2097 parameters.Add(_Database.CreateParameter("OwnerID", prim.OwnerID)); 2106 parameters.Add(_Database.CreateParameter("OwnerID", prim.OwnerID));
2098 parameters.Add(_Database.CreateParameter("GroupID", prim.GroupID)); 2107 parameters.Add(_Database.CreateParameter("GroupID", prim.GroupID));
2099 parameters.Add(_Database.CreateParameter("LastOwnerID", prim.LastOwnerID)); 2108 parameters.Add(_Database.CreateParameter("LastOwnerID", prim.LastOwnerID));
2109 parameters.Add(_Database.CreateParameter("RezzerID", prim.RezzerID));
2100 parameters.Add(_Database.CreateParameter("OwnerMask", prim.OwnerMask)); 2110 parameters.Add(_Database.CreateParameter("OwnerMask", prim.OwnerMask));
2101 parameters.Add(_Database.CreateParameter("NextOwnerMask", prim.NextOwnerMask)); 2111 parameters.Add(_Database.CreateParameter("NextOwnerMask", prim.NextOwnerMask));
2102 parameters.Add(_Database.CreateParameter("GroupMask", prim.GroupMask)); 2112 parameters.Add(_Database.CreateParameter("GroupMask", prim.GroupMask));
@@ -2196,7 +2206,19 @@ namespace OpenSim.Data.PGSQL
2196 parameters.Add(_Database.CreateParameter("CollisionSound", prim.CollisionSound)); 2206 parameters.Add(_Database.CreateParameter("CollisionSound", prim.CollisionSound));
2197 parameters.Add(_Database.CreateParameter("CollisionSoundVolume", prim.CollisionSoundVolume)); 2207 parameters.Add(_Database.CreateParameter("CollisionSoundVolume", prim.CollisionSoundVolume));
2198 2208
2199 parameters.Add(_Database.CreateParameter("PassTouches", prim.PassTouches)); 2209 parameters.Add(_Database.CreateParameter("PassTouches", (bool)prim.PassTouches));
2210 parameters.Add(_Database.CreateParameter("PassCollisions", prim.PassCollisions));
2211
2212
2213 if (prim.PassTouches)
2214 parameters.Add(_Database.CreateParameter("PassTouches", true));
2215 else
2216 parameters.Add(_Database.CreateParameter("PassTouches", false));
2217
2218 if (prim.PassCollisions)
2219 parameters.Add(_Database.CreateParameter("PassCollisions", 1));
2220 else
2221 parameters.Add(_Database.CreateParameter("PassCollisions", 0));
2200 2222
2201 parameters.Add(_Database.CreateParameter("LinkNumber", prim.LinkNum)); 2223 parameters.Add(_Database.CreateParameter("LinkNumber", prim.LinkNum));
2202 parameters.Add(_Database.CreateParameter("MediaURL", prim.MediaUrl)); 2224 parameters.Add(_Database.CreateParameter("MediaURL", prim.MediaUrl));
@@ -2211,12 +2233,13 @@ namespace OpenSim.Data.PGSQL
2211 parameters.Add(_Database.CreateParameter("GravityModifier", (double)prim.GravityModifier)); 2233 parameters.Add(_Database.CreateParameter("GravityModifier", (double)prim.GravityModifier));
2212 parameters.Add(_Database.CreateParameter("Friction", (double)prim.Friction)); 2234 parameters.Add(_Database.CreateParameter("Friction", (double)prim.Friction));
2213 parameters.Add(_Database.CreateParameter("Restitution", (double)prim.Restitution)); 2235 parameters.Add(_Database.CreateParameter("Restitution", (double)prim.Restitution));
2236 parameters.Add(_Database.CreateParameter("RotationAxisLocks", prim.RotationAxisLocks));
2214 2237
2215 return parameters.ToArray(); 2238 return parameters.ToArray();
2216 } 2239 }
2217 2240
2218 /// <summary> 2241 /// <summary>
2219 /// Creates the primshape parameters for stroing in DB. 2242 /// Creates the primshape parameters for storing in DB.
2220 /// </summary> 2243 /// </summary>
2221 /// <param name="prim">Basic data of SceneObjectpart prim.</param> 2244 /// <param name="prim">Basic data of SceneObjectpart prim.</param>
2222 /// <param name="sceneGroupID">The scene group ID.</param> 2245 /// <param name="sceneGroupID">The scene group ID.</param>
diff --git a/OpenSim/Data/PGSQL/Resources/RegionStore.migrations b/OpenSim/Data/PGSQL/Resources/RegionStore.migrations
index c085939..2f197bf 100644
--- a/OpenSim/Data/PGSQL/Resources/RegionStore.migrations
+++ b/OpenSim/Data/PGSQL/Resources/RegionStore.migrations
@@ -1195,3 +1195,12 @@ CREATE TABLE bakedterrain
1195 ); 1195 );
1196 1196
1197COMMIT; 1197COMMIT;
1198
1199:VERSION 45 #---- Add RezzerID filed in table prims
1200
1201BEGIN TRANSACTION;
1202
1203ALTER TABLE prims ADD "RezzerID" uuid NULL;
1204
1205COMMIT;
1206