diff options
author | Melanie | 2012-01-06 22:35:06 +0000 |
---|---|---|
committer | Melanie | 2012-01-06 22:35:06 +0000 |
commit | 7518b075b76fea062971a9e5fb716118130ebe43 (patch) | |
tree | df4449fdfe02de0b706cac6024603e4ebabdb256 /OpenSim/Region/OptionalModules/World/NPC/Tests | |
parent | eliminate a few tabs from OpenSimDefaults.ini (diff) | |
download | opensim-SC-7518b075b76fea062971a9e5fb716118130ebe43.zip opensim-SC-7518b075b76fea062971a9e5fb716118130ebe43.tar.gz opensim-SC-7518b075b76fea062971a9e5fb716118130ebe43.tar.bz2 opensim-SC-7518b075b76fea062971a9e5fb716118130ebe43.tar.xz |
Add osNpcCreateOwned to create an owned NPC. Those can be sensed only by the owner, can be destroyed only by the owner and only the owner can save their appearance. Added "NPC" as a flag to llSensor to sense NPCs and exclude them from "AGENT" results.
Diffstat (limited to 'OpenSim/Region/OptionalModules/World/NPC/Tests')
-rw-r--r-- | OpenSim/Region/OptionalModules/World/NPC/Tests/NPCModuleTests.cs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/OpenSim/Region/OptionalModules/World/NPC/Tests/NPCModuleTests.cs b/OpenSim/Region/OptionalModules/World/NPC/Tests/NPCModuleTests.cs index 9c66b25..571d33d 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/Tests/NPCModuleTests.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/Tests/NPCModuleTests.cs | |||
@@ -109,7 +109,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC.Tests | |||
109 | afm.SetAppearance(sp, originalTe, null); | 109 | afm.SetAppearance(sp, originalTe, null); |
110 | 110 | ||
111 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); | 111 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); |
112 | UUID npcId = npcModule.CreateNPC("John", "Smith", new Vector3(128, 128, 30), scene, sp.Appearance); | 112 | UUID npcId = npcModule.CreateNPC("John", "Smith", new Vector3(128, 128, 30), UUID.Zero, scene, sp.Appearance); |
113 | 113 | ||
114 | ScenePresence npc = scene.GetScenePresence(npcId); | 114 | ScenePresence npc = scene.GetScenePresence(npcId); |
115 | 115 | ||
@@ -137,7 +137,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC.Tests | |||
137 | am.RezSingleAttachmentFromInventory(sp, attItemId, (uint)AttachmentPoint.Chest); | 137 | am.RezSingleAttachmentFromInventory(sp, attItemId, (uint)AttachmentPoint.Chest); |
138 | 138 | ||
139 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); | 139 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); |
140 | UUID npcId = npcModule.CreateNPC("John", "Smith", new Vector3(128, 128, 30), scene, sp.Appearance); | 140 | UUID npcId = npcModule.CreateNPC("John", "Smith", new Vector3(128, 128, 30), UUID.Zero, scene, sp.Appearance); |
141 | 141 | ||
142 | ScenePresence npc = scene.GetScenePresence(npcId); | 142 | ScenePresence npc = scene.GetScenePresence(npcId); |
143 | 143 | ||
@@ -169,7 +169,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC.Tests | |||
169 | 169 | ||
170 | Vector3 startPos = new Vector3(128, 128, 30); | 170 | Vector3 startPos = new Vector3(128, 128, 30); |
171 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); | 171 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); |
172 | UUID npcId = npcModule.CreateNPC("John", "Smith", startPos, scene, sp.Appearance); | 172 | UUID npcId = npcModule.CreateNPC("John", "Smith", startPos, UUID.Zero, scene, sp.Appearance); |
173 | 173 | ||
174 | ScenePresence npc = scene.GetScenePresence(npcId); | 174 | ScenePresence npc = scene.GetScenePresence(npcId); |
175 | Assert.That(npc.AbsolutePosition, Is.EqualTo(startPos)); | 175 | Assert.That(npc.AbsolutePosition, Is.EqualTo(startPos)); |
@@ -240,7 +240,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC.Tests | |||
240 | 240 | ||
241 | Vector3 startPos = new Vector3(128, 128, 30); | 241 | Vector3 startPos = new Vector3(128, 128, 30); |
242 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); | 242 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); |
243 | UUID npcId = npcModule.CreateNPC("John", "Smith", startPos, scene, sp.Appearance); | 243 | UUID npcId = npcModule.CreateNPC("John", "Smith", startPos, UUID.Zero, scene, sp.Appearance); |
244 | 244 | ||
245 | ScenePresence npc = scene.GetScenePresence(npcId); | 245 | ScenePresence npc = scene.GetScenePresence(npcId); |
246 | SceneObjectPart part = SceneHelpers.AddSceneObject(scene); | 246 | SceneObjectPart part = SceneHelpers.AddSceneObject(scene); |
@@ -273,7 +273,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC.Tests | |||
273 | Vector3 startPos = new Vector3(1, 1, 1); | 273 | Vector3 startPos = new Vector3(1, 1, 1); |
274 | 274 | ||
275 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); | 275 | INPCModule npcModule = scene.RequestModuleInterface<INPCModule>(); |
276 | UUID npcId = npcModule.CreateNPC("John", "Smith", startPos, scene, sp.Appearance); | 276 | UUID npcId = npcModule.CreateNPC("John", "Smith", startPos, UUID.Zero, scene, sp.Appearance); |
277 | 277 | ||
278 | ScenePresence npc = scene.GetScenePresence(npcId); | 278 | ScenePresence npc = scene.GetScenePresence(npcId); |
279 | SceneObjectPart part = SceneHelpers.AddSceneObject(scene); | 279 | SceneObjectPart part = SceneHelpers.AddSceneObject(scene); |