aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs5
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs2
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs4
-rw-r--r--OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs10
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.Inventory.cs5
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs7
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs14
-rw-r--r--OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs107
-rw-r--r--OpenSim/Region/Framework/Scenes/Tests/ScenePresenceCrossingTests.cs4
-rw-r--r--OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTeleportTests.cs14
-rw-r--r--OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs2
-rw-r--r--OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs2
-rwxr-xr-xOpenSim/Region/Physics/BulletSPlugin/BSShapes.cs8
13 files changed, 125 insertions, 59 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
index 17b59da..9de564b 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLClientView.cs
@@ -1580,7 +1580,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
1580 OutPacket(pc, ThrottleOutPacketType.Unknown); 1580 OutPacket(pc, ThrottleOutPacketType.Unknown);
1581 } 1581 }
1582 1582
1583 public void SendKillObject(ulong regionHandle, List<uint> localIDs) 1583 public void SendKillObject(List<uint> localIDs)
1584 { 1584 {
1585// foreach (uint id in localIDs) 1585// foreach (uint id in localIDs)
1586// m_log.DebugFormat("[CLIENT]: Sending KillObjectPacket to {0} for {1} in {2}", Name, id, regionHandle); 1586// m_log.DebugFormat("[CLIENT]: Sending KillObjectPacket to {0} for {1} in {2}", Name, id, regionHandle);
@@ -11961,8 +11961,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
11961 if (part == null) 11961 if (part == null)
11962 { 11962 {
11963 // It's a ghost! tell the client to delete it from view. 11963 // It's a ghost! tell the client to delete it from view.
11964 simClient.SendKillObject(Scene.RegionInfo.RegionHandle, 11964 simClient.SendKillObject(new List<uint> { localId });
11965 new List<uint> { localId });
11966 } 11965 }
11967 else 11966 else
11968 { 11967 {
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
index cb724aa..0f03ad0 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
@@ -841,7 +841,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments
841 m_scene.ForEachClient( 841 m_scene.ForEachClient(
842 client => 842 client =>
843 { if (client.AgentId != so.AttachedAvatar) 843 { if (client.AgentId != so.AttachedAvatar)
844 client.SendKillObject(m_scene.RegionInfo.RegionHandle, new List<uint>() { so.LocalId }); 844 client.SendKillObject(new List<uint>() { so.LocalId });
845 }); 845 });
846 } 846 }
847 847
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs
index 1a38619..8f9b17e 100644
--- a/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Attachments/Tests/AttachmentsModuleTests.cs
@@ -833,11 +833,11 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments.Tests
833 UserAccount ua1 = UserAccountHelpers.CreateUserWithInventory(sceneA, 0x1); 833 UserAccount ua1 = UserAccountHelpers.CreateUserWithInventory(sceneA, 0x1);
834 834
835 AgentCircuitData acd = SceneHelpers.GenerateAgentData(ua1.PrincipalID); 835 AgentCircuitData acd = SceneHelpers.GenerateAgentData(ua1.PrincipalID);
836 TestClient tc = new TestClient(acd, sceneA, sh.SceneManager); 836 TestClient tc = new TestClient(acd, sceneA);
837 List<TestClient> destinationTestClients = new List<TestClient>(); 837 List<TestClient> destinationTestClients = new List<TestClient>();
838 EntityTransferHelpers.SetUpInformClientOfNeighbour(tc, destinationTestClients); 838 EntityTransferHelpers.SetUpInformClientOfNeighbour(tc, destinationTestClients);
839 839
840 ScenePresence beforeTeleportSp = SceneHelpers.AddScenePresence(sceneA, tc, acd, sh.SceneManager); 840 ScenePresence beforeTeleportSp = SceneHelpers.AddScenePresence(sceneA, tc, acd);
841 beforeTeleportSp.AbsolutePosition = new Vector3(30, 31, 32); 841 beforeTeleportSp.AbsolutePosition = new Vector3(30, 31, 32);
842 842
843 InventoryItemBase attItem = CreateAttachmentItem(sceneA, ua1.PrincipalID, "att", 0x10, 0x20); 843 InventoryItemBase attItem = CreateAttachmentItem(sceneA, ua1.PrincipalID, "att", 0x10, 0x20);
diff --git a/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs b/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs
index f555b49..11a0146 100644
--- a/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs
+++ b/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs
@@ -104,14 +104,8 @@ namespace OpenSim.Region.Framework.Scenes
104 // better than losing the object for now. 104 // better than losing the object for now.
105 if (permissionToDelete) 105 if (permissionToDelete)
106 { 106 {
107 List<uint> killIDs = new List<uint>();
108
109 foreach (SceneObjectGroup g in objectGroups) 107 foreach (SceneObjectGroup g in objectGroups)
110 { killIDs.Add(g.LocalId); 108 g.DeleteGroupFromScene(false);
111 g.DeleteGroupFromScene(true);
112 }
113
114 m_scene.SendKillObject(killIDs);
115 } 109 }
116 } 110 }
117 111
@@ -160,7 +154,7 @@ namespace OpenSim.Region.Framework.Scenes
160 if (x.permissionToDelete) 154 if (x.permissionToDelete)
161 { 155 {
162 foreach (SceneObjectGroup g in x.objectGroups) 156 foreach (SceneObjectGroup g in x.objectGroups)
163 m_scene.DeleteSceneObject(g, false); 157 m_scene.DeleteSceneObject(g, true);
164 } 158 }
165 } 159 }
166 catch (Exception e) 160 catch (Exception e)
diff --git a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
index d2e41f8..257e070 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
@@ -485,7 +485,10 @@ namespace OpenSim.Region.Framework.Scenes
485 item.SaleType = itemUpd.SaleType; 485 item.SaleType = itemUpd.SaleType;
486 486
487 InventoryService.UpdateItem(item); 487 InventoryService.UpdateItem(item);
488 remoteClient.SendBulkUpdateInventory(item); 488
489 // We cannot send out a bulk update here, since this will cause editing of clothing to start
490 // failing frequently. Possibly this is a race with a separate transaction that uploads the asset.
491// remoteClient.SendBulkUpdateInventory(item);
489 } 492 }
490 493
491 if (UUID.Zero != transactionID) 494 if (UUID.Zero != transactionID)
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 5860c9a..1023e25 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -3648,7 +3648,7 @@ namespace OpenSim.Region.Framework.Scenes
3648 delegate(IClientAPI client) 3648 delegate(IClientAPI client)
3649 { 3649 {
3650 //We can safely ignore null reference exceptions. It means the avatar is dead and cleaned up anyway 3650 //We can safely ignore null reference exceptions. It means the avatar is dead and cleaned up anyway
3651 try { client.SendKillObject(avatar.RegionHandle, new List<uint> { avatar.LocalId }); } 3651 try { client.SendKillObject(new List<uint> { avatar.LocalId }); }
3652 catch (NullReferenceException) { } 3652 catch (NullReferenceException) { }
3653 }); 3653 });
3654 } 3654 }
@@ -3729,7 +3729,8 @@ namespace OpenSim.Region.Framework.Scenes
3729 } 3729 }
3730 deleteIDs.Add(localID); 3730 deleteIDs.Add(localID);
3731 } 3731 }
3732 ForEachClient(delegate(IClientAPI client) { client.SendKillObject(m_regionHandle, deleteIDs); }); 3732
3733 ForEachClient(c => c.SendKillObject(deleteIDs));
3733 } 3734 }
3734 3735
3735 #endregion 3736 #endregion
@@ -4382,8 +4383,6 @@ namespace OpenSim.Region.Framework.Scenes
4382 m_log.DebugFormat( 4383 m_log.DebugFormat(
4383 "[SCENE]: Incoming child agent update for {0} in {1}", cAgentData.AgentID, RegionInfo.RegionName); 4384 "[SCENE]: Incoming child agent update for {0} in {1}", cAgentData.AgentID, RegionInfo.RegionName);
4384 4385
4385 // XPTO: if this agent is not allowed here as root, always return false
4386
4387 // We have to wait until the viewer contacts this region after receiving EAC. 4386 // We have to wait until the viewer contacts this region after receiving EAC.
4388 // That calls AddNewClient, which finally creates the ScenePresence 4387 // That calls AddNewClient, which finally creates the ScenePresence
4389 int flags = GetUserFlags(cAgentData.AgentID); 4388 int flags = GetUserFlags(cAgentData.AgentID);
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
index 69fb6df..92e4fce 100644
--- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs
@@ -1857,11 +1857,11 @@ namespace OpenSim.Region.Framework.Scenes
1857 /// <summary> 1857 /// <summary>
1858 /// Delete this group from its scene. 1858 /// Delete this group from its scene.
1859 /// </summary> 1859 /// </summary>
1860 /// 1860 /// <remarks>
1861 /// This only handles the in-world consequences of deletion (e.g. any avatars sitting on it are forcibly stood 1861 /// This only handles the in-world consequences of deletion (e.g. any avatars sitting on it are forcibly stood
1862 /// up and all avatars receive notification of its removal. Removal of the scene object from database backup 1862 /// up and all avatars receive notification of its removal. Removal of the scene object from database backup
1863 /// must be handled by the caller. 1863 /// must be handled by the caller.
1864 /// 1864 /// </remarks>
1865 /// <param name="silent">If true then deletion is not broadcast to clients</param> 1865 /// <param name="silent">If true then deletion is not broadcast to clients</param>
1866 public void DeleteGroupFromScene(bool silent) 1866 public void DeleteGroupFromScene(bool silent)
1867 { 1867 {
@@ -1875,10 +1875,10 @@ namespace OpenSim.Region.Framework.Scenes
1875 { 1875 {
1876 SceneObjectPart part = parts[i]; 1876 SceneObjectPart part = parts[i];
1877 1877
1878 Scene.ForEachRootScenePresence(delegate(ScenePresence avatar) 1878 Scene.ForEachScenePresence(sp =>
1879 { 1879 {
1880 if (avatar.ParentID == LocalId) 1880 if (!sp.IsChildAgent && sp.ParentID == LocalId)
1881 avatar.StandUp(); 1881 sp.StandUp();
1882 1882
1883 if (!silent) 1883 if (!silent)
1884 { 1884 {
@@ -1886,9 +1886,9 @@ namespace OpenSim.Region.Framework.Scenes
1886 if (part == m_rootPart) 1886 if (part == m_rootPart)
1887 { 1887 {
1888 if (!IsAttachment 1888 if (!IsAttachment
1889 || AttachedAvatar == avatar.ControllingClient.AgentId 1889 || AttachedAvatar == sp.UUID
1890 || !HasPrivateAttachmentPoint) 1890 || !HasPrivateAttachmentPoint)
1891 avatar.ControllingClient.SendKillObject(m_regionHandle, new List<uint> { part.LocalId }); 1891 sp.ControllingClient.SendKillObject(new List<uint> { part.LocalId });
1892 } 1892 }
1893 } 1893 }
1894 }); 1894 });
diff --git a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs
index 52ad538..d670dad 100644
--- a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs
+++ b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectDeRezTests.cs
@@ -33,7 +33,9 @@ using NUnit.Framework;
33using OpenMetaverse; 33using OpenMetaverse;
34using OpenSim.Framework; 34using OpenSim.Framework;
35using OpenSim.Framework.Communications; 35using OpenSim.Framework.Communications;
36using OpenSim.Region.CoreModules.Framework.EntityTransfer;
36using OpenSim.Region.CoreModules.Framework.InventoryAccess; 37using OpenSim.Region.CoreModules.Framework.InventoryAccess;
38using OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation;
37using OpenSim.Region.CoreModules.World.Permissions; 39using OpenSim.Region.CoreModules.World.Permissions;
38using OpenSim.Region.Framework.Scenes; 40using OpenSim.Region.Framework.Scenes;
39using OpenSim.Services.Interfaces; 41using OpenSim.Services.Interfaces;
@@ -52,6 +54,24 @@ namespace OpenSim.Region.Framework.Scenes.Tests
52 [TestFixture] 54 [TestFixture]
53 public class SceneObjectDeRezTests : OpenSimTestCase 55 public class SceneObjectDeRezTests : OpenSimTestCase
54 { 56 {
57 [TestFixtureSetUp]
58 public void FixtureInit()
59 {
60 // Don't allow tests to be bamboozled by asynchronous events. Execute everything on the same thread.
61 // This facility was added after the original async delete tests were written, so it may be possible now
62 // to not bother explicitly disabling their async (since everything will be running sync).
63 Util.FireAndForgetMethod = FireAndForgetMethod.RegressionTest;
64 }
65
66 [TestFixtureTearDown]
67 public void TearDown()
68 {
69 // We must set this back afterwards, otherwise later tests will fail since they're expecting multiple
70 // threads. Possibly, later tests should be rewritten so none of them require async stuff (which regression
71 // tests really shouldn't).
72 Util.FireAndForgetMethod = Util.DefaultFireAndForgetMethod;
73 }
74
55 /// <summary> 75 /// <summary>
56 /// Test deleting an object from a scene. 76 /// Test deleting an object from a scene.
57 /// </summary> 77 /// </summary>
@@ -59,46 +79,96 @@ namespace OpenSim.Region.Framework.Scenes.Tests
59 public void TestDeRezSceneObject() 79 public void TestDeRezSceneObject()
60 { 80 {
61 TestHelpers.InMethod(); 81 TestHelpers.InMethod();
62// log4net.Config.XmlConfigurator.Configure();
63 82
64 UUID userId = UUID.Parse("10000000-0000-0000-0000-000000000001"); 83 UUID userId = UUID.Parse("10000000-0000-0000-0000-000000000001");
65 84
66 TestScene scene = new SceneHelpers().SetupScene(); 85 TestScene scene = new SceneHelpers().SetupScene();
67 IConfigSource configSource = new IniConfigSource(); 86 SceneHelpers.SetupSceneModules(scene, new PermissionsModule());
68 IConfig config = configSource.AddConfig("Startup"); 87 TestClient client = (TestClient)SceneHelpers.AddScenePresence(scene, userId).ControllingClient;
69 config.Set("serverside_object_permissions", true);
70 SceneHelpers.SetupSceneModules(scene, configSource, new object[] { new PermissionsModule() });
71 IClientAPI client = SceneHelpers.AddScenePresence(scene, userId).ControllingClient;
72 88
73 // Turn off the timer on the async sog deleter - we'll crank it by hand for this test. 89 // Turn off the timer on the async sog deleter - we'll crank it by hand for this test.
74 AsyncSceneObjectGroupDeleter sogd = scene.SceneObjectGroupDeleter; 90 AsyncSceneObjectGroupDeleter sogd = scene.SceneObjectGroupDeleter;
75 sogd.Enabled = false; 91 sogd.Enabled = false;
76 92
77 SceneObjectPart part 93 SceneObjectGroup so = SceneHelpers.AddSceneObject(scene, "so1", userId);
78 = new SceneObjectPart(userId, PrimitiveBaseShape.Default, Vector3.Zero, Quaternion.Identity, Vector3.Zero); 94 uint soLocalId = so.LocalId;
79 part.Name = "obj1";
80 scene.AddNewSceneObject(new SceneObjectGroup(part), false);
81 95
82 List<uint> localIds = new List<uint>(); 96 List<uint> localIds = new List<uint>();
83 localIds.Add(part.LocalId); 97 localIds.Add(so.LocalId);
84 scene.DeRezObjects(client, localIds, UUID.Zero, DeRezAction.Delete, UUID.Zero); 98 scene.DeRezObjects(client, localIds, UUID.Zero, DeRezAction.Delete, UUID.Zero);
85 99
86 // Check that object isn't deleted until we crank the sogd handle. 100 // Check that object isn't deleted until we crank the sogd handle.
87 SceneObjectPart retrievedPart = scene.GetSceneObjectPart(part.LocalId); 101 SceneObjectPart retrievedPart = scene.GetSceneObjectPart(so.LocalId);
88 Assert.That(retrievedPart, Is.Not.Null); 102 Assert.That(retrievedPart, Is.Not.Null);
89 Assert.That(retrievedPart.ParentGroup.IsDeleted, Is.False); 103 Assert.That(retrievedPart.ParentGroup.IsDeleted, Is.False);
90 104
91 sogd.InventoryDeQueueAndDelete(); 105 sogd.InventoryDeQueueAndDelete();
92 106
93 SceneObjectPart retrievedPart2 = scene.GetSceneObjectPart(part.LocalId); 107 SceneObjectPart retrievedPart2 = scene.GetSceneObjectPart(so.LocalId);
94 Assert.That(retrievedPart2, Is.Null); 108 Assert.That(retrievedPart2, Is.Null);
109
110 Assert.That(client.ReceivedKills.Count, Is.EqualTo(1));
111 Assert.That(client.ReceivedKills[0], Is.EqualTo(soLocalId));
112 }
113
114 /// <summary>
115 /// Test that child and root agents correctly receive KillObject notifications.
116 /// </summary>
117 [Test]
118 public void TestDeRezSceneObjectToAgents()
119 {
120 TestHelpers.InMethod();
121// TestHelpers.EnableLogging();
122
123 SceneHelpers sh = new SceneHelpers();
124 TestScene sceneA = sh.SetupScene("sceneA", TestHelpers.ParseTail(0x100), 1000, 1000);
125 TestScene sceneB = sh.SetupScene("sceneB", TestHelpers.ParseTail(0x200), 1000, 999);
126
127 // We need this so that the creation of the root client for userB in sceneB can trigger the creation of a child client in sceneA
128 LocalSimulationConnectorModule lscm = new LocalSimulationConnectorModule();
129 EntityTransferModule etmB = new EntityTransferModule();
130 IConfigSource config = new IniConfigSource();
131 IConfig modulesConfig = config.AddConfig("Modules");
132 modulesConfig.Set("EntityTransferModule", etmB.Name);
133 modulesConfig.Set("SimulationServices", lscm.Name);
134 SceneHelpers.SetupSceneModules(new Scene[] { sceneA, sceneB }, config, lscm);
135 SceneHelpers.SetupSceneModules(sceneB, config, etmB);
136
137 // We need this for derez
138 SceneHelpers.SetupSceneModules(sceneA, new PermissionsModule());
139
140 UserAccount uaA = UserAccountHelpers.CreateUserWithInventory(sceneA, "Andy", "AAA", 0x1, "");
141 UserAccount uaB = UserAccountHelpers.CreateUserWithInventory(sceneA, "Brian", "BBB", 0x2, "");
142
143 TestClient clientA = (TestClient)SceneHelpers.AddScenePresence(sceneA, uaA).ControllingClient;
144
145 // This is the more long-winded route we have to take to get a child client created for userB in sceneA
146 // rather than just calling AddScenePresence() as for userA
147 AgentCircuitData acd = SceneHelpers.GenerateAgentData(uaB);
148 TestClient clientB = new TestClient(acd, sceneB);
149 List<TestClient> childClientsB = new List<TestClient>();
150 EntityTransferHelpers.SetUpInformClientOfNeighbour(clientB, childClientsB);
151
152 SceneHelpers.AddScenePresence(sceneB, clientB, acd);
153
154 SceneObjectGroup so = SceneHelpers.AddSceneObject(sceneA);
155 uint soLocalId = so.LocalId;
156
157 sceneA.DeleteSceneObject(so, false);
158
159 Assert.That(clientA.ReceivedKills.Count, Is.EqualTo(1));
160 Assert.That(clientA.ReceivedKills[0], Is.EqualTo(soLocalId));
161
162 Assert.That(childClientsB[0].ReceivedKills.Count, Is.EqualTo(1));
163 Assert.That(childClientsB[0].ReceivedKills[0], Is.EqualTo(soLocalId));
95 } 164 }
96 165
97 /// <summary> 166 /// <summary>
98 /// Test deleting an object from a scene where the deleter is not the owner 167 /// Test deleting an object from a scene where the deleter is not the owner
99 /// </summary> 168 /// </summary>
100 /// 169 /// <remarks>
101 /// This test assumes that the deleter is not a god. 170 /// This test assumes that the deleter is not a god.
171 /// </remarks>
102 [Test] 172 [Test]
103 public void TestDeRezSceneObjectNotOwner() 173 public void TestDeRezSceneObjectNotOwner()
104 { 174 {
@@ -109,10 +179,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
109 UUID objectOwnerId = UUID.Parse("20000000-0000-0000-0000-000000000001"); 179 UUID objectOwnerId = UUID.Parse("20000000-0000-0000-0000-000000000001");
110 180
111 TestScene scene = new SceneHelpers().SetupScene(); 181 TestScene scene = new SceneHelpers().SetupScene();
112 IConfigSource configSource = new IniConfigSource(); 182 SceneHelpers.SetupSceneModules(scene, new PermissionsModule());
113 IConfig config = configSource.AddConfig("Startup");
114 config.Set("serverside_object_permissions", true);
115 SceneHelpers.SetupSceneModules(scene, configSource, new object[] { new PermissionsModule() });
116 IClientAPI client = SceneHelpers.AddScenePresence(scene, userId).ControllingClient; 183 IClientAPI client = SceneHelpers.AddScenePresence(scene, userId).ControllingClient;
117 184
118 // Turn off the timer on the async sog deleter - we'll crank it by hand for this test. 185 // Turn off the timer on the async sog deleter - we'll crank it by hand for this test.
diff --git a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceCrossingTests.cs b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceCrossingTests.cs
index 8775949..5a72239 100644
--- a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceCrossingTests.cs
+++ b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceCrossingTests.cs
@@ -95,11 +95,11 @@ namespace OpenSim.Region.Framework.Scenes.Tests
95 SceneHelpers.SetupSceneModules(sceneB, config, new CapabilitiesModule(), etmB); 95 SceneHelpers.SetupSceneModules(sceneB, config, new CapabilitiesModule(), etmB);
96 96
97 AgentCircuitData acd = SceneHelpers.GenerateAgentData(userId); 97 AgentCircuitData acd = SceneHelpers.GenerateAgentData(userId);
98 TestClient tc = new TestClient(acd, sceneA, sh.SceneManager); 98 TestClient tc = new TestClient(acd, sceneA);
99 List<TestClient> destinationTestClients = new List<TestClient>(); 99 List<TestClient> destinationTestClients = new List<TestClient>();
100 EntityTransferHelpers.SetUpInformClientOfNeighbour(tc, destinationTestClients); 100 EntityTransferHelpers.SetUpInformClientOfNeighbour(tc, destinationTestClients);
101 101
102 ScenePresence originalSp = SceneHelpers.AddScenePresence(sceneA, tc, acd, sh.SceneManager); 102 ScenePresence originalSp = SceneHelpers.AddScenePresence(sceneA, tc, acd);
103 originalSp.AbsolutePosition = new Vector3(128, 32, 10); 103 originalSp.AbsolutePosition = new Vector3(128, 32, 10);
104 104
105// originalSp.Flying = true; 105// originalSp.Flying = true;
diff --git a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTeleportTests.cs b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTeleportTests.cs
index de4458d..297c66b 100644
--- a/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTeleportTests.cs
+++ b/OpenSim/Region/Framework/Scenes/Tests/ScenePresenceTeleportTests.cs
@@ -139,7 +139,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
139 Vector3 teleportPosition = new Vector3(10, 11, 12); 139 Vector3 teleportPosition = new Vector3(10, 11, 12);
140 Vector3 teleportLookAt = new Vector3(20, 21, 22); 140 Vector3 teleportLookAt = new Vector3(20, 21, 22);
141 141
142 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId, sh.SceneManager); 142 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId);
143 sp.AbsolutePosition = new Vector3(30, 31, 32); 143 sp.AbsolutePosition = new Vector3(30, 31, 32);
144 144
145 List<TestClient> destinationTestClients = new List<TestClient>(); 145 List<TestClient> destinationTestClients = new List<TestClient>();
@@ -224,7 +224,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
224 Vector3 teleportPosition = new Vector3(10, 11, 12); 224 Vector3 teleportPosition = new Vector3(10, 11, 12);
225 Vector3 teleportLookAt = new Vector3(20, 21, 22); 225 Vector3 teleportLookAt = new Vector3(20, 21, 22);
226 226
227 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId, sh.SceneManager); 227 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId);
228 sp.AbsolutePosition = preTeleportPosition; 228 sp.AbsolutePosition = preTeleportPosition;
229 229
230 // Make sceneB return false on query access 230 // Make sceneB return false on query access
@@ -300,7 +300,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
300 Vector3 teleportPosition = new Vector3(10, 11, 12); 300 Vector3 teleportPosition = new Vector3(10, 11, 12);
301 Vector3 teleportLookAt = new Vector3(20, 21, 22); 301 Vector3 teleportLookAt = new Vector3(20, 21, 22);
302 302
303 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId, sh.SceneManager); 303 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId);
304 sp.AbsolutePosition = preTeleportPosition; 304 sp.AbsolutePosition = preTeleportPosition;
305 305
306 // Make sceneB refuse CreateAgent 306 // Make sceneB refuse CreateAgent
@@ -389,7 +389,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
389 Vector3 teleportPosition = new Vector3(10, 11, 12); 389 Vector3 teleportPosition = new Vector3(10, 11, 12);
390 Vector3 teleportLookAt = new Vector3(20, 21, 22); 390 Vector3 teleportLookAt = new Vector3(20, 21, 22);
391 391
392 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId, sh.SceneManager); 392 ScenePresence sp = SceneHelpers.AddScenePresence(sceneA, userId);
393 sp.AbsolutePosition = preTeleportPosition; 393 sp.AbsolutePosition = preTeleportPosition;
394 394
395 sceneA.RequestTeleportLocation( 395 sceneA.RequestTeleportLocation(
@@ -428,7 +428,7 @@ namespace OpenSim.Region.Framework.Scenes.Tests
428 public void TestSameSimulatorNeighbouringRegions() 428 public void TestSameSimulatorNeighbouringRegions()
429 { 429 {
430 TestHelpers.InMethod(); 430 TestHelpers.InMethod();
431 TestHelpers.EnableLogging(); 431// TestHelpers.EnableLogging();
432 432
433 UUID userId = TestHelpers.ParseTail(0x1); 433 UUID userId = TestHelpers.ParseTail(0x1);
434 434
@@ -458,11 +458,11 @@ namespace OpenSim.Region.Framework.Scenes.Tests
458 Vector3 teleportLookAt = new Vector3(20, 21, 22); 458 Vector3 teleportLookAt = new Vector3(20, 21, 22);
459 459
460 AgentCircuitData acd = SceneHelpers.GenerateAgentData(userId); 460 AgentCircuitData acd = SceneHelpers.GenerateAgentData(userId);
461 TestClient tc = new TestClient(acd, sceneA, sh.SceneManager); 461 TestClient tc = new TestClient(acd, sceneA);
462 List<TestClient> destinationTestClients = new List<TestClient>(); 462 List<TestClient> destinationTestClients = new List<TestClient>();
463 EntityTransferHelpers.SetUpInformClientOfNeighbour(tc, destinationTestClients); 463 EntityTransferHelpers.SetUpInformClientOfNeighbour(tc, destinationTestClients);
464 464
465 ScenePresence beforeSceneASp = SceneHelpers.AddScenePresence(sceneA, tc, acd, sh.SceneManager); 465 ScenePresence beforeSceneASp = SceneHelpers.AddScenePresence(sceneA, tc, acd);
466 beforeSceneASp.AbsolutePosition = new Vector3(30, 31, 32); 466 beforeSceneASp.AbsolutePosition = new Vector3(30, 31, 32);
467 467
468 Assert.That(beforeSceneASp, Is.Not.Null); 468 Assert.That(beforeSceneASp, Is.Not.Null);
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
index 550f089..f7b837c 100644
--- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
+++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
@@ -955,7 +955,7 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server
955 955
956 } 956 }
957 957
958 public void SendKillObject(ulong regionHandle, List<uint> localID) 958 public void SendKillObject(List<uint> localID)
959 { 959 {
960 960
961 } 961 }
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
index d1bb547..a6a53aa 100644
--- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
+++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
@@ -596,7 +596,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
596 596
597 } 597 }
598 598
599 public virtual void SendKillObject(ulong regionHandle, List<uint> localID) 599 public virtual void SendKillObject(List<uint> localID)
600 { 600 {
601 } 601 }
602 602
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs b/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
index f89c52f..2dc029e 100755
--- a/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSShapes.cs
@@ -368,9 +368,10 @@ public class BSShapeMesh : BSShape
368 368
369 // Check to see if mesh was created (might require an asset). 369 // Check to see if mesh was created (might require an asset).
370 newShape = VerifyMeshCreated(physicsScene, newShape, prim); 370 newShape = VerifyMeshCreated(physicsScene, newShape, prim);
371 if (!newShape.isNativeShape) 371 if (!newShape.isNativeShape || prim.PrimAssetState == BSPhysObject.PrimAssetCondition.Failed)
372 { 372 {
373 // If a mesh was what was created, remember the built shape for later sharing. 373 // If a mesh was what was created, remember the built shape for later sharing.
374 // Also note that if meshing failed we put it in the mesh list as there is nothing else to do about the mesh.
374 Meshes.Add(newMeshKey, retMesh); 375 Meshes.Add(newMeshKey, retMesh);
375 } 376 }
376 377
@@ -483,8 +484,11 @@ public class BSShapeMesh : BSShape
483 } 484 }
484 else 485 else
485 { 486 {
487 // Force the asset condition to 'failed' so we won't try to keep fetching and processing this mesh.
488 prim.PrimAssetState = BSPhysObject.PrimAssetCondition.Failed;
486 physicsScene.Logger.DebugFormat("{0} All mesh triangles degenerate. Prim {1} at {2} in {3}", 489 physicsScene.Logger.DebugFormat("{0} All mesh triangles degenerate. Prim {1} at {2} in {3}",
487 LogHeader, prim.PhysObjectName, prim.RawPosition, physicsScene.Name); 490 LogHeader, prim.PhysObjectName, prim.RawPosition, physicsScene.Name);
491 physicsScene.DetailLog("{0},BSShapeMesh.CreatePhysicalMesh,allDegenerate,key={1}", prim.LocalID, newMeshKey);
488 } 492 }
489 } 493 }
490 newShape.shapeKey = newMeshKey; 494 newShape.shapeKey = newMeshKey;
@@ -523,7 +527,7 @@ public class BSShapeHull : BSShape
523 527
524 // Check to see if hull was created (might require an asset). 528 // Check to see if hull was created (might require an asset).
525 newShape = VerifyMeshCreated(physicsScene, newShape, prim); 529 newShape = VerifyMeshCreated(physicsScene, newShape, prim);
526 if (!newShape.isNativeShape) 530 if (!newShape.isNativeShape || prim.PrimAssetState == BSPhysObject.PrimAssetCondition.Failed)
527 { 531 {
528 // If a mesh was what was created, remember the built shape for later sharing. 532 // If a mesh was what was created, remember the built shape for later sharing.
529 Hulls.Add(newHullKey, retHull); 533 Hulls.Add(newHullKey, retHull);