diff options
author | Melanie Thielker | 2008-11-17 21:44:09 +0000 |
---|---|---|
committer | Melanie Thielker | 2008-11-17 21:44:09 +0000 |
commit | a8e40bed52d9db6d099843ffb796cae266064c14 (patch) | |
tree | 58cdf119d8b13bed007051333937b4f2ab4bf999 /OpenSim/Region/Environment | |
parent | * Remove Appdomain code in XEngine.cs (diff) | |
download | opensim-SC-a8e40bed52d9db6d099843ffb796cae266064c14.zip opensim-SC-a8e40bed52d9db6d099843ffb796cae266064c14.tar.gz opensim-SC-a8e40bed52d9db6d099843ffb796cae266064c14.tar.bz2 opensim-SC-a8e40bed52d9db6d099843ffb796cae266064c14.tar.xz |
Set group on newly rezzed objects to the rezzer's (or rezzing object's)
group
Diffstat (limited to 'OpenSim/Region/Environment')
4 files changed, 28 insertions, 1 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index 0c217dd..e46b13c 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |||
@@ -2031,6 +2031,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
2031 | 2031 | ||
2032 | List<SceneObjectPart> partList = new List<SceneObjectPart>(group.Children.Values); | 2032 | List<SceneObjectPart> partList = new List<SceneObjectPart>(group.Children.Values); |
2033 | 2033 | ||
2034 | group.SetGroup(remoteClient.ActiveGroupId, remoteClient); | ||
2034 | if (rootPart.OwnerID != item.Owner) | 2035 | if (rootPart.OwnerID != item.Owner) |
2035 | { | 2036 | { |
2036 | //Need to kill the for sale here | 2037 | //Need to kill the for sale here |
@@ -2148,6 +2149,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
2148 | 2149 | ||
2149 | List<SceneObjectPart> partList = new List<SceneObjectPart>(group.Children.Values); | 2150 | List<SceneObjectPart> partList = new List<SceneObjectPart>(group.Children.Values); |
2150 | 2151 | ||
2152 | group.SetGroup(sourcePart.GroupID, null); | ||
2153 | |||
2151 | if (rootPart.OwnerID != item.OwnerID) | 2154 | if (rootPart.OwnerID != item.OwnerID) |
2152 | { | 2155 | { |
2153 | if (ExternalChecks.ExternalChecksPropagatePermissions()) | 2156 | if (ExternalChecks.ExternalChecksPropagatePermissions()) |
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs index bf430b9..380557b 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | |||
@@ -2825,6 +2825,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
2825 | foreach (SceneObjectPart part in m_parts.Values) | 2825 | foreach (SceneObjectPart part in m_parts.Values) |
2826 | { | 2826 | { |
2827 | part.SetGroup(GroupID, client); | 2827 | part.SetGroup(GroupID, client); |
2828 | part.ChangeInventoryGroup(GroupID); | ||
2828 | } | 2829 | } |
2829 | 2830 | ||
2830 | HasGroupChanged = true; | 2831 | HasGroupChanged = true; |
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs index 4209e4a..ba638e5 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs | |||
@@ -123,6 +123,28 @@ namespace OpenSim.Region.Environment.Scenes | |||
123 | } | 123 | } |
124 | } | 124 | } |
125 | 125 | ||
126 | public void ChangeInventoryGroup(UUID groupID) | ||
127 | { | ||
128 | lock (TaskInventory) | ||
129 | { | ||
130 | if (0 == TaskInventory.Count) | ||
131 | { | ||
132 | return; | ||
133 | } | ||
134 | |||
135 | HasInventoryChanged = true; | ||
136 | ParentGroup.HasGroupChanged = true; | ||
137 | IList<TaskInventoryItem> items = new List<TaskInventoryItem>(TaskInventory.Values); | ||
138 | foreach (TaskInventoryItem item in items) | ||
139 | { | ||
140 | if (groupID != item.GroupID) | ||
141 | { | ||
142 | item.GroupID = groupID; | ||
143 | } | ||
144 | } | ||
145 | } | ||
146 | } | ||
147 | |||
126 | /// <summary> | 148 | /// <summary> |
127 | /// Start all the scripts contained in this prim's inventory | 149 | /// Start all the scripts contained in this prim's inventory |
128 | /// </summary> | 150 | /// </summary> |
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs index deb7f89..c7862ec 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs | |||
@@ -2304,7 +2304,8 @@ if (m_shape != null) { | |||
2304 | public void SetGroup(UUID groupID, IClientAPI client) | 2304 | public void SetGroup(UUID groupID, IClientAPI client) |
2305 | { | 2305 | { |
2306 | _groupID = groupID; | 2306 | _groupID = groupID; |
2307 | GetProperties(client); | 2307 | if (client != null) |
2308 | GetProperties(client); | ||
2308 | m_updateFlag = 2; | 2309 | m_updateFlag = 2; |
2309 | } | 2310 | } |
2310 | 2311 | ||