diff options
author | Teravus Ovares | 2008-02-23 11:42:55 +0000 |
---|---|---|
committer | Teravus Ovares | 2008-02-23 11:42:55 +0000 |
commit | 27508c1ad87786935dbf28aa217bcbe55a9aa645 (patch) | |
tree | 0ae701c00cb8e92ab6416fb6688afeb536960b6e /OpenSim/Region/Environment/Scenes | |
parent | * Reduced size of 'startup complete message' by several thousand lines. (diff) | |
download | opensim-SC_OLD-27508c1ad87786935dbf28aa217bcbe55a9aa645.zip opensim-SC_OLD-27508c1ad87786935dbf28aa217bcbe55a9aa645.tar.gz opensim-SC_OLD-27508c1ad87786935dbf28aa217bcbe55a9aa645.tar.bz2 opensim-SC_OLD-27508c1ad87786935dbf28aa217bcbe55a9aa645.tar.xz |
* Added Support within the ODEPlugin for Selected. Which means that;
* When you select a physical prim, it stops while you've got it selected.
* When you move or alter a prim in some manner, it doesn't become collidable until you de-select it
* When you select a prim, it doesn't become temporarily 'phantom' until you make some change to it while it's selected. (this prevents accidental selections in prim floor from causing it to go phantom on you(but don't move it or you'll fall))
* There's one major difference, and that's a physical object won't stop if you don't have permission to edit it. This prevents people who don't have edit permissions on a prim from stopping it while it's moving.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs | 20 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | 8 |
2 files changed, 22 insertions, 6 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs b/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs index 7c0cd77..c393479 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.PacketHandlers.cs | |||
@@ -104,11 +104,16 @@ namespace OpenSim.Region.Environment.Scenes | |||
104 | { | 104 | { |
105 | if (ent is SceneObjectGroup) | 105 | if (ent is SceneObjectGroup) |
106 | { | 106 | { |
107 | |||
107 | if (((SceneObjectGroup) ent).LocalId == primLocalID) | 108 | if (((SceneObjectGroup) ent).LocalId == primLocalID) |
108 | { | 109 | { |
109 | ((SceneObjectGroup) ent).GetProperties(remoteClient); | 110 | // A prim is only tainted if it's allowed to be edited by the person clicking it. |
110 | ((SceneObjectGroup) ent).IsSelected = true; | 111 | if (m_permissionManager.CanEditObjectPosition(remoteClient.AgentId, ((SceneObjectGroup)ent).UUID) || m_permissionManager.CanEditObject(remoteClient.AgentId, ((SceneObjectGroup)ent).UUID)) |
111 | LandManager.setPrimsTainted(); | 112 | { |
113 | ((SceneObjectGroup) ent).GetProperties(remoteClient); | ||
114 | ((SceneObjectGroup) ent).IsSelected = true; | ||
115 | LandManager.setPrimsTainted(); | ||
116 | } | ||
112 | break; | 117 | break; |
113 | } | 118 | } |
114 | } | 119 | } |
@@ -130,9 +135,12 @@ namespace OpenSim.Region.Environment.Scenes | |||
130 | { | 135 | { |
131 | if (((SceneObjectGroup) ent).LocalId == primLocalID) | 136 | if (((SceneObjectGroup) ent).LocalId == primLocalID) |
132 | { | 137 | { |
133 | ((SceneObjectGroup) ent).IsSelected = false; | 138 | if (m_permissionManager.CanEditObjectPosition(remoteClient.AgentId, ((SceneObjectGroup)ent).UUID) || m_permissionManager.CanEditObject(remoteClient.AgentId, ((SceneObjectGroup)ent).UUID)) |
134 | LandManager.setPrimsTainted(); | 139 | { |
135 | break; | 140 | ((SceneObjectGroup) ent).IsSelected = false; |
141 | LandManager.setPrimsTainted(); | ||
142 | break; | ||
143 | } | ||
136 | } | 144 | } |
137 | } | 145 | } |
138 | } | 146 | } |
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs index 8fd9edb..801e614 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | |||
@@ -203,6 +203,14 @@ namespace OpenSim.Region.Environment.Scenes | |||
203 | if (m_rootPart.PhysActor != null) | 203 | if (m_rootPart.PhysActor != null) |
204 | { | 204 | { |
205 | m_rootPart.PhysActor.Selected = value; | 205 | m_rootPart.PhysActor.Selected = value; |
206 | // Pass it on to the children. | ||
207 | foreach (SceneObjectPart child in Children.Values) | ||
208 | { | ||
209 | if (child.PhysActor != null) | ||
210 | { | ||
211 | child.PhysActor.Selected = value; | ||
212 | } | ||
213 | } | ||
206 | } | 214 | } |
207 | } | 215 | } |
208 | } | 216 | } |