Fix script "Running" behavior

Unchecking "Running" box in script editor now persists. This fixes http://opensimulator.org/mantis/view.php?id=6057
This commit is contained in:
BlueWall
2012-06-23 04:11:31 -04:00
parent 78143769bf
commit 6d3ee8bb39
6 changed files with 53 additions and 0 deletions

View File

@@ -120,6 +120,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
public bool Running { get; set; }
public bool Run { get; set; }
public bool Suspended
{
get { return m_Suspended; }
@@ -215,6 +217,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
m_postOnRez = postOnRez;
m_AttachedAvatar = part.ParentGroup.AttachedAvatar;
m_RegionID = part.ParentGroup.Scene.RegionInfo.RegionID;
Run = true;
if (part != null)
{
@@ -359,6 +362,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
if (m_startedFromSavedState)
{
if (!Run)
return;
Start();
if (m_postOnRez)
{
@@ -391,6 +397,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance
}
else
{
if (!Run)
return;
Start();
PostEvent(new EventParams("state_entry",
new Object[0], new DetectParams[0]));