store sop pseudocrc and region cacheID on sqlite

master
UbitUmarov 2020-03-28 16:18:31 +00:00
parent 0958eceadd
commit 2e66f8dbdf
2 changed files with 18 additions and 1 deletions

View File

@ -386,3 +386,11 @@ ALTER TABLE `prims` ADD COLUMN `standtargety` float NOT NULL DEFAULT '0.0';
ALTER TABLE `prims` ADD COLUMN `standtargetz` float NOT NULL DEFAULT '0.0';
ALTER TABLE `prims` ADD COLUMN `sitactrange` float NOT NULL DEFAULT '0.0';
COMMIT;
:VERSION 38 #----- Add pseudo CRC and region cache id
BEGIN;
ALTER TABLE `prims` ADD COLUMN `pseudocrc` integer DEFAULT '0';
ALTER TABLE `regionsettings` ADD COLUMN `cacheID` char(36) DEFAULT NULL;
COMMIT;

View File

@ -1323,6 +1323,8 @@ namespace OpenSim.Data.SQLite
createCol(prims, "standtargetz", typeof(float));
createCol(prims, "sitactrange", typeof(float));
createCol(prims, "pseudocrc", typeof(int));
// Add in contraints
prims.PrimaryKey = new DataColumn[] { prims.Columns["UUID"] };
@ -1532,6 +1534,7 @@ namespace OpenSim.Data.SQLite
createCol(regionsettings, "parcel_tile_ID", typeof(String));
createCol(regionsettings, "block_search", typeof(Boolean));
createCol(regionsettings, "casino", typeof(Boolean));
createCol(regionsettings, "cacheID", typeof(string));
regionsettings.PrimaryKey = new DataColumn[] { regionsettings.Columns["regionUUID"] };
return regionsettings;
}
@ -1868,6 +1871,10 @@ namespace OpenSim.Data.SQLite
pdata = PhysicsInertiaData.FromXml2(row["PhysInertia"].ToString());
prim.PhysicsInertia = pdata;
int pseudocrc = Convert.ToInt32(row["pseudocrc"]);
if(pseudocrc != 0)
prim.PseudoCRC = pseudocrc;
return prim;
}
@ -2303,6 +2310,7 @@ namespace OpenSim.Data.SQLite
else
row["PhysInertia"] = String.Empty;
row["pseudocrc"] = prim.PseudoCRC;
}
/// <summary>
@ -2450,6 +2458,7 @@ namespace OpenSim.Data.SQLite
row["parcel_tile_ID"] = settings.ParcelImageID.ToString();
row["block_search"] = settings.GodBlockSearch;
row["casino"] = settings.Casino;
row["cacheID"] = settings.CacheID;
}
/// <summary>