aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ScriptEngine')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs20
-rw-r--r--OpenSim/Region/ScriptEngine/XEngine/XEngine.cs32
2 files changed, 38 insertions, 14 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 138bcc9..1d4c235 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -6134,6 +6134,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
6134 PSYS_PART_MAX_AGE = 7, 6134 PSYS_PART_MAX_AGE = 7,
6135 PSYS_SRC_ACCEL = 8, 6135 PSYS_SRC_ACCEL = 8,
6136 PSYS_SRC_PATTERN = 9, 6136 PSYS_SRC_PATTERN = 9,
6137 PSYS_SRC_INNERANGLE = 10,
6138 PSYS_SRC_OUTERANGLE = 11,
6137 PSYS_SRC_TEXTURE = 12, 6139 PSYS_SRC_TEXTURE = 12,
6138 PSYS_SRC_BURST_RATE = 13, 6140 PSYS_SRC_BURST_RATE = 13,
6139 PSYS_SRC_BURST_PART_COUNT = 15, 6141 PSYS_SRC_BURST_PART_COUNT = 15,
@@ -6266,6 +6268,22 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
6266 prules.Pattern = (Primitive.ParticleSystem.SourcePattern)tmpi; 6268 prules.Pattern = (Primitive.ParticleSystem.SourcePattern)tmpi;
6267 break; 6269 break;
6268 6270
6271 // PSYS_SRC_INNERANGLE and PSYS_SRC_ANGLE_BEGIN use the same variables. The
6272 // PSYS_SRC_OUTERANGLE and PSYS_SRC_ANGLE_END also use the same variable. The
6273 // client tells the difference between the two by looking at the 0x02 bit in
6274 // the PartFlags variable.
6275 case (int)ScriptBaseClass.PSYS_SRC_INNERANGLE:
6276 tempf = (float)rules.GetLSLFloatItem(i + 1);
6277 prules.InnerAngle = (float)tempf;
6278 prules.PartFlags &= 0xFFFFFFFD; // Make sure new angle format is off.
6279 break;
6280
6281 case (int)ScriptBaseClass.PSYS_SRC_OUTERANGLE:
6282 tempf = (float)rules.GetLSLFloatItem(i + 1);
6283 prules.OuterAngle = (float)tempf;
6284 prules.PartFlags &= 0xFFFFFFFD; // Make sure new angle format is off.
6285 break;
6286
6269 case (int)ScriptBaseClass.PSYS_SRC_TEXTURE: 6287 case (int)ScriptBaseClass.PSYS_SRC_TEXTURE:
6270 prules.Texture = KeyOrName(rules.GetLSLStringItem(i + 1)); 6288 prules.Texture = KeyOrName(rules.GetLSLStringItem(i + 1));
6271 break; 6289 break;
@@ -6322,11 +6340,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
6322 case (int)ScriptBaseClass.PSYS_SRC_ANGLE_BEGIN: 6340 case (int)ScriptBaseClass.PSYS_SRC_ANGLE_BEGIN:
6323 tempf = (float)rules.GetLSLFloatItem(i + 1); 6341 tempf = (float)rules.GetLSLFloatItem(i + 1);
6324 prules.InnerAngle = (float)tempf; 6342 prules.InnerAngle = (float)tempf;
6343 prules.PartFlags |= 0x02; // Set new angle format.
6325 break; 6344 break;
6326 6345
6327 case (int)ScriptBaseClass.PSYS_SRC_ANGLE_END: 6346 case (int)ScriptBaseClass.PSYS_SRC_ANGLE_END:
6328 tempf = (float)rules.GetLSLFloatItem(i + 1); 6347 tempf = (float)rules.GetLSLFloatItem(i + 1);
6329 prules.OuterAngle = (float)tempf; 6348 prules.OuterAngle = (float)tempf;
6349 prules.PartFlags |= 0x02; // Set new angle format.
6330 break; 6350 break;
6331 6351
6332 case (int)ScriptBaseClass.PSYS_SRC_INNERANGLE: 6352 case (int)ScriptBaseClass.PSYS_SRC_INNERANGLE:
diff --git a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs
index d4c1727..916e27f 100644
--- a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs
+++ b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs
@@ -769,8 +769,6 @@ namespace OpenSim.Region.ScriptEngine.XEngine
769 } 769 }
770 } 770 }
771 771
772
773
774 ScriptInstance instance = null; 772 ScriptInstance instance = null;
775 // Create the object record 773 // Create the object record
776 lockScriptsForRead(true); 774 lockScriptsForRead(true);
@@ -952,7 +950,6 @@ namespace OpenSim.Region.ScriptEngine.XEngine
952 950
953 CleanAssemblies(); 951 CleanAssemblies();
954 952
955
956 ScriptRemoved handlerScriptRemoved = OnScriptRemoved; 953 ScriptRemoved handlerScriptRemoved = OnScriptRemoved;
957 if (handlerScriptRemoved != null) 954 if (handlerScriptRemoved != null)
958 handlerScriptRemoved(itemID); 955 handlerScriptRemoved(itemID);
@@ -1086,26 +1083,33 @@ namespace OpenSim.Region.ScriptEngine.XEngine
1086 public bool PostObjectEvent(uint localID, EventParams p) 1083 public bool PostObjectEvent(uint localID, EventParams p)
1087 { 1084 {
1088 bool result = false; 1085 bool result = false;
1089 1086 List<UUID> uuids = null;
1087
1090 lock (m_PrimObjects) 1088 lock (m_PrimObjects)
1091 { 1089 {
1092 if (!m_PrimObjects.ContainsKey(localID)) 1090 if (!m_PrimObjects.ContainsKey(localID))
1093 return false; 1091 return false;
1094 1092
1095 1093 uuids = m_PrimObjects[localID];
1096 foreach (UUID itemID in m_PrimObjects[localID]) 1094 }
1095
1096 foreach (UUID itemID in uuids)
1097 {
1098 IScriptInstance instance = null;
1099 try
1097 { 1100 {
1098 if (m_Scripts.ContainsKey(itemID)) 1101 if (m_Scripts.ContainsKey(itemID))
1099 { 1102 instance = m_Scripts[itemID];
1100 IScriptInstance instance = m_Scripts[itemID]; 1103 }
1101 if (instance != null) 1104 catch { /* ignore race conditions */ }
1102 { 1105
1103 instance.PostEvent(p); 1106 if (instance != null)
1104 result = true; 1107 {
1105 } 1108 instance.PostEvent(p);
1106 } 1109 result = true;
1107 } 1110 }
1108 } 1111 }
1112
1109 return result; 1113 return result;
1110 } 1114 }
1111 1115