mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 00:46:02 +08:00
Merge branch 'ubitwork' of ssh://3dhosting.de/var/git/careminster into ubitwork
This commit is contained in:
@@ -35,10 +35,13 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
// fees are normalized to 1.0
|
||||
// this parameters scale them to basic cost ( so 1.0 translates to 10 )
|
||||
|
||||
public float ModelMeshCostFactor = 1.0f; // scale total cost relative to basic (excluding textures)
|
||||
public float ModelTextureCostFactor = 1.0f; // scale textures fee to basic.
|
||||
public float ModelMinCostFactor = 0.5f; // minimum total model free excluding textures
|
||||
public float ModelMeshCostFactor = 0f; //Free
|
||||
public float ModelMinCostFactor = 0f; // Free
|
||||
//public float ModelMeshCostFactor = 1.0f; // scale total cost relative to basic (excluding textures)
|
||||
//public float ModelMinCostFactor = 0.5f; // minimum total model free excluding textures
|
||||
|
||||
public float ModelTextureCostFactor = 1.00f; // keep full price because texture price
|
||||
// is based on it's storage needs not on usability
|
||||
// itens costs in normalized values
|
||||
// ie will be multiplied by basicCost and factors above
|
||||
const float primCreationCost = 0.002f; // extra cost for each prim creation overhead
|
||||
|
||||
@@ -146,14 +146,14 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
{
|
||||
m_scene = scene;
|
||||
|
||||
HasEvents = (x, y) => { return this.responses.ContainsKey(x); };
|
||||
HasEvents = (x, y) => { lock (responses) return responses.ContainsKey(x); };
|
||||
GetEvents = (x, y, s) =>
|
||||
{
|
||||
lock (responses)
|
||||
{
|
||||
try
|
||||
{
|
||||
return this.responses[x];
|
||||
return responses[x];
|
||||
}
|
||||
finally
|
||||
{
|
||||
@@ -165,15 +165,15 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
Request = (x, y) =>
|
||||
{
|
||||
y["RequestID"] = x.ToString();
|
||||
lock (this.requests)
|
||||
this.requests.Add(y);
|
||||
lock (requests)
|
||||
requests.Add(y);
|
||||
|
||||
m_queue.Enqueue(this);
|
||||
};
|
||||
|
||||
NoEvents = (x, y) =>
|
||||
{
|
||||
lock (this.requests)
|
||||
lock (requests)
|
||||
{
|
||||
Hashtable request = requests.Find(id => id["RequestID"].ToString() == x.ToString());
|
||||
requests.Remove(request);
|
||||
@@ -198,7 +198,7 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
|
||||
try
|
||||
{
|
||||
lock (this.requests)
|
||||
lock (requests)
|
||||
{
|
||||
request = requests[0];
|
||||
requests.RemoveAt(0);
|
||||
@@ -221,8 +221,10 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
response["content_type"] = "text/plain";
|
||||
response["keepalive"] = false;
|
||||
response["reusecontext"] = false;
|
||||
|
||||
lock (responses)
|
||||
responses[requestID] = response;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -144,31 +144,34 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
public PollServiceInventoryEventArgs(UUID pId) :
|
||||
base(null, null, null, null, pId, 30000)
|
||||
{
|
||||
HasEvents = (x, y) => { return this.responses.ContainsKey(x); };
|
||||
HasEvents = (x, y) => { lock (responses) return responses.ContainsKey(x); };
|
||||
GetEvents = (x, y, s) =>
|
||||
{
|
||||
try
|
||||
lock (responses)
|
||||
{
|
||||
return this.responses[x];
|
||||
}
|
||||
finally
|
||||
{
|
||||
responses.Remove(x);
|
||||
try
|
||||
{
|
||||
return responses[x];
|
||||
}
|
||||
finally
|
||||
{
|
||||
responses.Remove(x);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
Request = (x, y) =>
|
||||
{
|
||||
y["RequestID"] = x.ToString();
|
||||
lock (this.requests)
|
||||
this.requests.Add(y);
|
||||
lock (requests)
|
||||
requests.Add(y);
|
||||
|
||||
m_queue.Enqueue(this);
|
||||
};
|
||||
|
||||
NoEvents = (x, y) =>
|
||||
{
|
||||
lock (this.requests)
|
||||
lock (requests)
|
||||
{
|
||||
Hashtable request = requests.Find(id => id["RequestID"].ToString() == x.ToString());
|
||||
requests.Remove(request);
|
||||
@@ -192,7 +195,7 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
|
||||
try
|
||||
{
|
||||
lock (this.requests)
|
||||
lock (requests)
|
||||
{
|
||||
request = requests[0];
|
||||
requests.RemoveAt(0);
|
||||
@@ -214,7 +217,8 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||
|
||||
response["str_response_string"] = m_webFetchHandler.FetchInventoryDescendentsRequest(request["body"].ToString(), String.Empty, String.Empty, null, null);
|
||||
|
||||
responses[requestID] = response;
|
||||
lock (responses)
|
||||
responses[requestID] = response;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -2067,8 +2067,13 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
OutPacket(bulkUpdate, ThrottleOutPacketType.Asset);
|
||||
}
|
||||
|
||||
/// <see>IClientAPI.SendInventoryItemCreateUpdate(InventoryItemBase)</see>
|
||||
public void SendInventoryItemCreateUpdate(InventoryItemBase Item, uint callbackId)
|
||||
{
|
||||
SendInventoryItemCreateUpdate(Item, UUID.Zero, callbackId);
|
||||
}
|
||||
|
||||
/// <see>IClientAPI.SendInventoryItemCreateUpdate(InventoryItemBase)</see>
|
||||
public void SendInventoryItemCreateUpdate(InventoryItemBase Item, UUID transactionID, uint callbackId)
|
||||
{
|
||||
const uint FULL_MASK_PERMISSIONS = (uint)PermissionMask.All;
|
||||
|
||||
@@ -2079,6 +2084,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||
// TODO: don't create new blocks if recycling an old packet
|
||||
InventoryReply.AgentData.AgentID = AgentId;
|
||||
InventoryReply.AgentData.SimApproved = true;
|
||||
InventoryReply.AgentData.TransactionID = transactionID;
|
||||
InventoryReply.InventoryData = new UpdateCreateInventoryItemPacket.InventoryDataBlock[1];
|
||||
InventoryReply.InventoryData[0] = new UpdateCreateInventoryItemPacket.InventoryDataBlock();
|
||||
InventoryReply.InventoryData[0].ItemID = Item.ID;
|
||||
|
||||
Reference in New Issue
Block a user