aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MySQL
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Data/MySQL')
-rw-r--r--OpenSim/Data/MySQL/MySQLLegacyRegionData.cs16
-rw-r--r--OpenSim/Data/MySQL/Resources/RegionStore.migrations9
2 files changed, 20 insertions, 5 deletions
diff --git a/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs b/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs
index bfeae12..d8debc5 100644
--- a/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs
+++ b/OpenSim/Data/MySQL/MySQLLegacyRegionData.cs
@@ -174,7 +174,7 @@ namespace OpenSim.Data.MySQL
174 "ParticleSystem, ClickAction, Material, " + 174 "ParticleSystem, ClickAction, Material, " +
175 "CollisionSound, CollisionSoundVolume, " + 175 "CollisionSound, CollisionSoundVolume, " +
176 "PassTouches, " + 176 "PassTouches, " +
177 "LinkNumber) values (" + "?UUID, " + 177 "LinkNumber, MediaURL) values (" + "?UUID, " +
178 "?CreationDate, ?Name, ?Text, " + 178 "?CreationDate, ?Name, ?Text, " +
179 "?Description, ?SitName, ?TouchName, " + 179 "?Description, ?SitName, ?TouchName, " +
180 "?ObjectFlags, ?OwnerMask, ?NextOwnerMask, " + 180 "?ObjectFlags, ?OwnerMask, ?NextOwnerMask, " +
@@ -205,7 +205,7 @@ namespace OpenSim.Data.MySQL
205 "?SaleType, ?ColorR, ?ColorG, " + 205 "?SaleType, ?ColorR, ?ColorG, " +
206 "?ColorB, ?ColorA, ?ParticleSystem, " + 206 "?ColorB, ?ColorA, ?ParticleSystem, " +
207 "?ClickAction, ?Material, ?CollisionSound, " + 207 "?ClickAction, ?Material, ?CollisionSound, " +
208 "?CollisionSoundVolume, ?PassTouches, ?LinkNumber)"; 208 "?CollisionSoundVolume, ?PassTouches, ?LinkNumber, ?MediaURL)";
209 209
210 FillPrimCommand(cmd, prim, obj.UUID, regionUUID); 210 FillPrimCommand(cmd, prim, obj.UUID, regionUUID);
211 211
@@ -222,7 +222,7 @@ namespace OpenSim.Data.MySQL
222 "PathTaperX, PathTaperY, PathTwist, " + 222 "PathTaperX, PathTaperY, PathTwist, " +
223 "PathTwistBegin, ProfileBegin, ProfileEnd, " + 223 "PathTwistBegin, ProfileBegin, ProfileEnd, " +
224 "ProfileCurve, ProfileHollow, Texture, " + 224 "ProfileCurve, ProfileHollow, Texture, " +
225 "ExtraParams, State) values (?UUID, " + 225 "ExtraParams, State, Media) values (?UUID, " +
226 "?Shape, ?ScaleX, ?ScaleY, ?ScaleZ, " + 226 "?Shape, ?ScaleX, ?ScaleY, ?ScaleZ, " +
227 "?PCode, ?PathBegin, ?PathEnd, " + 227 "?PCode, ?PathBegin, ?PathEnd, " +
228 "?PathScaleX, ?PathScaleY, " + 228 "?PathScaleX, ?PathScaleY, " +
@@ -233,7 +233,7 @@ namespace OpenSim.Data.MySQL
233 "?PathTwistBegin, ?ProfileBegin, " + 233 "?PathTwistBegin, ?ProfileBegin, " +
234 "?ProfileEnd, ?ProfileCurve, " + 234 "?ProfileEnd, ?ProfileCurve, " +
235 "?ProfileHollow, ?Texture, ?ExtraParams, " + 235 "?ProfileHollow, ?Texture, ?ExtraParams, " +
236 "?State)"; 236 "?State, ?Media)";
237 237
238 FillShapeCommand(cmd, prim); 238 FillShapeCommand(cmd, prim);
239 239
@@ -1184,6 +1184,9 @@ namespace OpenSim.Data.MySQL
1184 1184
1185 prim.PassTouches = ((sbyte)row["PassTouches"] != 0); 1185 prim.PassTouches = ((sbyte)row["PassTouches"] != 0);
1186 prim.LinkNum = (int)row["LinkNumber"]; 1186 prim.LinkNum = (int)row["LinkNumber"];
1187
1188 if (!(row["MediaURL"] is System.DBNull))
1189 prim.MediaUrl = (string)row["MediaURL"];
1187 1190
1188 return prim; 1191 return prim;
1189 } 1192 }
@@ -1521,6 +1524,7 @@ namespace OpenSim.Data.MySQL
1521 cmd.Parameters.AddWithValue("PassTouches", 0); 1524 cmd.Parameters.AddWithValue("PassTouches", 0);
1522 1525
1523 cmd.Parameters.AddWithValue("LinkNumber", prim.LinkNum); 1526 cmd.Parameters.AddWithValue("LinkNumber", prim.LinkNum);
1527 cmd.Parameters.AddWithValue("MediaURL", prim.MediaUrl);
1524 } 1528 }
1525 1529
1526 /// <summary> 1530 /// <summary>
@@ -1700,6 +1704,9 @@ namespace OpenSim.Data.MySQL
1700 s.ExtraParams = (byte[])row["ExtraParams"]; 1704 s.ExtraParams = (byte[])row["ExtraParams"];
1701 1705
1702 s.State = (byte)(int)row["State"]; 1706 s.State = (byte)(int)row["State"];
1707
1708 if (!(row["Media"] is System.DBNull))
1709 s.Media = PrimitiveBaseShape.MediaList.FromXml((string)row["Media"]);
1703 1710
1704 return s; 1711 return s;
1705 } 1712 }
@@ -1743,6 +1750,7 @@ namespace OpenSim.Data.MySQL
1743 cmd.Parameters.AddWithValue("Texture", s.TextureEntry); 1750 cmd.Parameters.AddWithValue("Texture", s.TextureEntry);
1744 cmd.Parameters.AddWithValue("ExtraParams", s.ExtraParams); 1751 cmd.Parameters.AddWithValue("ExtraParams", s.ExtraParams);
1745 cmd.Parameters.AddWithValue("State", s.State); 1752 cmd.Parameters.AddWithValue("State", s.State);
1753 cmd.Parameters.AddWithValue("Media", null == s.Media ? null : s.Media.ToXml());
1746 } 1754 }
1747 1755
1748 public void StorePrimInventory(UUID primID, ICollection<TaskInventoryItem> items) 1756 public void StorePrimInventory(UUID primID, ICollection<TaskInventoryItem> items)
diff --git a/OpenSim/Data/MySQL/Resources/RegionStore.migrations b/OpenSim/Data/MySQL/Resources/RegionStore.migrations
index 88ee748..ce99ce4 100644
--- a/OpenSim/Data/MySQL/Resources/RegionStore.migrations
+++ b/OpenSim/Data/MySQL/Resources/RegionStore.migrations
@@ -1,4 +1,4 @@
1 1
2:VERSION 1 #--------------------- 2:VERSION 1 #---------------------
3 3
4BEGIN; 4BEGIN;
@@ -800,3 +800,10 @@ BEGIN;
800ALTER TABLE `regionwindlight` CHANGE COLUMN `cloud_scroll_x` `cloud_scroll_x` FLOAT(4,2) NOT NULL DEFAULT '0.20' AFTER `cloud_detail_density`, CHANGE COLUMN `cloud_scroll_y` `cloud_scroll_y` FLOAT(4,2) NOT NULL DEFAULT '0.01' AFTER `cloud_scroll_x_lock`; 800ALTER TABLE `regionwindlight` CHANGE COLUMN `cloud_scroll_x` `cloud_scroll_x` FLOAT(4,2) NOT NULL DEFAULT '0.20' AFTER `cloud_detail_density`, CHANGE COLUMN `cloud_scroll_y` `cloud_scroll_y` FLOAT(4,2) NOT NULL DEFAULT '0.01' AFTER `cloud_scroll_x_lock`;
801COMMIT; 801COMMIT;
802 802
803:VERSION 35 #---------------------
804-- Added post 0.7
805
806BEGIN;
807ALTER TABLE prims ADD COLUMN MediaURL varchar(255);
808ALTER TABLE primshapes ADD COLUMN Media TEXT;
809COMMIT; \ No newline at end of file