diff options
author | Justin Clarke Casey | 2008-03-18 20:11:35 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2008-03-18 20:11:35 +0000 |
commit | f77ab461846410297489c07b7c5029b099e119f3 (patch) | |
tree | 84916f1ea6338bfc9a6507cbda3b7e47e63fb0da /OpenSim/Region/Environment/Scenes | |
parent | * Stop grid inventory network failures crashing the client session (diff) | |
download | opensim-SC_OLD-f77ab461846410297489c07b7c5029b099e119f3.zip opensim-SC_OLD-f77ab461846410297489c07b7c5029b099e119f3.tar.gz opensim-SC_OLD-f77ab461846410297489c07b7c5029b099e119f3.tar.bz2 opensim-SC_OLD-f77ab461846410297489c07b7c5029b099e119f3.tar.xz |
* Stop (which currently removes) all scripts in an object when that object is deleted from the region
Diffstat (limited to 'OpenSim/Region/Environment/Scenes')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | 11 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs | 3 |
2 files changed, 14 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs index 1a672e8..8b30b58 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | |||
@@ -1818,8 +1818,19 @@ namespace OpenSim.Region.Environment.Scenes | |||
1818 | } | 1818 | } |
1819 | } | 1819 | } |
1820 | 1820 | ||
1821 | /// <summary> | ||
1822 | /// Delete all the parts in this group. | ||
1823 | /// </summary> | ||
1821 | public void DeleteParts() | 1824 | public void DeleteParts() |
1822 | { | 1825 | { |
1826 | lock (m_parts) | ||
1827 | { | ||
1828 | foreach (SceneObjectPart part in m_parts.Values) | ||
1829 | { | ||
1830 | part.StopScripts(); | ||
1831 | } | ||
1832 | } | ||
1833 | |||
1823 | m_rootPart = null; | 1834 | m_rootPart = null; |
1824 | m_parts.Clear(); | 1835 | m_parts.Clear(); |
1825 | } | 1836 | } |
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs index deeb0ad..f7e82a5 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs | |||
@@ -126,6 +126,9 @@ namespace OpenSim.Region.Environment.Scenes | |||
126 | } | 126 | } |
127 | } | 127 | } |
128 | 128 | ||
129 | /// <summary> | ||
130 | /// Stop all the scripts in this prim. | ||
131 | /// </summary> | ||
129 | public void StopScripts() | 132 | public void StopScripts() |
130 | { | 133 | { |
131 | lock (m_taskInventory) | 134 | lock (m_taskInventory) |