aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/Linden/Caps
diff options
context:
space:
mode:
authorUbitUmarov2015-12-20 11:43:27 +0000
committerUbitUmarov2015-12-20 11:43:27 +0000
commit844266c4d5d75bdf967a643abccfa28d1685c40c (patch)
tree519b90961f5f6ac3b0a21c83b00a5b1216ca3ec3 /OpenSim/Region/ClientStack/Linden/Caps
parent BUG FIX on avatar position updates send control (diff)
downloadopensim-SC_OLD-844266c4d5d75bdf967a643abccfa28d1685c40c.zip
opensim-SC_OLD-844266c4d5d75bdf967a643abccfa28d1685c40c.tar.gz
opensim-SC_OLD-844266c4d5d75bdf967a643abccfa28d1685c40c.tar.bz2
opensim-SC_OLD-844266c4d5d75bdf967a643abccfa28d1685c40c.tar.xz
change the return list of objects costs, sending a answer if none found
Diffstat (limited to 'OpenSim/Region/ClientStack/Linden/Caps')
-rw-r--r--OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs68
1 files changed, 30 insertions, 38 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
index b61959d..91b2ee7 100644
--- a/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
+++ b/OpenSim/Region/ClientStack/Linden/Caps/BunchOfCaps/BunchOfCaps.cs
@@ -1442,41 +1442,36 @@ namespace OpenSim.Region.ClientStack.Linden
1442 UUID uuid = object_ids[i].AsUUID(); 1442 UUID uuid = object_ids[i].AsUUID();
1443 1443
1444 SceneObjectPart part = m_Scene.GetSceneObjectPart(uuid); 1444 SceneObjectPart part = m_Scene.GetSceneObjectPart(uuid);
1445 1445 SceneObjectGroup grp = null;
1446 if (part != null) 1446 if (part != null)
1447 grp = part.ParentGroup;
1448 if (grp != null)
1447 { 1449 {
1448 SceneObjectGroup grp = part.ParentGroup; 1450 float linksetCost;
1449 if (grp != null) 1451 float linksetPhysCost;
1450 { 1452 float partCost;
1451 float linksetCost; 1453 float partPhysCost;
1452 float linksetPhysCost;
1453 float partCost;
1454 float partPhysCost;
1455
1456 grp.GetResourcesCosts(part, out linksetCost, out linksetPhysCost, out partCost, out partPhysCost);
1457
1458 OSDMap object_data = new OSDMap();
1459 object_data["linked_set_resource_cost"] = linksetCost;
1460 object_data["resource_cost"] = partCost;
1461 object_data["physics_cost"] = partPhysCost;
1462 object_data["linked_set_physics_cost"] = linksetPhysCost;
1463 1454
1464 resp[uuid.ToString()] = object_data; 1455 grp.GetResourcesCosts(part,out linksetCost,out linksetPhysCost,out partCost,out partPhysCost);
1465 }
1466 else
1467 {
1468 OSDMap object_data = new OSDMap();
1469 object_data["linked_set_resource_cost"] = 0;
1470 object_data["resource_cost"] = 0;
1471 object_data["physics_cost"] = 0;
1472 object_data["linked_set_physics_cost"] = 0;
1473
1474 resp[uuid.ToString()] = object_data;
1475 }
1476 1456
1457 OSDMap object_data = new OSDMap();
1458 object_data["linked_set_resource_cost"] = linksetCost;
1459 object_data["resource_cost"] = partCost;
1460 object_data["physics_cost"] = partPhysCost;
1461 object_data["linked_set_physics_cost"] = linksetPhysCost;
1462 object_data["resource_limiting_type"] = "legacy";
1463 resp[uuid.ToString()] = object_data;
1477 } 1464 }
1478 } 1465 }
1479 1466 if(resp.Count == 0)
1467 {
1468 OSDMap object_data = new OSDMap();
1469 object_data["linked_set_resource_cost"] = 0;
1470 object_data["resource_cost"] = 0;
1471 object_data["physics_cost"] = 0;
1472 object_data["linked_set_physics_cost"] = 0;
1473 resp[UUID.Zero.ToString()] = object_data;
1474 }
1480 string response = OSDParser.SerializeLLSDXmlString(resp); 1475 string response = OSDParser.SerializeLLSDXmlString(resp);
1481 return response; 1476 return response;
1482 } 1477 }
@@ -1538,17 +1533,14 @@ namespace OpenSim.Region.ClientStack.Linden
1538 } 1533 }
1539 } 1534 }
1540 1535
1541 // if (simul != 0) 1536 OSDMap object_data = new OSDMap();
1542 {
1543 OSDMap object_data = new OSDMap();
1544 1537
1545 object_data["physics"] = phys; 1538 object_data["physics"] = phys;
1546 object_data["streaming"] = stream; 1539 object_data["streaming"] = stream;
1547 object_data["simulation"] = simul; 1540 object_data["simulation"] = simul;
1548
1549 resp["selected"] = object_data;
1550 }
1551 1541
1542 resp["selected"] = object_data;
1543// resp["transaction_id"] = "undef";
1552 string response = OSDParser.SerializeLLSDXmlString(resp); 1544 string response = OSDParser.SerializeLLSDXmlString(resp);
1553 return response; 1545 return response;
1554 } 1546 }