Skip to content

Commit

Permalink
Merge branch 'release/opensim-rel-0.9.2.2.8738'
Browse files Browse the repository at this point in the history
  • Loading branch information
mdickson committed Dec 5, 2023
2 parents f2c214a + 9ff674b commit 0accd42
Show file tree
Hide file tree
Showing 30 changed files with 1,284 additions and 79 deletions.
22 changes: 19 additions & 3 deletions OpenSim/Data/MySQL/MySQLSimulationData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,8 @@ public virtual void StoreObject(SceneObjectGroup obj, UUID regionUUID)
"AttachedPosY, AttachedPosZ, " +
"PhysicsShapeType, Density, GravityModifier, " +
"Friction, Restitution, Vehicle, PhysInertia, DynAttrs, " +
"RotationAxisLocks, sopanims, sitactrange, pseudocrc" +
"RotationAxisLocks, sopanims, sitactrange, pseudocrc, " +
"linksetdata" +
") values (" + "?UUID, " +
"?CreationDate, ?Name, ?Text, " +
"?Description, ?SitName, ?TouchName, " +
Expand Down Expand Up @@ -216,7 +217,8 @@ public virtual void StoreObject(SceneObjectGroup obj, UUID regionUUID)
"?AttachedPosY, ?AttachedPosZ, " +
"?PhysicsShapeType, ?Density, ?GravityModifier, " +
"?Friction, ?Restitution, ?Vehicle, ?PhysInertia, ?DynAttrs," +
"?RotationAxisLocks, ?sopanims, ?sitactrange, ?pseudocrc)";
"?RotationAxisLocks, ?sopanims, ?sitactrange, ?pseudocrc, " +
"?linksetdata)";

FillPrimCommand(cmd, prim, obj.UUID, regionUUID);

Expand Down Expand Up @@ -1202,6 +1204,11 @@ private SceneObjectPart BuildPrim(IDataReader row)
if(pseudocrc != 0)
prim.PseudoCRC = pseudocrc;

if (!(row["linksetdata"] is DBNull))
{
prim.DeserializeLinksetData((string)row["linksetdata"]);
}

return prim;
}

Expand Down Expand Up @@ -1613,13 +1620,22 @@ private void FillPrimCommand(MySqlCommand cmd, SceneObjectPart prim, UUID sceneG
cmd.Parameters.AddWithValue("Restitution", prim.Restitution);
cmd.Parameters.AddWithValue("RotationAxisLocks", prim.RotationAxisLocks);

if (prim.Animations!= null)
if (prim.Animations != null)
cmd.Parameters.AddWithValue("sopanims", prim.SerializeAnimations());
else
cmd.Parameters.AddWithValue("sopanims", null);

cmd.Parameters.AddWithValue("sitactrange", prim.SitActiveRange);
cmd.Parameters.AddWithValue("pseudocrc", prim.PseudoCRC);

if (prim.LinksetData != null)
{
cmd.Parameters.AddWithValue("linksetdata", prim.SerializeLinksetData());
}
else
{
cmd.Parameters.AddWithValue("linksetdata", null);
}
}

/// <summary>
Expand Down
2 changes: 1 addition & 1 deletion OpenSim/Data/MySQL/OpenSim.Data.MySQL.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
<EmbeddedResource Include="Resources\os_groups_Store.migrations" />
<EmbeddedResource Include="Resources\Presence.migrations" />
<EmbeddedResource Include="Resources\RegionStore.migrations" />
<EmbeddedResource Include="Resources\UserAlias.migrations" />
<EmbeddedResource Include="Resources\UserAlias.migrations" />
<EmbeddedResource Include="Resources\UserAccount.migrations" />
<EmbeddedResource Include="Resources\UserProfiles.migrations" />
<EmbeddedResource Include="Resources\XAssetStore.migrations" />
Expand Down
8 changes: 8 additions & 0 deletions OpenSim/Data/MySQL/Resources/RegionStore.migrations
Original file line number Diff line number Diff line change
Expand Up @@ -550,3 +550,11 @@ BEGIN;
ALTER TABLE `land` ADD COLUMN `environment` MEDIUMTEXT default NULL;
COMMIT;

:VERSION 64 #----- material overrides
ALTER TABLE `primshapes` ADD COLUMN `MatOvrd` blob default NULL;
COMMIT;

