aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs')
-rw-r--r--OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs17
1 files changed, 16 insertions, 1 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs b/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs
index b169d9a..985c8a3 100644
--- a/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs
+++ b/OpenSim/Region/Environment/Scenes/Tests/SceneTestUtils.cs
@@ -111,17 +111,32 @@ namespace OpenSim.Region.Environment.Scenes.Tests
111 111
112 return client; 112 return client;
113 } 113 }
114
115 /// <summary>
116 /// Add a test object
117 /// </summary>
118 /// <param name="scene"></param>
119 /// <returns></returns>
120 public static SceneObjectPart AddSceneObject(Scene scene)
121 {
122 return AddSceneObject(scene, null);
123 }
114 124
115 /// <summary> 125 /// <summary>
116 /// Add a test object 126 /// Add a test object
117 /// </summary> 127 /// </summary>
118 /// <param name="scene"></param> 128 /// <param name="scene"></param>
129 /// <param name="name"></param>
119 /// <returns></returns> 130 /// <returns></returns>
120 public static SceneObjectPart AddSceneObject(Scene scene) 131 public static SceneObjectPart AddSceneObject(Scene scene, string name)
121 { 132 {
122 SceneObjectGroup sceneObject = new SceneObjectGroup(); 133 SceneObjectGroup sceneObject = new SceneObjectGroup();
123 SceneObjectPart part 134 SceneObjectPart part
124 = new SceneObjectPart(UUID.Zero, PrimitiveBaseShape.Default, Vector3.Zero, Quaternion.Identity, Vector3.Zero); 135 = new SceneObjectPart(UUID.Zero, PrimitiveBaseShape.Default, Vector3.Zero, Quaternion.Identity, Vector3.Zero);
136
137 if (name != null)
138 part.Name = name;
139
125 //part.UpdatePrimFlags(false, false, true); 140 //part.UpdatePrimFlags(false, false, true);
126 part.ObjectFlags |= (uint)PrimFlags.Phantom; 141 part.ObjectFlags |= (uint)PrimFlags.Phantom;
127 sceneObject.SetRootPart(part); 142 sceneObject.SetRootPart(part);