mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 00:46:02 +08:00
Implement proper persistence of the following prim properties:
Floating text, Rotation, Texture animation, Particle System This will make "Eye Candy" scripts work without modification in XEngine. The use of the CHANGED_REGION_RESTART hack is no longer needed. Implemented in MySQL only, hovertext also in SQLite.
This commit is contained in:
8
OpenSim/Data/SQLite/Resources/009_RegionStore.sql
Normal file
8
OpenSim/Data/SQLite/Resources/009_RegionStore.sql
Normal file
@@ -0,0 +1,8 @@
|
||||
BEGIN;
|
||||
|
||||
ALTER TABLE prims ADD COLUMN ColorR integer not null default 0;
|
||||
ALTER TABLE prims ADD COLUMN ColorG integer not null default 0;
|
||||
ALTER TABLE prims ADD COLUMN ColorB integer not null default 0;
|
||||
ALTER TABLE prims ADD COLUMN ColorA integer not null default 0;
|
||||
|
||||
COMMIT;
|
||||
@@ -31,6 +31,7 @@ using System.Data;
|
||||
using System.IO;
|
||||
using System.Reflection;
|
||||
using System.Threading;
|
||||
using System.Drawing;
|
||||
using OpenMetaverse;
|
||||
using log4net;
|
||||
using Mono.Data.SqliteClient;
|
||||
@@ -666,6 +667,10 @@ namespace OpenSim.Data.SQLite
|
||||
createCol(prims, "SceneGroupID", typeof (String));
|
||||
// various text fields
|
||||
createCol(prims, "Text", typeof (String));
|
||||
createCol(prims, "ColorR", typeof (Int32));
|
||||
createCol(prims, "ColorG", typeof (Int32));
|
||||
createCol(prims, "ColorB", typeof (Int32));
|
||||
createCol(prims, "ColorA", typeof (Int32));
|
||||
createCol(prims, "Description", typeof (String));
|
||||
createCol(prims, "SitName", typeof (String));
|
||||
createCol(prims, "TouchName", typeof (String));
|
||||
@@ -890,6 +895,10 @@ namespace OpenSim.Data.SQLite
|
||||
prim.Name = (String) row["Name"];
|
||||
// various text fields
|
||||
prim.Text = (String) row["Text"];
|
||||
prim.Color = Color.FromArgb(Convert.ToInt32(row["ColorA"]),
|
||||
Convert.ToInt32(row["ColorR"]),
|
||||
Convert.ToInt32(row["ColorG"]),
|
||||
Convert.ToInt32(row["ColorB"]));
|
||||
prim.Description = (String) row["Description"];
|
||||
prim.SitName = (String) row["SitName"];
|
||||
prim.TouchName = (String) row["TouchName"];
|
||||
|
||||
Reference in New Issue
Block a user