Merge branch 'master' into varregion

varregion
Robert Adams 2013-12-05 21:07:44 -08:00
commit 4eb52eb19e
7 changed files with 40 additions and 18 deletions

View File

@ -736,7 +736,6 @@ namespace OpenSim.Data.MySQL
string query = string.Empty; string query = string.Empty;
query += "UPDATE userprofile SET "; query += "UPDATE userprofile SET ";
query += "profilePartner=?profilePartner, ";
query += "profileURL=?profileURL, "; query += "profileURL=?profileURL, ";
query += "profileImage=?image, "; query += "profileImage=?image, ";
query += "profileAboutText=?abouttext,"; query += "profileAboutText=?abouttext,";
@ -752,7 +751,6 @@ namespace OpenSim.Data.MySQL
using (MySqlCommand cmd = new MySqlCommand(query, dbcon)) using (MySqlCommand cmd = new MySqlCommand(query, dbcon))
{ {
cmd.Parameters.AddWithValue("?profileURL", props.WebUrl); cmd.Parameters.AddWithValue("?profileURL", props.WebUrl);
cmd.Parameters.AddWithValue("?profilePartner", props.PartnerId.ToString());
cmd.Parameters.AddWithValue("?image", props.ImageId.ToString()); cmd.Parameters.AddWithValue("?image", props.ImageId.ToString());
cmd.Parameters.AddWithValue("?abouttext", props.AboutText); cmd.Parameters.AddWithValue("?abouttext", props.AboutText);
cmd.Parameters.AddWithValue("?firstlifeimage", props.FirstLifeImageId.ToString()); cmd.Parameters.AddWithValue("?firstlifeimage", props.FirstLifeImageId.ToString());

View File

@ -206,7 +206,7 @@ namespace OpenSim.Data.PGSQL
DataTable schemaTable = result.GetSchemaTable(); DataTable schemaTable = result.GetSchemaTable();
foreach (DataRow row in schemaTable.Rows) foreach (DataRow row in schemaTable.Rows)
m_ColumnNames.Add(row["column_name"].ToString()); m_ColumnNames.Add(row["ColumnName"].ToString());
} }
foreach (string s in m_ColumnNames) foreach (string s in m_ColumnNames)

View File

