aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs b/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs
index 5dfe58e..306090e 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs
@@ -120,6 +120,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
120 120
121 public bool Running { get; set; } 121 public bool Running { get; set; }
122 122
123 public bool Run { get; set; }
124
123 public bool Suspended 125 public bool Suspended
124 { 126 {
125 get { return m_Suspended; } 127 get { return m_Suspended; }
@@ -215,6 +217,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
215 m_postOnRez = postOnRez; 217 m_postOnRez = postOnRez;
216 m_AttachedAvatar = part.ParentGroup.AttachedAvatar; 218 m_AttachedAvatar = part.ParentGroup.AttachedAvatar;
217 m_RegionID = part.ParentGroup.Scene.RegionInfo.RegionID; 219 m_RegionID = part.ParentGroup.Scene.RegionInfo.RegionID;
220 Run = true;
218 221
219 if (part != null) 222 if (part != null)
220 { 223 {
@@ -359,6 +362,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
359 362
360 if (m_startedFromSavedState) 363 if (m_startedFromSavedState)
361 { 364 {
365 if (!Run)
366 return;
367
362 Start(); 368 Start();
363 if (m_postOnRez) 369 if (m_postOnRez)
364 { 370 {
@@ -391,6 +397,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
391 } 397 }
392 else 398 else
393 { 399 {
400 if (!Run)
401 return;
402
394 Start(); 403 Start();
395 PostEvent(new EventParams("state_entry", 404 PostEvent(new EventParams("state_entry",
396 new Object[0], new DetectParams[0])); 405 new Object[0], new DetectParams[0]));