diff options
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs b/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs index 468a4ad..b169d9a 100644 --- a/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs +++ b/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs | |||
@@ -97,9 +97,16 @@ namespace OpenSim.Region.Environment.Scenes.Tests | |||
97 | agent.startpos = Vector3.Zero; | 97 | agent.startpos = Vector3.Zero; |
98 | agent.CapsPath = "http://wibble.com"; | 98 | agent.CapsPath = "http://wibble.com"; |
99 | 99 | ||
100 | // We emulate the proper login sequence here by doing things in three stages | ||
101 | // Stage 1: simulate login by telling the scene to expect a new user connection | ||
100 | scene.NewUserConnection(agent); | 102 | scene.NewUserConnection(agent); |
103 | |||
104 | // Stage 2: add the new client as a child agent to the scene | ||
101 | IClientAPI client = new TestClient(agent); | 105 | IClientAPI client = new TestClient(agent); |
102 | scene.AddNewClient(client, true); | 106 | scene.AddNewClient(client); |
107 | |||
108 | // Stage 3: Invoke agent crossing, which converts the child agent into a root agent (with appearance, | ||
109 | // inventory, etc.) | ||
103 | scene.AgentCrossing(agent.AgentID, new Vector3(90, 90, 90), false); | 110 | scene.AgentCrossing(agent.AgentID, new Vector3(90, 90, 90), false); |
104 | 111 | ||
105 | return client; | 112 | return client; |