aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment
diff options
context:
space:
mode:
authorTeravus Ovares2008-02-06 09:53:59 +0000
committerTeravus Ovares2008-02-06 09:53:59 +0000
commitd842699ef3e99c9815781a3e5adacdfcfcf6ff94 (patch)
tree6cc24f48754042b5bfc7c7527f70fa9d6a6ab8e0 /OpenSim/Region/Environment
parent* Added the ability to start and stop all scripts in the simulator using the ... (diff)
downloadopensim-SC_OLD-d842699ef3e99c9815781a3e5adacdfcfcf6ff94.zip
opensim-SC_OLD-d842699ef3e99c9815781a3e5adacdfcfcf6ff94.tar.gz
opensim-SC_OLD-d842699ef3e99c9815781a3e5adacdfcfcf6ff94.tar.bz2
opensim-SC_OLD-d842699ef3e99c9815781a3e5adacdfcfcf6ff94.tar.xz
* Put the script run limiter on the SceneObjectPart as otherwise you can drop scripts in prim and they'll still run with scripts disabled.
Diffstat (limited to 'OpenSim/Region/Environment')
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs28
1 files changed, 15 insertions, 13 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs
index e8ffe0e..a9eba00 100644
--- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.Inventory.cs
@@ -151,21 +151,23 @@ namespace OpenSim.Region.Environment.Scenes
151// "[PRIMINVENTORY]: " + 151// "[PRIMINVENTORY]: " +
152// "Starting script {0}, {1} in prim {2}, {3}", 152// "Starting script {0}, {1} in prim {2}, {3}",
153// item.Name, item.ItemID, Name, UUID)); 153// item.Name, item.ItemID, Name, UUID));
154 154 if (!((m_parentGroup.Scene.RegionInfo.EstateSettings.regionFlags & Simulator.RegionFlags.SkipScripts) == Simulator.RegionFlags.SkipScripts))
155 AssetBase rezAsset = m_parentGroup.Scene.AssetCache.GetAsset(item.AssetID, false);
156
157 if (rezAsset != null)
158 { 155 {
159 string script = Helpers.FieldToUTF8String(rezAsset.Data); 156 AssetBase rezAsset = m_parentGroup.Scene.AssetCache.GetAsset(item.AssetID, false);
160 m_parentGroup.Scene.EventManager.TriggerRezScript(LocalID, item.ItemID, script);
161 157
162 } 158 if (rezAsset != null)
163 else 159 {
164 { 160 string script = Helpers.FieldToUTF8String(rezAsset.Data);
165 m_log.Error(String.Format( 161 m_parentGroup.Scene.EventManager.TriggerRezScript(LocalID, item.ItemID, script);
166 "[PRIMINVENTORY]: " + 162
167 "Couldn't start script {0}, {1} since asset ID {2} could not be found", 163 }
168 item.Name, item.ItemID, item.AssetID)); 164 else
165 {
166 m_log.Error(String.Format(
167 "[PRIMINVENTORY]: " +
168 "Couldn't start script {0}, {1} since asset ID {2} could not be found",
169 item.Name, item.ItemID, item.AssetID));
170 }
169 } 171 }
170 } 172 }
171 173