@ -715,7 +715,6 @@ namespace OpenSim.Data.PGSQL
string query = string.Empty; string query = string.Empty;
query += "UPDATE userprofile SET "; query += "UPDATE userprofile SET ";
query += "profilePartner=:profilePartner, ";
query += "profileURL=:profileURL, "; query += "profileURL=:profileURL, ";
query += "profileImage=:image, "; query += "profileImage=:image, ";
query += "profileAboutText=:abouttext,"; query += "profileAboutText=:abouttext,";
@ -731,7 +730,6 @@ namespace OpenSim.Data.PGSQL
using (NpgsqlCommand cmd = new NpgsqlCommand(query, dbcon)) using (NpgsqlCommand cmd = new NpgsqlCommand(query, dbcon))
{ {
cmd.Parameters.AddWithValue("profileURL", props.WebUrl); cmd.Parameters.AddWithValue("profileURL", props.WebUrl);
cmd.Parameters.AddWithValue("profilePartner", props.PartnerId.ToString());
cmd.Parameters.AddWithValue("image", props.ImageId.ToString()); cmd.Parameters.AddWithValue("image", props.ImageId.ToString());
cmd.Parameters.AddWithValue("abouttext", props.AboutText); cmd.Parameters.AddWithValue("abouttext", props.AboutText);
cmd.Parameters.AddWithValue("firstlifeimage", props.FirstLifeImageId.ToString()); cmd.Parameters.AddWithValue("firstlifeimage", props.FirstLifeImageId.ToString());

View File

@ -679,7 +679,6 @@ namespace OpenSim.Data.SQLite
string query = string.Empty; string query = string.Empty;
query += "UPDATE userprofile SET "; query += "UPDATE userprofile SET ";
query += "profilePartner=:profilePartner, ";
query += "profileURL=:profileURL, "; query += "profileURL=:profileURL, ";
query += "profileImage=:image, "; query += "profileImage=:image, ";
query += "profileAboutText=:abouttext,"; query += "profileAboutText=:abouttext,";
@ -693,7 +692,6 @@ namespace OpenSim.Data.SQLite
{ {
cmd.CommandText = query; cmd.CommandText = query;
cmd.Parameters.AddWithValue(":profileURL", props.WebUrl); cmd.Parameters.AddWithValue(":profileURL", props.WebUrl);
cmd.Parameters.AddWithValue(":profilePartner", props.PartnerId.ToString());
cmd.Parameters.AddWithValue(":image", props.ImageId.ToString()); cmd.Parameters.AddWithValue(":image", props.ImageId.ToString());
cmd.Parameters.AddWithValue(":abouttext", props.AboutText); cmd.Parameters.AddWithValue(":abouttext", props.AboutText);
cmd.Parameters.AddWithValue(":firstlifeimage", props.FirstLifeImageId.ToString()); cmd.Parameters.AddWithValue(":firstlifeimage", props.FirstLifeImageId.ToString());

View File

@ -498,24 +498,28 @@ namespace OpenSim.Region.ClientStack.Linden
if (inventoryType == "sound") if (inventoryType == "sound")
{ {
inType = 1; inType = (sbyte)InventoryType.Sound;
assType = 1; assType = (sbyte)AssetType.Sound;
}
else if (inventoryType == "snapshot")
{
inType = (sbyte)InventoryType.Snapshot;
} }
else if (inventoryType == "animation") else if (inventoryType == "animation")
{ {
inType = 19; inType = (sbyte)InventoryType.Animation;
assType = 20; assType = (sbyte)AssetType.Animation;
} }
else if (inventoryType == "wearable") else if (inventoryType == "wearable")
{ {
inType = 18; inType = (sbyte)InventoryType.Wearable;
switch (assetType) switch (assetType)
{ {
case "bodypart": case "bodypart":
assType = 13; assType = (sbyte)AssetType.Bodypart;
break; break;
case "clothing": case "clothing":
assType = 5; assType = (sbyte)AssetType.Clothing;
break; break;
} }
} }

View File

@ -5063,7 +5063,18 @@ namespace OpenSim.Region.ClientStack.LindenUDP
// acceleration = new Vector3(1, 0, 0); // acceleration = new Vector3(1, 0, 0);
angularVelocity = presence.AngularVelocity; angularVelocity = presence.AngularVelocity;
// Whilst not in mouselook, an avatar will transmit only the Z rotation as this is the only axis
// it rotates around.
// In mouselook, X and Y co-ordinate will also be sent but when used in Rotation, these cause unwanted
// excessive up and down movements of the camera when looking up and down.
// See http://opensimulator.org/mantis/view.php?id=3274
// This does not affect head movement, since this is controlled entirely by camera movement rather than
// body rotation. It does not affect sitting avatar since it's the sitting part rotation that takes
// effect, not the avatar rotation.
rotation = presence.Rotation; rotation = presence.Rotation;
rotation.X = 0;
rotation.Y = 0;
if (sendTexture) if (sendTexture)
textureEntry = presence.Appearance.Texture.GetBytes(); textureEntry = presence.Appearance.Texture.GetBytes();
@ -5179,7 +5190,19 @@ namespace OpenSim.Region.ClientStack.LindenUDP
data.OffsetPosition.ToBytes(objectData, 16); data.OffsetPosition.ToBytes(objectData, 16);
// data.Velocity.ToBytes(objectData, 28); // data.Velocity.ToBytes(objectData, 28);
// data.Acceleration.ToBytes(objectData, 40); // data.Acceleration.ToBytes(objectData, 40);
data.Rotation.ToBytes(objectData, 52);
// Whilst not in mouselook, an avatar will transmit only the Z rotation as this is the only axis
// it rotates around.
// In mouselook, X and Y co-ordinate will also be sent but when used in Rotation, these cause unwanted
// excessive up and down movements of the camera when looking up and down.
// See http://opensimulator.org/mantis/view.php?id=3274
// This does not affect head movement, since this is controlled entirely by camera movement rather than
// body rotation. It does not affect sitting avatar since it's the sitting part rotation that takes
// effect, not the avatar rotation.
Quaternion rot = data.Rotation;
rot.X = 0;
rot.Y = 0;
rot.ToBytes(objectData, 52);
//data.AngularVelocity.ToBytes(objectData, 64); //data.AngularVelocity.ToBytes(objectData, 64);
ObjectUpdatePacket.ObjectDataBlock update = new ObjectUpdatePacket.ObjectDataBlock(); ObjectUpdatePacket.ObjectDataBlock update = new ObjectUpdatePacket.ObjectDataBlock();

View File

@ -1645,12 +1645,13 @@ namespace OpenSim.Region.Framework.Scenes
if (AllowMovement && !SitGround) if (AllowMovement && !SitGround)
{ {
Quaternion bodyRotation = agentData.BodyRotation; // m_log.DebugFormat("[SCENE PRESENCE]: Initial body rotation {0} for {1}", agentData.BodyRotation, Name);
bool update_rotation = false; bool update_rotation = false;
if (bodyRotation != Rotation) if (agentData.BodyRotation != Rotation)
{ {
Rotation = bodyRotation; Rotation = agentData.BodyRotation;
update_rotation = true; update_rotation = true;
} }