aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MySQL/MySQLSimulationData.cs
diff options
context:
space:
mode:
authorMelanie2012-02-02 21:36:45 +0100
committerMelanie2012-02-02 21:36:45 +0100
commit07c487a28f6ce6d85cf32fba0c2ded724f7b5af7 (patch)
tree7852ae5fa1c6a9d91f6c5b7930615a45245b694e /OpenSim/Data/MySQL/MySQLSimulationData.cs
parentStreamline banning code using existing methods. (diff)
downloadopensim-SC_OLD-07c487a28f6ce6d85cf32fba0c2ded724f7b5af7.zip
opensim-SC_OLD-07c487a28f6ce6d85cf32fba0c2ded724f7b5af7.tar.gz
opensim-SC_OLD-07c487a28f6ce6d85cf32fba0c2ded724f7b5af7.tar.bz2
opensim-SC_OLD-07c487a28f6ce6d85cf32fba0c2ded724f7b5af7.tar.xz
Make ban, eject, freeze and the scripted versions of those work.
Diffstat (limited to '')
-rw-r--r--OpenSim/Data/MySQL/MySQLSimulationData.cs17
1 files changed, 9 insertions, 8 deletions
diff --git a/OpenSim/Data/MySQL/MySQLSimulationData.cs b/OpenSim/Data/MySQL/MySQLSimulationData.cs
index d459e08..48ef447 100644
--- a/OpenSim/Data/MySQL/MySQLSimulationData.cs
+++ b/OpenSim/Data/MySQL/MySQLSimulationData.cs
@@ -715,10 +715,10 @@ namespace OpenSim.Data.MySQL
715 715
716 cmd.Parameters.Clear(); 716 cmd.Parameters.Clear();
717 cmd.CommandText = "insert into landaccesslist (LandUUID, " + 717 cmd.CommandText = "insert into landaccesslist (LandUUID, " +
718 "AccessUUID, Flags) values (?LandUUID, ?AccessUUID, " + 718 "AccessUUID, Flags, Expires) values (?LandUUID, ?AccessUUID, " +
719 "?Flags)"; 719 "?Flags, ?Expires)";
720 720
721 foreach (ParcelManager.ParcelAccessEntry entry in parcel.LandData.ParcelAccessList) 721 foreach (LandAccessEntry entry in parcel.LandData.ParcelAccessList)
722 { 722 {
723 FillLandAccessCommand(cmd, entry, parcel.LandData.GlobalID); 723 FillLandAccessCommand(cmd, entry, parcel.LandData.GlobalID);
724 ExecuteNonQuery(cmd); 724 ExecuteNonQuery(cmd);
@@ -1396,7 +1396,7 @@ namespace OpenSim.Data.MySQL
1396 newData.ObscureMusic = Convert.ToBoolean(row["ObscureMusic"]); 1396 newData.ObscureMusic = Convert.ToBoolean(row["ObscureMusic"]);
1397 newData.ObscureMedia = Convert.ToBoolean(row["ObscureMedia"]); 1397 newData.ObscureMedia = Convert.ToBoolean(row["ObscureMedia"]);
1398 1398
1399 newData.ParcelAccessList = new List<ParcelManager.ParcelAccessEntry>(); 1399 newData.ParcelAccessList = new List<LandAccessEntry>();
1400 1400
1401 return newData; 1401 return newData;
1402 } 1402 }
@@ -1406,12 +1406,12 @@ namespace OpenSim.Data.MySQL
1406 /// </summary> 1406 /// </summary>
1407 /// <param name="row"></param> 1407 /// <param name="row"></param>
1408 /// <returns></returns> 1408 /// <returns></returns>
1409 private static ParcelManager.ParcelAccessEntry BuildLandAccessData(IDataReader row) 1409 private static LandAccessEntry BuildLandAccessData(IDataReader row)
1410 { 1410 {
1411 ParcelManager.ParcelAccessEntry entry = new ParcelManager.ParcelAccessEntry(); 1411 LandAccessEntry entry = new LandAccessEntry();
1412 entry.AgentID = DBGuid.FromDB(row["AccessUUID"]); 1412 entry.AgentID = DBGuid.FromDB(row["AccessUUID"]);
1413 entry.Flags = (AccessList) Convert.ToInt32(row["Flags"]); 1413 entry.Flags = (AccessList) Convert.ToInt32(row["Flags"]);
1414 entry.Time = new DateTime(); 1414 entry.Expires = Convert.ToInt32(row["Expires"]);
1415 return entry; 1415 return entry;
1416 } 1416 }
1417 1417
@@ -1723,11 +1723,12 @@ namespace OpenSim.Data.MySQL
1723 /// <param name="row"></param> 1723 /// <param name="row"></param>
1724 /// <param name="entry"></param> 1724 /// <param name="entry"></param>
1725 /// <param name="parcelID"></param> 1725 /// <param name="parcelID"></param>
1726 private static void FillLandAccessCommand(MySqlCommand cmd, ParcelManager.ParcelAccessEntry entry, UUID parcelID) 1726 private static void FillLandAccessCommand(MySqlCommand cmd, LandAccessEntry entry, UUID parcelID)
1727 { 1727 {
1728 cmd.Parameters.AddWithValue("LandUUID", parcelID.ToString()); 1728 cmd.Parameters.AddWithValue("LandUUID", parcelID.ToString());
1729 cmd.Parameters.AddWithValue("AccessUUID", entry.AgentID.ToString()); 1729 cmd.Parameters.AddWithValue("AccessUUID", entry.AgentID.ToString());
1730 cmd.Parameters.AddWithValue("Flags", entry.Flags); 1730 cmd.Parameters.AddWithValue("Flags", entry.Flags);
1731 cmd.Parameters.AddWithValue("Expires", entry.Expires.ToString());
1731 } 1732 }
1732 1733
1733 /// <summary> 1734 /// <summary>