:VERSION 65 #----- add linkset data storage column
BEGIN;
ALTER TABLE `prims` ADD COLUMN `linksetdata` MEDIUMTEXT default NULL;
COMMIT;
2 changes: 1 addition & 1 deletion OpenSim/Data/OpenSim.Data.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
<Compile Remove="MySQL\MySQLRegionData.cs" />
<Compile Remove="MySQL\MySQLSimulationData.cs" />
<Compile Remove="MySQL\MySQLUserAccountData.cs" />
<Compile Remove="MySQL\MySQLUserAliasData.cs" />
<Compile Remove="MySQL\MySQLUserAliasData.cs" />
<Compile Remove="MySQL\MySQLUserProfilesData.cs" />
<Compile Remove="MySQL\MySQLXAssetData.cs" />
<Compile Remove="MySQL\MySQLXInventoryData.cs" />
Expand Down
17 changes: 12 additions & 5 deletions OpenSim/Data/PGSQL/PGSQLSimulationData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -355,9 +355,9 @@ UPDATE prims SET
""ClickAction"" = :ClickAction, ""Material"" = :Material, ""CollisionSound"" = :CollisionSound, ""CollisionSoundVolume"" = :CollisionSoundVolume, ""PassTouches"" = :PassTouches,
""LinkNumber"" = :LinkNumber, ""MediaURL"" = :MediaURL, ""DynAttrs"" = :DynAttrs, ""Vehicle"" = :Vehicle,
""PhysInertia"" = :PhysInertia, ""standtargetx"" =:standtargetx, ""standtargety"" =:standtargety, ""standtargetz"" =:standtargetz,
""sitactrange"" =:sitactrange, ""pseudocrc"" = :pseudocrc, ""sopanims"" = :sopanims
WHERE ""UUID"" = :UUID ;
""sitactrange"" =:sitactrange, ""pseudocrc"" = :pseudocrc, ""sopanims"" = :sopanims,
""linksetdata"" =:linksetdata
WHERE ""UUID"" = :UUID ;
INSERT INTO
prims (
Expand All @@ -371,7 +371,7 @@ INSERT INTO
""ForceMouselook"", ""ScriptAccessPin"", ""AllowedDrop"", ""DieAtEdge"", ""SalePrice"", ""SaleType"", ""ColorR"", ""ColorG"", ""ColorB"", ""ColorA"",
""ParticleSystem"", ""ClickAction"", ""Material"", ""CollisionSound"", ""CollisionSoundVolume"", ""PassTouches"", ""LinkNumber"", ""MediaURL"", ""DynAttrs"",
""PhysicsShapeType"", ""Density"", ""GravityModifier"", ""Friction"", ""Restitution"", ""PassCollisions"", ""RotationAxisLocks"", ""RezzerID"" , ""Vehicle"", ""PhysInertia"",
""standtargetx"", ""standtargety"", ""standtargetz"", ""sitactrange"", ""pseudocrc"", ""sopanims""
""standtargetx"", ""standtargety"", ""standtargetz"", ""sitactrange"", ""pseudocrc"", ""sopanims"", ""linksetdata""
) Select
:UUID, :CreationDate, :Name, :Text, :Description, :SitName, :TouchName, :ObjectFlags, :OwnerMask, :NextOwnerMask, :GroupMask,
:EveryoneMask, :BaseMask, :PositionX, :PositionY, :PositionZ, :GroupPositionX, :GroupPositionY, :GroupPositionZ, :VelocityX,
Expand All @@ -383,7 +383,7 @@ INSERT INTO
:ForceMouselook, :ScriptAccessPin, :AllowedDrop, :DieAtEdge, :SalePrice, :SaleType, :ColorR, :ColorG, :ColorB, :ColorA,
:ParticleSystem, :ClickAction, :Material, :CollisionSound, :CollisionSoundVolume, :PassTouches, :LinkNumber, :MediaURL, :DynAttrs,
:PhysicsShapeType, :Density, :GravityModifier, :Friction, :Restitution, :PassCollisions, :RotationAxisLocks, :RezzerID, :Vehicle, :PhysInertia,
:standtargetx, :standtargety, :standtargetz,:sitactrange, :pseudocrc, :sopanims
:standtargetx, :standtargety, :standtargetz,:sitactrange, :pseudocrc, :sopanims, :LinksetData
where not EXISTS (SELECT ""UUID"" FROM prims WHERE ""UUID"" = :UUID);
";

Expand Down Expand Up @@ -1406,6 +1406,11 @@ private static SceneObjectPart BuildPrim(IDataRecord primRow)
prim.Animations = null;
}

if ((primRow["LinksetData"] is DBNull) == false)
{
prim.DeserializeLinksetData(((string)primRow["linksetdata"]));
}

return prim;
}

Expand Down Expand Up @@ -1870,6 +1875,8 @@ private NpgsqlParameter[] CreatePrimParameters(SceneObjectPart prim, UUID sceneG
else
parameters.Add(_Database.CreateParameter("sopanims", null));

parameters.Add(_Database.CreateParameter("linksetdata", prim.SerializeLinksetData()));

return parameters.ToArray();
}

Expand Down
5 changes: 5 additions & 0 deletions OpenSim/Data/PGSQL/Resources/RegionStore.migrations
Original file line number Diff line number Diff line change
Expand Up @@ -1261,3 +1261,8 @@ BEGIN;
ALTER TABLE `prims` ADD COLUMN `sopanims` bytea NULL;
ALTER TABLE `primshapes` ADD COLUMN `MatOvrd` bytea NULL;
COMMIT;

