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/NPCAvatar.cs | |
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 '')
-rw-r--r-- | OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index 84055cc..5f4f937 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | |||
@@ -42,13 +42,15 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
42 | private readonly Vector3 m_startPos; | 42 | private readonly Vector3 m_startPos; |
43 | private readonly UUID m_uuid = UUID.Random(); | 43 | private readonly UUID m_uuid = UUID.Random(); |
44 | private readonly Scene m_scene; | 44 | private readonly Scene m_scene; |
45 | private readonly UUID m_ownerID; | ||
45 | 46 | ||
46 | public NPCAvatar(string firstname, string lastname, Vector3 position, Scene scene) | 47 | public NPCAvatar(string firstname, string lastname, Vector3 position, UUID ownerID, Scene scene) |
47 | { | 48 | { |
48 | m_firstname = firstname; | 49 | m_firstname = firstname; |
49 | m_lastname = lastname; | 50 | m_lastname = lastname; |
50 | m_startPos = position; | 51 | m_startPos = position; |
51 | m_scene = scene; | 52 | m_scene = scene; |
53 | m_ownerID = ownerID; | ||
52 | } | 54 | } |
53 | 55 | ||
54 | public IScene Scene | 56 | public IScene Scene |
@@ -56,6 +58,11 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
56 | get { return m_scene; } | 58 | get { return m_scene; } |
57 | } | 59 | } |
58 | 60 | ||
61 | public UUID OwnerID | ||
62 | { | ||
63 | get { return m_ownerID; } | ||
64 | } | ||
65 | |||
59 | public ISceneAgent SceneAgent { get { throw new NotImplementedException(); } } | 66 | public ISceneAgent SceneAgent { get { throw new NotImplementedException(); } } |
60 | 67 | ||
61 | public void Say(string message) | 68 | public void Say(string message) |