From ec5f96b272d6a8bbde4d44657e5868f09e33d2e1 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Tue, 29 Jul 2014 05:53:40 +0200 Subject: Persist new land fields for access control --- OpenSim/Data/MySQL/MySQLSimulationData.cs | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'OpenSim/Data/MySQL/MySQLSimulationData.cs') diff --git a/OpenSim/Data/MySQL/MySQLSimulationData.cs b/OpenSim/Data/MySQL/MySQLSimulationData.cs index 1b3e81e..f743663 100644 --- a/OpenSim/Data/MySQL/MySQLSimulationData.cs +++ b/OpenSim/Data/MySQL/MySQLSimulationData.cs @@ -706,7 +706,8 @@ namespace OpenSim.Data.MySQL "UserLocationX, UserLocationY, UserLocationZ, " + "UserLookAtX, UserLookAtY, UserLookAtZ, " + "AuthbuyerID, OtherCleanTime, MediaType, MediaDescription, " + - "MediaSize, MediaLoop, ObscureMusic, ObscureMedia) values (" + + "MediaSize, MediaLoop, ObscureMusic, ObscureMedia, " + + "SeeAVs, AnyAVSounds, GroupAVSounds) values (" + "?UUID, ?RegionUUID, " + "?LocalLandID, ?Bitmap, ?Name, ?Description, " + "?OwnerUUID, ?IsGroupOwned, ?Area, ?AuctionID, " + @@ -717,7 +718,8 @@ namespace OpenSim.Data.MySQL "?UserLocationX, ?UserLocationY, ?UserLocationZ, " + "?UserLookAtX, ?UserLookAtY, ?UserLookAtZ, " + "?AuthbuyerID, ?OtherCleanTime, ?MediaType, ?MediaDescription, "+ - "CONCAT(?MediaWidth, ',', ?MediaHeight), ?MediaLoop, ?ObscureMusic, ?ObscureMedia)"; + "CONCAT(?MediaWidth, ',', ?MediaHeight), ?MediaLoop, ?ObscureMusic, ?ObscureMedia, " + + "?SeeAVs, ?AnyAVSounds, ?GroupAVSounds)"; FillLandCommand(cmd, parcel.LandData, parcel.RegionUUID); @@ -1544,6 +1546,13 @@ namespace OpenSim.Data.MySQL newData.ParcelAccessList = new List(); + if (!(row["SeeAVs"] is System.DBNull)) + newData.SeeAVs = Convert.ToInt32(row["SeeAVs"]) != 0 ? true : false; + if (!(row["AnyAVSounds"] is System.DBNull)) + newData.AnyAVSounds = Convert.ToInt32(row["AnyAVSounds"]) != 0 ? true : false; + if (!(row["GroupAVSounds"] is System.DBNull)) + newData.GroupAVSounds = Convert.ToInt32(row["GroupAVSounds"]) != 0 ? true : false; + return newData; } @@ -1893,6 +1902,9 @@ namespace OpenSim.Data.MySQL cmd.Parameters.AddWithValue("MediaLoop", land.MediaLoop); cmd.Parameters.AddWithValue("ObscureMusic", land.ObscureMusic); cmd.Parameters.AddWithValue("ObscureMedia", land.ObscureMedia); + cmd.Parameters.AddWithValue("SeeAVs", land.SeeAVs ? 1 : 0); + cmd.Parameters.AddWithValue("AnyAVSounds", land.AnyAVSounds ? 1 : 0); + cmd.Parameters.AddWithValue("GroupAVSounds", land.GroupAVSounds ? 1 : 0); } -- cgit v1.1