:VERSION 53 #----- add linkset data storage column
BEGIN;
ALTER TABLE `prims` ADD COLUMN `linksetdata` varchar default NULL;
COMMIT;
5 changes: 5 additions & 0 deletions OpenSim/Data/SQLite/Resources/RegionStore.migrations
Original file line number Diff line number Diff line change
Expand Up @@ -406,3 +406,8 @@ BEGIN;
ALTER TABLE `prims` ADD COLUMN `sopanims` blob default NULL;
ALTER TABLE `primshapes` ADD COLUMN `MatOvrd` blob default NULL;
COMMIT;

:VERSION 41 #----- add linkset data storage column
BEGIN;
ALTER TABLE `prims` ADD COLUMN `linksetdata` TEXT default NULL;
COMMIT;
9 changes: 9 additions & 0 deletions OpenSim/Data/SQLite/SQLiteSimulationData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1251,6 +1251,8 @@ private static DataTable createPrimTable()
createCol(prims, "pseudocrc", typeof(int));
createCol(prims, "sopanims", typeof(byte[]));

createCol(prims, "linksetdata", typeof(string));

// Add in contraints
prims.PrimaryKey = new DataColumn[] { prims.Columns["UUID"] };

Expand Down Expand Up @@ -1810,6 +1812,11 @@ private SceneObjectPart buildPrim(DataRow row)
prim.Animations = null;
}

if (!(row["linksetdata"] is DBNull))
{
prim.DeserializeLinksetData((string)row["LinksetData"]);
}

return prim;
}

Expand Down Expand Up @@ -2199,6 +2206,8 @@ private static void fillPrimRow(DataRow row, SceneObjectPart prim, UUID sceneGro

row["pseudocrc"] = prim.PseudoCRC;
row["sopanims"] = prim.SerializeAnimations();

row["linksetdata"] = prim.SerializeLinksetData();
}

/// <summary>
Expand Down
22 changes: 4 additions & 18 deletions OpenSim/Framework/VersionInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,30 +39,16 @@ public class VersionInfo
{
public const string VersionNumber = "0.9.2.2";
public const string AssemblyVersionNumber = "0.9.2.2";
public const string Release = "8619";

public const Flavour VERSION_FLAVOUR = Flavour.Dev;

public enum Flavour
{
Unknown,
Dev,
RC1,
RC2,
RC3,
Release,
Post_Fixes,
Extended
}
public const string Release = "8738";

public static string Version
{
get { return GetVersionString(VersionNumber, Release, VERSION_FLAVOUR); }
get { return GetVersionString(VersionNumber, Release); }
}

public static string GetVersionString(string versionNumber, string release, Flavour flavour)
public static string GetVersionString(string versionNumber, string release)
{
string versionString = "OpenSim-NGC " + versionNumber + "." + release + " Yeti " + flavour;
string versionString = "OpenSim-NGC Tranquillity " + versionNumber + "." + release;
return versionString.PadRight(VERSIONINFO_VERSION_LENGTH);
}

Expand Down
20 changes: 3 additions & 17 deletions OpenSim/Framework/VersionInfo.tt
Original file line number Diff line number Diff line change
Expand Up @@ -41,28 +41,14 @@ namespace OpenSim
public const string AssemblyVersionNumber = "0.9.2.2";
public const string Release = "<#= (int)DateTimeOffset.UtcNow.Subtract(new DateTimeOffset(2000, 1, 1, 0, 0, 0, TimeSpan.Zero)).TotalDays #>";

public const Flavour VERSION_FLAVOUR = Flavour.Dev;

public enum Flavour
{
Unknown,
Dev,
RC1,
RC2,
RC3,
Release,
Post_Fixes,
Extended
}

public static string Version
{
get { return GetVersionString(VersionNumber, Release, VERSION_FLAVOUR); }
get { return GetVersionString(VersionNumber, Release); }
}

public static string GetVersionString(string versionNumber, string release, Flavour flavour)
public static string GetVersionString(string versionNumber, string release)
{
string versionString = "OpenSim-NGC " + versionNumber + "." + release + " Yeti " + flavour;
string versionString = "OpenSim-NGC Tranquillity " + versionNumber + "." + release;
return versionString.PadRight(VERSIONINFO_VERSION_LENGTH);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,8 @@
<Compile Remove="Scenes\EventManager.cs" />
<Compile Remove="Scenes\GodController.cs" />
<Compile Remove="Scenes\KeyframeMotion.cs" />
<Compile Remove="Scenes\LinksetData.cs" />
<Compile Remove="Scenes\LinksetDataEntry.cs" />
<Compile Remove="Scenes\Prioritizer.cs" />
<Compile Remove="Scenes\PriorityQueue.cs" />
<Compile Remove="Scenes\RegionStatsHandler.cs" />
Expand Down
1 change: 1 addition & 0 deletions OpenSim/Region/Framework/OpenSim.Region.Framework.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -82,5 +82,6 @@
<PackageReference Include="log4net" Version="2.0.15" />
<PackageReference Include="Mono.Addins" Version="1.4.1" />
<PackageReference Include="System.Drawing.Common" Version="6.0.0" />
<PackageReference Include="System.Text.Json" Version="6.0.9" />
</ItemGroup>
</Project>
Loading

0 comments on commit 0accd42

Please sign in to comment.