don't read from dbs wrong sound flags
parent
9487f5cdd3
commit
6ae1341c58
|
@ -1403,7 +1403,10 @@ namespace OpenSim.Data.MySQL
|
||||||
|
|
||||||
prim.Sound = DBGuid.FromDB(row["LoopedSound"].ToString());
|
prim.Sound = DBGuid.FromDB(row["LoopedSound"].ToString());
|
||||||
prim.SoundGain = (float)(double)row["LoopedSoundGain"];
|
prim.SoundGain = (float)(double)row["LoopedSoundGain"];
|
||||||
prim.SoundFlags = 1; // If it's persisted at all, it's looped
|
if (prim.Sound != UUID.Zero)
|
||||||
|
prim.SoundFlags = 1; // If it's persisted at all, it's looped
|
||||||
|
else
|
||||||
|
prim.SoundFlags = 0;
|
||||||
|
|
||||||
if (!(row["TextureAnimation"] is DBNull))
|
if (!(row["TextureAnimation"] is DBNull))
|
||||||
prim.TextureAnimation = (byte[])row["TextureAnimation"];
|
prim.TextureAnimation = (byte[])row["TextureAnimation"];
|
||||||
|
|
|
@ -1742,7 +1742,10 @@ namespace OpenSim.Data.PGSQL
|
||||||
|
|
||||||
prim.Sound = new UUID((Guid)primRow["LoopedSound"]);
|
prim.Sound = new UUID((Guid)primRow["LoopedSound"]);
|
||||||
prim.SoundGain = Convert.ToSingle(primRow["LoopedSoundGain"]);
|
prim.SoundGain = Convert.ToSingle(primRow["LoopedSoundGain"]);
|
||||||
prim.SoundFlags = 1; // If it's persisted at all, it's looped
|
if (prim.Sound != UUID.Zero)
|
||||||
|
prim.SoundFlags = 1; // If it's persisted at all, it's looped
|
||||||
|
else
|
||||||
|
prim.SoundFlags = 0;
|
||||||
|
|
||||||
if (!(primRow["TextureAnimation"] is DBNull))
|
if (!(primRow["TextureAnimation"] is DBNull))
|
||||||
prim.TextureAnimation = (Byte[])primRow["TextureAnimation"];
|
prim.TextureAnimation = (Byte[])primRow["TextureAnimation"];
|
||||||
|
|
|
@ -1742,7 +1742,10 @@ namespace OpenSim.Data.SQLite
|
||||||
|
|
||||||
prim.Sound = new UUID(row["LoopedSound"].ToString());
|
prim.Sound = new UUID(row["LoopedSound"].ToString());
|
||||||
prim.SoundGain = Convert.ToSingle(row["LoopedSoundGain"]);
|
prim.SoundGain = Convert.ToSingle(row["LoopedSoundGain"]);
|
||||||
prim.SoundFlags = 1; // If it's persisted at all, it's looped
|
if (prim.Sound != UUID.Zero)
|
||||||
|
prim.SoundFlags = 1; // If it's persisted at all, it's looped
|
||||||
|
else
|
||||||
|
prim.SoundFlags = 0;
|
||||||
|
|
||||||
if (!row.IsNull("TextureAnimation"))
|
if (!row.IsNull("TextureAnimation"))
|
||||||
prim.TextureAnimation = Convert.FromBase64String(row["TextureAnimation"].ToString());
|
prim.TextureAnimation = Convert.FromBase64String(row["TextureAnimation"].ToString());
|
||||||
|
|
Loading…
Reference in New Issue