diff options
author | onefang | 2019-05-19 22:54:18 +1000 |
---|---|---|
committer | onefang | 2019-05-19 22:54:18 +1000 |
commit | c568d4c16b75615dd10b253cad5cd2fd710e2fb9 (patch) | |
tree | d9573f9ff43d02d9fbb8f4e7dbd373d79affbc6c /OpenSim | |
parent | More script speed ups. (diff) | |
download | opensim-SC-c568d4c16b75615dd10b253cad5cd2fd710e2fb9.zip opensim-SC-c568d4c16b75615dd10b253cad5cd2fd710e2fb9.tar.gz opensim-SC-c568d4c16b75615dd10b253cad5cd2fd710e2fb9.tar.bz2 opensim-SC-c568d4c16b75615dd10b253cad5cd2fd710e2fb9.tar.xz |
One last big source of script slowness removed.
No need to artificially slow stuff down. lol
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 158 | ||||
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | 37 |
2 files changed, 14 insertions, 181 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 3a3703c..ecaa672 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -109,7 +109,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
109 | 109 | ||
110 | protected bool throwErrorOnNotImplemented = false; | 110 | protected bool throwErrorOnNotImplemented = false; |
111 | protected AsyncCommandManager AsyncCommands = null; | 111 | protected AsyncCommandManager AsyncCommands = null; |
112 | protected float m_ScriptDelayFactor = 1.0f; | ||
113 | protected float m_ScriptDistanceFactor = 1.0f; | 112 | protected float m_ScriptDistanceFactor = 1.0f; |
114 | protected float m_MinTimerInterval = 0.5f; | 113 | protected float m_MinTimerInterval = 0.5f; |
115 | protected float m_recoilScaleFactor = 0.0f; | 114 | protected float m_recoilScaleFactor = 0.0f; |
@@ -126,64 +125,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
126 | 125 | ||
127 | protected Dictionary<UUID, UserInfoCacheEntry> m_userInfoCache = new Dictionary<UUID, UserInfoCacheEntry>(); | 126 | protected Dictionary<UUID, UserInfoCacheEntry> m_userInfoCache = new Dictionary<UUID, UserInfoCacheEntry>(); |
128 | protected int EMAIL_PAUSE_TIME = 20; // documented delay value for smtp. | 127 | protected int EMAIL_PAUSE_TIME = 20; // documented delay value for smtp. |
129 | protected int m_sleepMsOnSetTexture = 200; | ||
130 | protected int m_sleepMsOnSetLinkTexture = 200; | ||
131 | protected int m_sleepMsOnScaleTexture = 200; | ||
132 | protected int m_sleepMsOnOffsetTexture = 200; | ||
133 | protected int m_sleepMsOnRotateTexture = 200; | ||
134 | protected int m_sleepMsOnSetPos = 200; | ||
135 | protected int m_sleepMsOnSetRot = 200; | ||
136 | protected int m_sleepMsOnSetLocalRot = 200; | ||
137 | protected int m_sleepMsOnPreloadSound = 1000; | ||
138 | protected int m_sleepMsOnMakeExplosion = 100; | ||
139 | protected int m_sleepMsOnMakeFountain = 100; | ||
140 | protected int m_sleepMsOnMakeSmoke = 100; | ||
141 | protected int m_sleepMsOnMakeFire = 100; | ||
142 | protected int m_sleepMsOnRezAtRoot = 100; | ||
143 | protected int m_sleepMsOnInstantMessage = 2000; | ||
144 | protected int m_sleepMsOnEmail = 20000; | ||
145 | protected int m_sleepMsOnCreateLink = 1000; | ||
146 | protected int m_sleepMsOnGiveInventory = 3000; | ||
147 | protected int m_sleepMsOnRequestAgentData = 100; | ||
148 | protected int m_sleepMsOnRequestInventoryData = 1000; | ||
149 | protected int m_sleepMsOnSetDamage = 5000; | ||
150 | protected int m_sleepMsOnTextBox = 1000; | ||
151 | protected int m_sleepMsOnAdjustSoundVolume = 100; | ||
152 | protected int m_sleepMsOnEjectFromLand = 5000; | ||
153 | protected int m_sleepMsOnAddToLandPassList = 100; | ||
154 | protected int m_sleepMsOnDialog = 1000; | ||
155 | protected int m_sleepMsOnRemoteLoadScript = 3000; | ||
156 | protected int m_sleepMsOnRemoteLoadScriptPin = 3000; | ||
157 | protected int m_sleepMsOnOpenRemoteDataChannel = 1000; | ||
158 | protected int m_sleepMsOnSendRemoteData = 3000; | ||
159 | protected int m_sleepMsOnRemoteDataReply = 3000; | ||
160 | protected int m_sleepMsOnCloseRemoteDataChannel = 1000; | ||
161 | protected int m_sleepMsOnSetPrimitiveParams = 200; | ||
162 | protected int m_sleepMsOnSetLinkPrimitiveParams = 200; | ||
163 | protected int m_sleepMsOnXorBase64Strings = 300; | ||
164 | protected int m_sleepMsOnSetParcelMusicURL = 2000; | ||
165 | protected int m_sleepMsOnGetPrimMediaParams = 1000; | ||
166 | protected int m_sleepMsOnGetLinkMedia = 1000; | ||
167 | protected int m_sleepMsOnSetPrimMediaParams = 1000; | ||
168 | protected int m_sleepMsOnSetLinkMedia = 1000; | ||
169 | protected int m_sleepMsOnClearPrimMedia = 1000; | ||
170 | protected int m_sleepMsOnClearLinkMedia = 1000; | ||
171 | protected int m_sleepMsOnRequestSimulatorData = 1000; | ||
172 | protected int m_sleepMsOnLoadURL = 10000; | ||
173 | protected int m_sleepMsOnParcelMediaCommandList = 2000; | ||
174 | protected int m_sleepMsOnParcelMediaQuery = 2000; | ||
175 | protected int m_sleepMsOnModPow = 1000; | ||
176 | protected int m_sleepMsOnSetPrimURL = 2000; | ||
177 | protected int m_sleepMsOnRefreshPrimURL = 20000; | ||
178 | protected int m_sleepMsOnMapDestination = 1000; | ||
179 | protected int m_sleepMsOnAddToLandBanList = 100; | ||
180 | protected int m_sleepMsOnRemoveFromLandPassList = 100; | ||
181 | protected int m_sleepMsOnRemoveFromLandBanList = 100; | ||
182 | protected int m_sleepMsOnResetLandBanList = 100; | ||
183 | protected int m_sleepMsOnResetLandPassList = 100; | ||
184 | protected int m_sleepMsOnGetParcelPrimOwners = 2000; | ||
185 | protected int m_sleepMsOnGetNumberOfNotecardLines = 100; | ||
186 | protected int m_sleepMsOnGetNotecardLine = 100; | ||
187 | protected string m_internalObjectHost = "lsl.opensim.local"; | 128 | protected string m_internalObjectHost = "lsl.opensim.local"; |
188 | protected bool m_restrictEmail = false; | 129 | protected bool m_restrictEmail = false; |
189 | protected ISoundModule m_SoundModule = null; | 130 | protected ISoundModule m_SoundModule = null; |
@@ -321,10 +262,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
321 | 262 | ||
322 | if (seConfig != null) | 263 | if (seConfig != null) |
323 | { | 264 | { |
324 | m_ScriptDelayFactor = | ||
325 | seConfig.GetFloat("ScriptDelayFactor", m_ScriptDelayFactor); | ||
326 | m_ScriptDistanceFactor = | ||
327 | seConfig.GetFloat("ScriptDistanceLimitFactor", m_ScriptDistanceFactor); | ||
328 | m_MinTimerInterval = | 265 | m_MinTimerInterval = |
329 | seConfig.GetFloat("MinTimerInterval", m_MinTimerInterval); | 266 | seConfig.GetFloat("MinTimerInterval", m_MinTimerInterval); |
330 | m_automaticLinkPermission = | 267 | m_automaticLinkPermission = |
@@ -409,7 +346,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
409 | m_internalObjectHost = smtpConfig.GetString("internal_object_host", m_internalObjectHost); | 346 | m_internalObjectHost = smtpConfig.GetString("internal_object_host", m_internalObjectHost); |
410 | } | 347 | } |
411 | } | 348 | } |
412 | m_sleepMsOnEmail = EMAIL_PAUSE_TIME * 1000; | 349 | //// m_sleepMsOnEmail = EMAIL_PAUSE_TIME * 1000; |
413 | } | 350 | } |
414 | 351 | ||
415 | public override Object InitializeLifetimeService() | 352 | public override Object InitializeLifetimeService() |
@@ -438,14 +375,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
438 | return p; | 375 | return p; |
439 | } | 376 | } |
440 | 377 | ||
441 | protected virtual void ScriptSleep(int delay) | ||
442 | { | ||
443 | delay = (int)((float)delay * m_ScriptDelayFactor); | ||
444 | if (delay == 0) | ||
445 | return; | ||
446 | |||
447 | Sleep(delay); | ||
448 | } | ||
449 | protected virtual void Sleep(int delay) | 378 | protected virtual void Sleep(int delay) |
450 | { | 379 | { |
451 | if (m_item == null) // Some unit tests don't set this | 380 | if (m_item == null) // Some unit tests don't set this |
@@ -1183,8 +1112,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
1183 | // m_SayShoutCount++; | 1112 | // m_SayShoutCount++; |
1184 | CheckSayShoutTime(); | 1113 | CheckSayShoutTime(); |
1185 | 1114 | ||
1186 | if (m_SayShoutCount >= 11) | 1115 | //// if (m_SayShoutCount >= 11) |
1187 | ScriptSleep(2000); | 1116 | //// ScriptSleep(2000); |
1188 | 1117 | ||
1189 | if (m_scriptConsoleChannelEnabled && (channelID == m_scriptConsoleChannel)) | 1118 | if (m_scriptConsoleChannelEnabled && (channelID == m_scriptConsoleChannel)) |
1190 | { | 1119 | { |
@@ -1210,8 +1139,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
1210 | // m_SayShoutCount++; | 1139 | // m_SayShoutCount++; |
1211 | CheckSayShoutTime(); | 1140 | CheckSayShoutTime(); |
1212 | 1141 | ||
1213 | if (m_SayShoutCount >= 11) | 1142 | //// if (m_SayShoutCount >= 11) |
1214 | ScriptSleep(2000); | 1143 | //// ScriptSleep(2000); |
1215 | 1144 | ||
1216 | if (text.Length > 1023) | 1145 | if (text.Length > 1023) |
1217 | text = text.Substring(0, 1023); | 1146 | text = text.Substring(0, 1023); |
@@ -2334,7 +2263,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
2334 | public void llSetTexture(string texture, int face) | 2263 | public void llSetTexture(string texture, int face) |
2335 | { | 2264 | { |
2336 | SetTexture(m_host, texture, face); | 2265 | SetTexture(m_host, texture, face); |
2337 | ScriptSleep(m_sleepMsOnSetTexture); | ||
2338 | } | 2266 | } |
2339 | 2267 | ||
2340 | public void llSetLinkTexture(int linknumber, string texture, int face) | 2268 | public void llSetLinkTexture(int linknumber, string texture, int face) |
@@ -2349,7 +2277,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
2349 | } | 2277 | } |
2350 | finally { } | 2278 | finally { } |
2351 | } | 2279 | } |
2352 | ScriptSleep(m_sleepMsOnSetLinkTexture); | ||
2353 | } | 2280 | } |
2354 | 2281 | ||
2355 | protected void SetTexture(SceneObjectPart part, string texture, int face) | 2282 | protected void SetTexture(SceneObjectPart part, string texture, int face) |
@@ -2396,7 +2323,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
2396 | public void llScaleTexture(double u, double v, int face) | 2323 | public void llScaleTexture(double u, double v, int face) |
2397 | { | 2324 | { |
2398 | ScaleTexture(m_host, u, v, face); | 2325 | ScaleTexture(m_host, u, v, face); |
2399 | ScriptSleep(m_sleepMsOnScaleTexture); | ||
2400 | } | 2326 | } |
2401 | 2327 | ||
2402 | protected void ScaleTexture(SceneObjectPart part, double u, double v, int face) | 2328 | protected void ScaleTexture(SceneObjectPart part, double u, double v, int face) |
@@ -2436,7 +2362,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
2436 | public void llOffsetTexture(double u, double v, int face) | 2362 | public void llOffsetTexture(double u, double v, int face) |
2437 | { | 2363 | { |
2438 | OffsetTexture(m_host, u, v, face); | 2364 | OffsetTexture(m_host, u, v, face); |
2439 | ScriptSleep(m_sleepMsOnOffsetTexture); | ||
2440 | } | 2365 | } |
2441 | 2366 | ||
2442 | protected void OffsetTexture(SceneObjectPart part, double u, double v, int face) | 2367 | protected void OffsetTexture(SceneObjectPart part, double u, double v, int face) |
@@ -2476,7 +2401,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
2476 | public void llRotateTexture(double rotation, int face) | 2401 | public void llRotateTexture(double rotation, int face) |
2477 | { | 2402 | { |
2478 | RotateTexture(m_host, rotation, face); | 2403 | RotateTexture(m_host, rotation, face); |
2479 | ScriptSleep(m_sleepMsOnRotateTexture); | ||
2480 | } | 2404 | } |
2481 | 2405 | ||
2482 | protected void RotateTexture(SceneObjectPart part, double rotation, int face) | 2406 | protected void RotateTexture(SceneObjectPart part, double rotation, int face) |
@@ -2554,8 +2478,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
2554 | public void llSetPos(LSL_Vector pos) | 2478 | public void llSetPos(LSL_Vector pos) |
2555 | { | 2479 | { |
2556 | SetPos(m_host, pos, true); | 2480 | SetPos(m_host, pos, true); |
2557 | |||
2558 | ScriptSleep(m_sleepMsOnSetPos); | ||
2559 | } | 2481 | } |
2560 | 2482 | ||
2561 | /// <summary> | 2483 | /// <summary> |
@@ -2727,14 +2649,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
2727 | SetRot(m_host, rootPart.RotationOffset * (Quaternion)rot); | 2649 | SetRot(m_host, rootPart.RotationOffset * (Quaternion)rot); |
2728 | } | 2650 | } |
2729 | } | 2651 | } |
2730 | |||
2731 | ScriptSleep(m_sleepMsOnSetRot); | ||
2732 | } | 2652 | } |
2733 | 2653 | ||
2734 | public void llSetLocalRot(LSL_Rotation rot) | 2654 | public void llSetLocalRot(LSL_Rotation rot) |
2735 | { | 2655 | { |
2736 | SetRot(m_host, rot); | 2656 | SetRot(m_host, rot); |
2737 | ScriptSleep(m_sleepMsOnSetLocalRot); | ||
2738 | } | 2657 | } |
2739 | 2658 | ||
2740 | protected void SetRot(SceneObjectPart part, Quaternion rot) | 2659 | protected void SetRot(SceneObjectPart part, Quaternion rot) |
@@ -3097,7 +3016,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3097 | { | 3016 | { |
3098 | if (m_SoundModule != null) | 3017 | if (m_SoundModule != null) |
3099 | m_SoundModule.PreloadSound(m_host.UUID, ScriptUtils.GetAssetIdFromKeyOrItemName(m_host, sound), 0); | 3018 | m_SoundModule.PreloadSound(m_host.UUID, ScriptUtils.GetAssetIdFromKeyOrItemName(m_host, sound), 0); |
3100 | ScriptSleep(m_sleepMsOnPreloadSound); | ||
3101 | } | 3019 | } |
3102 | 3020 | ||
3103 | /// <summary> | 3021 | /// <summary> |
@@ -3363,25 +3281,21 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3363 | public void llMakeExplosion(int particles, double scale, double vel, double lifetime, double arc, string texture, LSL_Vector offset) | 3281 | public void llMakeExplosion(int particles, double scale, double vel, double lifetime, double arc, string texture, LSL_Vector offset) |
3364 | { | 3282 | { |
3365 | Deprecated("llMakeExplosion", "Use llParticleSystem instead"); | 3283 | Deprecated("llMakeExplosion", "Use llParticleSystem instead"); |
3366 | ScriptSleep(m_sleepMsOnMakeExplosion); | ||
3367 | } | 3284 | } |
3368 | 3285 | ||
3369 | public void llMakeFountain(int particles, double scale, double vel, double lifetime, double arc, int bounce, string texture, LSL_Vector offset, double bounce_offset) | 3286 | public void llMakeFountain(int particles, double scale, double vel, double lifetime, double arc, int bounce, string texture, LSL_Vector offset, double bounce_offset) |
3370 | { | 3287 | { |
3371 | Deprecated("llMakeFountain", "Use llParticleSystem instead"); | 3288 | Deprecated("llMakeFountain", "Use llParticleSystem instead"); |
3372 | ScriptSleep(m_sleepMsOnMakeFountain); | ||
3373 | } | 3289 | } |
3374 | 3290 | ||
3375 | public void llMakeSmoke(int particles, double scale, double vel, double lifetime, double arc, string texture, LSL_Vector offset) | 3291 | public void llMakeSmoke(int particles, double scale, double vel, double lifetime, double arc, string texture, LSL_Vector offset) |
3376 | { | 3292 | { |
3377 | Deprecated("llMakeSmoke", "Use llParticleSystem instead"); | 3293 | Deprecated("llMakeSmoke", "Use llParticleSystem instead"); |
3378 | ScriptSleep(m_sleepMsOnMakeSmoke); | ||
3379 | } | 3294 | } |
3380 | 3295 | ||
3381 | public void llMakeFire(int particles, double scale, double vel, double lifetime, double arc, string texture, LSL_Vector offset) | 3296 | public void llMakeFire(int particles, double scale, double vel, double lifetime, double arc, string texture, LSL_Vector offset) |
3382 | { | 3297 | { |
3383 | Deprecated("llMakeFire", "Use llParticleSystem instead"); | 3298 | Deprecated("llMakeFire", "Use llParticleSystem instead"); |
3384 | ScriptSleep(m_sleepMsOnMakeFire); | ||
3385 | } | 3299 | } |
3386 | 3300 | ||
3387 | public void llRezAtRoot(string inventory, LSL_Vector pos, LSL_Vector vel, LSL_Rotation rot, int param) | 3301 | public void llRezAtRoot(string inventory, LSL_Vector pos, LSL_Vector vel, LSL_Rotation rot, int param) |
@@ -3458,8 +3372,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3458 | } | 3372 | } |
3459 | }, null, "LSL_Api.doObjectRez"); | 3373 | }, null, "LSL_Api.doObjectRez"); |
3460 | 3374 | ||
3461 | //ScriptSleep((int)((groupmass * velmag) / 10)); | ||
3462 | ScriptSleep(m_sleepMsOnRezAtRoot); | ||
3463 | } | 3375 | } |
3464 | 3376 | ||
3465 | public void llRezObject(string inventory, LSL_Vector pos, LSL_Vector vel, LSL_Rotation rot, int param) | 3377 | public void llRezObject(string inventory, LSL_Vector pos, LSL_Vector vel, LSL_Rotation rot, int param) |
@@ -3704,7 +3616,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3704 | if (!UUID.TryParse(user, out result) || result == UUID.Zero) | 3616 | if (!UUID.TryParse(user, out result) || result == UUID.Zero) |
3705 | { | 3617 | { |
3706 | Error("llInstantMessage","An invalid key was passed to llInstantMessage"); | 3618 | Error("llInstantMessage","An invalid key was passed to llInstantMessage"); |
3707 | ScriptSleep(2000); | 3619 | //// ScriptSleep(2000); |
3708 | return; | 3620 | return; |
3709 | } | 3621 | } |
3710 | 3622 | ||
@@ -3752,8 +3664,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3752 | { | 3664 | { |
3753 | m_TransferModule.SendInstantMessage(msg, delegate(bool success) {}); | 3665 | m_TransferModule.SendInstantMessage(msg, delegate(bool success) {}); |
3754 | } | 3666 | } |
3755 | |||
3756 | ScriptSleep(m_sleepMsOnInstantMessage); | ||
3757 | } | 3667 | } |
3758 | 3668 | ||
3759 | public void llEmail(string address, string subject, string message) | 3669 | public void llEmail(string address, string subject, string message) |
@@ -3790,7 +3700,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3790 | } | 3700 | } |
3791 | 3701 | ||
3792 | emailModule.SendEmail(m_host.UUID, address, subject, message); | 3702 | emailModule.SendEmail(m_host.UUID, address, subject, message); |
3793 | ScriptSleep(m_sleepMsOnEmail); | 3703 | //// ScriptSleep(m_sleepMsOnEmail); |
3794 | } | 3704 | } |
3795 | 3705 | ||
3796 | public void llGetNextEmail(string address, string subject) | 3706 | public void llGetNextEmail(string address, string subject) |
@@ -4568,9 +4478,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
4568 | if (m_TransferModule != null) | 4478 | if (m_TransferModule != null) |
4569 | m_TransferModule.SendInstantMessage(msg, delegate(bool success) {}); | 4479 | m_TransferModule.SendInstantMessage(msg, delegate(bool success) {}); |
4570 | } | 4480 | } |
4571 | |||
4572 | //This delay should only occur when giving inventory to avatars. | ||
4573 | ScriptSleep(m_sleepMsOnGiveInventory); | ||
4574 | } | 4481 | } |
4575 | } | 4482 | } |
4576 | 4483 | ||
@@ -4752,12 +4659,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
4752 | reply); | 4659 | reply); |
4753 | }); | 4660 | }); |
4754 | 4661 | ||
4755 | ScriptSleep(m_sleepMsOnRequestInventoryData); | ||
4756 | return tid.ToString(); | 4662 | return tid.ToString(); |
4757 | } | 4663 | } |
4758 | } | 4664 | } |
4759 | 4665 | ||
4760 | ScriptSleep(m_sleepMsOnRequestInventoryData); | ||
4761 | return String.Empty; | 4666 | return String.Empty; |
4762 | } | 4667 | } |
4763 | 4668 | ||
@@ -4794,8 +4699,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
4794 | } | 4699 | } |
4795 | } | 4700 | } |
4796 | } | 4701 | } |
4797 | |||
4798 | ScriptSleep(m_sleepMsOnSetDamage); | ||
4799 | } | 4702 | } |
4800 | 4703 | ||
4801 | public void llTeleportAgent(string agent, string destination, LSL_Vector targetPos, LSL_Vector targetLookAt) | 4704 | public void llTeleportAgent(string agent, string destination, LSL_Vector targetPos, LSL_Vector targetLookAt) |
@@ -4924,7 +4827,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
4924 | else | 4827 | else |
4925 | { | 4828 | { |
4926 | dm.SendTextBoxToUser(av, message, chatChannel, m_host.Name, m_host.UUID, m_host.OwnerID); | 4829 | dm.SendTextBoxToUser(av, message, chatChannel, m_host.Name, m_host.UUID, m_host.OwnerID); |
4927 | ScriptSleep(m_sleepMsOnTextBox); | ||
4928 | } | 4830 | } |
4929 | } | 4831 | } |
4930 | 4832 | ||
@@ -6417,7 +6319,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
6417 | public void llAdjustSoundVolume(double volume) | 6319 | public void llAdjustSoundVolume(double volume) |
6418 | { | 6320 | { |
6419 | m_host.AdjustSoundGain(volume); | 6321 | m_host.AdjustSoundGain(volume); |
6420 | ScriptSleep(m_sleepMsOnAdjustSoundVolume); | ||
6421 | } | 6322 | } |
6422 | 6323 | ||
6423 | public void llSetSoundRadius(double radius) | 6324 | public void llSetSoundRadius(double radius) |
@@ -6523,7 +6424,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
6523 | } | 6424 | } |
6524 | } | 6425 | } |
6525 | } | 6426 | } |
6526 | ScriptSleep(m_sleepMsOnEjectFromLand); | ||
6527 | } | 6427 | } |
6528 | 6428 | ||
6529 | public LSL_List llParseString2List(string str, LSL_List separators, LSL_List in_spacers) | 6429 | public LSL_List llParseString2List(string str, LSL_List separators, LSL_List in_spacers) |
@@ -7669,8 +7569,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7669 | dm.SendDialogToUser( | 7569 | dm.SendDialogToUser( |
7670 | av, m_host.Name, m_host.UUID, m_host.OwnerID, | 7570 | av, m_host.Name, m_host.UUID, m_host.OwnerID, |
7671 | message, new UUID("00000000-0000-2222-3333-100000001000"), chat_channel, buts); | 7571 | message, new UUID("00000000-0000-2222-3333-100000001000"), chat_channel, buts); |
7672 | |||
7673 | ScriptSleep(m_sleepMsOnDialog); | ||
7674 | } | 7572 | } |
7675 | 7573 | ||
7676 | public void llVolumeDetect(int detect) | 7574 | public void llVolumeDetect(int detect) |
@@ -7682,7 +7580,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7682 | public void llRemoteLoadScript(string target, string name, int running, int start_param) | 7580 | public void llRemoteLoadScript(string target, string name, int running, int start_param) |
7683 | { | 7581 | { |
7684 | Deprecated("llRemoteLoadScript", "Use llRemoteLoadScriptPin instead"); | 7582 | Deprecated("llRemoteLoadScript", "Use llRemoteLoadScriptPin instead"); |
7685 | ScriptSleep(m_sleepMsOnRemoteLoadScript); | ||
7686 | } | 7583 | } |
7687 | 7584 | ||
7688 | public void llSetRemoteScriptAccessPin(int pin) | 7585 | public void llSetRemoteScriptAccessPin(int pin) |
@@ -7728,8 +7625,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7728 | m_host.Inventory.RemoveInventoryItem(item.ItemID); | 7625 | m_host.Inventory.RemoveInventoryItem(item.ItemID); |
7729 | } | 7626 | } |
7730 | } | 7627 | } |
7731 | // this will cause the delay even if the script pin or permissions were wrong - seems ok | ||
7732 | ScriptSleep(m_sleepMsOnRemoteLoadScriptPin); | ||
7733 | } | 7628 | } |
7734 | 7629 | ||
7735 | public void llOpenRemoteDataChannel() | 7630 | public void llOpenRemoteDataChannel() |
@@ -7759,13 +7654,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7759 | m_ScriptEngine.PostScriptEvent(m_item.ItemID, new EventParams("remote_data", resobj, | 7654 | m_ScriptEngine.PostScriptEvent(m_item.ItemID, new EventParams("remote_data", resobj, |
7760 | new DetectParams[0])); | 7655 | new DetectParams[0])); |
7761 | } | 7656 | } |
7762 | ScriptSleep(m_sleepMsOnOpenRemoteDataChannel); | ||
7763 | } | 7657 | } |
7764 | 7658 | ||
7765 | public LSL_String llSendRemoteData(string channel, string dest, int idata, string sdata) | 7659 | public LSL_String llSendRemoteData(string channel, string dest, int idata, string sdata) |
7766 | { | 7660 | { |
7767 | IXMLRPC xmlrpcMod = m_ScriptEngine.World.RequestModuleInterface<IXMLRPC>(); | 7661 | IXMLRPC xmlrpcMod = m_ScriptEngine.World.RequestModuleInterface<IXMLRPC>(); |
7768 | ScriptSleep(m_sleepMsOnSendRemoteData); | ||
7769 | if (xmlrpcMod == null) | 7662 | if (xmlrpcMod == null) |
7770 | return ""; | 7663 | return ""; |
7771 | return (xmlrpcMod.SendRemoteData(m_host.LocalId, m_item.ItemID, channel, dest, idata, sdata)).ToString(); | 7664 | return (xmlrpcMod.SendRemoteData(m_host.LocalId, m_item.ItemID, channel, dest, idata, sdata)).ToString(); |
@@ -7776,7 +7669,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7776 | IXMLRPC xmlrpcMod = m_ScriptEngine.World.RequestModuleInterface<IXMLRPC>(); | 7669 | IXMLRPC xmlrpcMod = m_ScriptEngine.World.RequestModuleInterface<IXMLRPC>(); |
7777 | if (xmlrpcMod != null) | 7670 | if (xmlrpcMod != null) |
7778 | xmlrpcMod.RemoteDataReply(channel, message_id, sdata, idata); | 7671 | xmlrpcMod.RemoteDataReply(channel, message_id, sdata, idata); |
7779 | ScriptSleep(m_sleepMsOnRemoteDataReply); | ||
7780 | } | 7672 | } |
7781 | 7673 | ||
7782 | public void llCloseRemoteDataChannel(string channel) | 7674 | public void llCloseRemoteDataChannel(string channel) |
@@ -7790,7 +7682,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7790 | IXMLRPC xmlrpcMod = m_ScriptEngine.World.RequestModuleInterface<IXMLRPC>(); | 7682 | IXMLRPC xmlrpcMod = m_ScriptEngine.World.RequestModuleInterface<IXMLRPC>(); |
7791 | if (xmlrpcMod != null) | 7683 | if (xmlrpcMod != null) |
7792 | xmlrpcMod.CloseXMLRPCChannel((UUID)channel); | 7684 | xmlrpcMod.CloseXMLRPCChannel((UUID)channel); |
7793 | ScriptSleep(m_sleepMsOnCloseRemoteDataChannel); | ||
7794 | } | 7685 | } |
7795 | 7686 | ||
7796 | public LSL_String llMD5String(string src, int nonce) | 7687 | public LSL_String llMD5String(string src, int nonce) |
@@ -8192,15 +8083,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
8192 | public void llSetPrimitiveParams(LSL_List rules) | 8083 | public void llSetPrimitiveParams(LSL_List rules) |
8193 | { | 8084 | { |
8194 | SetLinkPrimParams(ScriptBaseClass.LINK_THIS, rules, "llSetPrimitiveParams"); | 8085 | SetLinkPrimParams(ScriptBaseClass.LINK_THIS, rules, "llSetPrimitiveParams"); |
8195 | |||
8196 | ScriptSleep(m_sleepMsOnSetPrimitiveParams); | ||
8197 | } | 8086 | } |
8198 | 8087 | ||
8199 | public void llSetLinkPrimitiveParams(int linknumber, LSL_List rules) | 8088 | public void llSetLinkPrimitiveParams(int linknumber, LSL_List rules) |
8200 | { | 8089 | { |
8201 | SetLinkPrimParams(linknumber, rules, "llSetLinkPrimitiveParams"); | 8090 | SetLinkPrimParams(linknumber, rules, "llSetLinkPrimitiveParams"); |
8202 | |||
8203 | ScriptSleep(m_sleepMsOnSetLinkPrimitiveParams); | ||
8204 | } | 8091 | } |
8205 | 8092 | ||
8206 | public void llSetLinkPrimitiveParamsFast(int linknumber, LSL_List rules) | 8093 | public void llSetLinkPrimitiveParamsFast(int linknumber, LSL_List rules) |
@@ -9990,7 +9877,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
9990 | 9877 | ||
9991 | string b64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; | 9878 | string b64 = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; |
9992 | 9879 | ||
9993 | ScriptSleep(300); | ||
9994 | if (str1 == String.Empty) | 9880 | if (str1 == String.Empty) |
9995 | return String.Empty; | 9881 | return String.Empty; |
9996 | if (str2 == String.Empty) | 9882 | if (str2 == String.Empty) |
@@ -10120,8 +10006,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
10120 | return; | 10006 | return; |
10121 | 10007 | ||
10122 | land.SetMusicUrl(url); | 10008 | land.SetMusicUrl(url); |
10123 | |||
10124 | ScriptSleep(m_sleepMsOnSetParcelMusicURL); | ||
10125 | } | 10009 | } |
10126 | 10010 | ||
10127 | public LSL_String llGetParcelMusicURL() | 10011 | public LSL_String llGetParcelMusicURL() |
@@ -11039,13 +10923,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
11039 | 10923 | ||
11040 | public LSL_List llGetPrimMediaParams(int face, LSL_List rules) | 10924 | public LSL_List llGetPrimMediaParams(int face, LSL_List rules) |
11041 | { | 10925 | { |
11042 | ScriptSleep(m_sleepMsOnGetPrimMediaParams); | ||
11043 | return GetPrimMediaParams(m_host, face, rules); | 10926 | return GetPrimMediaParams(m_host, face, rules); |
11044 | } | 10927 | } |
11045 | 10928 | ||
11046 | public LSL_List llGetLinkMedia(LSL_Integer link, LSL_Integer face, LSL_List rules) | 10929 | public LSL_List llGetLinkMedia(LSL_Integer link, LSL_Integer face, LSL_List rules) |
11047 | { | 10930 | { |
11048 | ScriptSleep(m_sleepMsOnGetLinkMedia); | ||
11049 | if (link == ScriptBaseClass.LINK_ROOT) | 10931 | if (link == ScriptBaseClass.LINK_ROOT) |
11050 | return GetPrimMediaParams(m_host.ParentGroup.RootPart, face, rules); | 10932 | return GetPrimMediaParams(m_host.ParentGroup.RootPart, face, rules); |
11051 | else if (link == ScriptBaseClass.LINK_THIS) | 10933 | else if (link == ScriptBaseClass.LINK_THIS) |
@@ -11164,13 +11046,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
11164 | 11046 | ||
11165 | public LSL_Integer llSetPrimMediaParams(LSL_Integer face, LSL_List rules) | 11047 | public LSL_Integer llSetPrimMediaParams(LSL_Integer face, LSL_List rules) |
11166 | { | 11048 | { |
11167 | ScriptSleep(m_sleepMsOnSetPrimMediaParams); | ||
11168 | return SetPrimMediaParams(m_host, face, rules); | 11049 | return SetPrimMediaParams(m_host, face, rules); |
11169 | } | 11050 | } |
11170 | 11051 | ||
11171 | public LSL_Integer llSetLinkMedia(LSL_Integer link, LSL_Integer face, LSL_List rules) | 11052 | public LSL_Integer llSetLinkMedia(LSL_Integer link, LSL_Integer face, LSL_List rules) |
11172 | { | 11053 | { |
11173 | ScriptSleep(m_sleepMsOnSetLinkMedia); | ||
11174 | if (link == ScriptBaseClass.LINK_ROOT) | 11054 | if (link == ScriptBaseClass.LINK_ROOT) |
11175 | return SetPrimMediaParams(m_host.ParentGroup.RootPart, face, rules); | 11055 | return SetPrimMediaParams(m_host.ParentGroup.RootPart, face, rules); |
11176 | else if (link == ScriptBaseClass.LINK_THIS) | 11056 | else if (link == ScriptBaseClass.LINK_THIS) |
@@ -11288,13 +11168,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
11288 | 11168 | ||
11289 | public LSL_Integer llClearPrimMedia(LSL_Integer face) | 11169 | public LSL_Integer llClearPrimMedia(LSL_Integer face) |
11290 | { | 11170 | { |
11291 | ScriptSleep(m_sleepMsOnClearPrimMedia); | ||
11292 | return ClearPrimMedia(m_host, face); | 11171 | return ClearPrimMedia(m_host, face); |
11293 | } | 11172 | } |
11294 | 11173 | ||
11295 | public LSL_Integer llClearLinkMedia(LSL_Integer link, LSL_Integer face) | 11174 | public LSL_Integer llClearLinkMedia(LSL_Integer link, LSL_Integer face) |
11296 | { | 11175 | { |
11297 | ScriptSleep(m_sleepMsOnClearLinkMedia); | ||
11298 | if (link == ScriptBaseClass.LINK_ROOT) | 11176 | if (link == ScriptBaseClass.LINK_ROOT) |
11299 | return ClearPrimMedia(m_host.ParentGroup.RootPart, face); | 11177 | return ClearPrimMedia(m_host.ParentGroup.RootPart, face); |
11300 | else if (link == ScriptBaseClass.LINK_THIS) | 11178 | else if (link == ScriptBaseClass.LINK_THIS) |
@@ -11925,7 +11803,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
11925 | case ScriptBaseClass.DATA_SIM_POS: | 11803 | case ScriptBaseClass.DATA_SIM_POS: |
11926 | if (info == null) | 11804 | if (info == null) |
11927 | { | 11805 | { |
11928 | ScriptSleep(m_sleepMsOnRequestSimulatorData); | ||
11929 | return UUID.Zero.ToString(); | 11806 | return UUID.Zero.ToString(); |
11930 | } | 11807 | } |
11931 | 11808 | ||
@@ -11972,7 +11849,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
11972 | case ScriptBaseClass.DATA_SIM_RATING: | 11849 | case ScriptBaseClass.DATA_SIM_RATING: |
11973 | if (info == null) | 11850 | if (info == null) |
11974 | { | 11851 | { |
11975 | ScriptSleep(m_sleepMsOnRequestSimulatorData); | ||
11976 | return UUID.Zero.ToString(); | 11852 | return UUID.Zero.ToString(); |
11977 | } | 11853 | } |
11978 | int access = info.Maturity; | 11854 | int access = info.Maturity; |
@@ -11991,7 +11867,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
11991 | reply = "OpenSim"; | 11867 | reply = "OpenSim"; |
11992 | break; | 11868 | break; |
11993 | default: | 11869 | default: |
11994 | ScriptSleep(m_sleepMsOnRequestSimulatorData); | ||
11995 | return UUID.Zero.ToString(); // Raise no event | 11870 | return UUID.Zero.ToString(); // Raise no event |
11996 | } | 11871 | } |
11997 | UUID rq = UUID.Random(); | 11872 | UUID rq = UUID.Random(); |
@@ -12002,7 +11877,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12002 | AsyncCommands. | 11877 | AsyncCommands. |
12003 | DataserverPlugin.DataserverReply(rq.ToString(), reply); | 11878 | DataserverPlugin.DataserverReply(rq.ToString(), reply); |
12004 | 11879 | ||
12005 | ScriptSleep(m_sleepMsOnRequestSimulatorData); | ||
12006 | return tid.ToString(); | 11880 | return tid.ToString(); |
12007 | } | 11881 | } |
12008 | catch(Exception) | 11882 | catch(Exception) |
@@ -12142,8 +12016,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12142 | if (null != dm) | 12016 | if (null != dm) |
12143 | dm.SendUrlToUser( | 12017 | dm.SendUrlToUser( |
12144 | new UUID(avatar_id), m_host.Name, m_host.UUID, m_host.OwnerID, false, message, url); | 12018 | new UUID(avatar_id), m_host.Name, m_host.UUID, m_host.OwnerID, false, message, url); |
12145 | |||
12146 | ScriptSleep(m_sleepMsOnLoadURL); | ||
12147 | } | 12019 | } |
12148 | 12020 | ||
12149 | public void llParcelMediaCommandList(LSL_List commandList) | 12021 | public void llParcelMediaCommandList(LSL_List commandList) |
@@ -12382,7 +12254,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12382 | (ParcelMediaCommandEnum)commandToSend, time); | 12254 | (ParcelMediaCommandEnum)commandToSend, time); |
12383 | } | 12255 | } |
12384 | } | 12256 | } |
12385 | ScriptSleep(m_sleepMsOnParcelMediaCommandList); | ||
12386 | } | 12257 | } |
12387 | 12258 | ||
12388 | public LSL_List llParcelMediaQuery(LSL_List aList) | 12259 | public LSL_List llParcelMediaQuery(LSL_List aList) |
@@ -12421,7 +12292,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12421 | 12292 | ||
12422 | } | 12293 | } |
12423 | } | 12294 | } |
12424 | ScriptSleep(m_sleepMsOnParcelMediaQuery); | ||
12425 | return list; | 12295 | return list; |
12426 | } | 12296 | } |
12427 | 12297 | ||
@@ -12429,7 +12299,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12429 | { | 12299 | { |
12430 | Int64 tmp = 0; | 12300 | Int64 tmp = 0; |
12431 | Math.DivRem(Convert.ToInt64(Math.Pow(a, b)), c, out tmp); | 12301 | Math.DivRem(Convert.ToInt64(Math.Pow(a, b)), c, out tmp); |
12432 | ScriptSleep(m_sleepMsOnModPow); | ||
12433 | return Convert.ToInt32(tmp); | 12302 | return Convert.ToInt32(tmp); |
12434 | } | 12303 | } |
12435 | 12304 | ||
@@ -12509,13 +12378,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12509 | public void llSetPrimURL(string url) | 12378 | public void llSetPrimURL(string url) |
12510 | { | 12379 | { |
12511 | Deprecated("llSetPrimURL", "Use llSetPrimMediaParams instead"); | 12380 | Deprecated("llSetPrimURL", "Use llSetPrimMediaParams instead"); |
12512 | ScriptSleep(m_sleepMsOnSetPrimURL); | ||
12513 | } | 12381 | } |
12514 | 12382 | ||
12515 | public void llRefreshPrimURL() | 12383 | public void llRefreshPrimURL() |
12516 | { | 12384 | { |
12517 | Deprecated("llRefreshPrimURL"); | 12385 | Deprecated("llRefreshPrimURL"); |
12518 | ScriptSleep(m_sleepMsOnRefreshPrimURL); | ||
12519 | } | 12386 | } |
12520 | 12387 | ||
12521 | public LSL_String llEscapeURL(string url) | 12388 | public LSL_String llEscapeURL(string url) |
@@ -12564,7 +12431,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12564 | avatar.ControllingClient.SendScriptTeleportRequest(m_host.Name, | 12431 | avatar.ControllingClient.SendScriptTeleportRequest(m_host.Name, |
12565 | simname, pos, lookAt); | 12432 | simname, pos, lookAt); |
12566 | } | 12433 | } |
12567 | ScriptSleep(m_sleepMsOnMapDestination); | ||
12568 | } | 12434 | } |
12569 | 12435 | ||
12570 | public void llAddToLandBanList(string avatar, double hours) | 12436 | public void llAddToLandBanList(string avatar, double hours) |
@@ -12604,7 +12470,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12604 | World.EventManager.TriggerLandObjectUpdated((uint)land.LandData.LocalID, land); | 12470 | World.EventManager.TriggerLandObjectUpdated((uint)land.LandData.LocalID, land); |
12605 | } | 12471 | } |
12606 | } | 12472 | } |
12607 | ScriptSleep(m_sleepMsOnAddToLandBanList); | ||
12608 | } | 12473 | } |
12609 | 12474 | ||
12610 | public void llRemoveFromLandPassList(string avatar) | 12475 | public void llRemoveFromLandPassList(string avatar) |
@@ -12630,7 +12495,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12630 | } | 12495 | } |
12631 | } | 12496 | } |
12632 | } | 12497 | } |
12633 | ScriptSleep(m_sleepMsOnRemoveFromLandPassList); | ||
12634 | } | 12498 | } |
12635 | 12499 | ||
12636 | public void llRemoveFromLandBanList(string avatar) | 12500 | public void llRemoveFromLandBanList(string avatar) |
@@ -12656,7 +12520,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12656 | } | 12520 | } |
12657 | } | 12521 | } |
12658 | } | 12522 | } |
12659 | ScriptSleep(m_sleepMsOnRemoveFromLandBanList); | ||
12660 | } | 12523 | } |
12661 | 12524 | ||
12662 | public void llSetCameraParams(LSL_List rules) | 12525 | public void llSetCameraParams(LSL_List rules) |
@@ -13134,7 +12997,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
13134 | } | 12997 | } |
13135 | } | 12998 | } |
13136 | } | 12999 | } |
13137 | ScriptSleep(m_sleepMsOnResetLandBanList); | ||
13138 | } | 13000 | } |
13139 | 13001 | ||
13140 | public void llResetLandPassList() | 13002 | public void llResetLandPassList() |
@@ -13150,7 +13012,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
13150 | } | 13012 | } |
13151 | } | 13013 | } |
13152 | } | 13014 | } |
13153 | ScriptSleep(m_sleepMsOnResetLandPassList); | ||
13154 | } | 13015 | } |
13155 | 13016 | ||
13156 | public LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide) | 13017 | public LSL_Integer llGetParcelPrimCount(LSL_Vector pos, int category, int sim_wide) |
@@ -13205,7 +13066,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
13205 | ret.Add(new LSL_Integer(detectedParams.Value)); | 13066 | ret.Add(new LSL_Integer(detectedParams.Value)); |
13206 | } | 13067 | } |
13207 | } | 13068 | } |
13208 | ScriptSleep(m_sleepMsOnGetParcelPrimOwners); | ||
13209 | return ret; | 13069 | return ret; |
13210 | } | 13070 | } |
13211 | 13071 | ||
@@ -13790,7 +13650,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
13790 | { | 13650 | { |
13791 | AsyncCommands.DataserverPlugin.DataserverReply(reqIdentifier, NotecardCache.GetLines(assetID).ToString()); | 13651 | AsyncCommands.DataserverPlugin.DataserverReply(reqIdentifier, NotecardCache.GetLines(assetID).ToString()); |
13792 | 13652 | ||
13793 | ScriptSleep(m_sleepMsOnGetNumberOfNotecardLines); | ||
13794 | return tid.ToString(); | 13653 | return tid.ToString(); |
13795 | } | 13654 | } |
13796 | 13655 | ||
@@ -13806,7 +13665,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
13806 | AsyncCommands.DataserverPlugin.DataserverReply(reqIdentifier, NotecardCache.GetLines(id).ToString()); | 13665 | AsyncCommands.DataserverPlugin.DataserverReply(reqIdentifier, NotecardCache.GetLines(id).ToString()); |
13807 | }); | 13666 | }); |
13808 | 13667 | ||
13809 | ScriptSleep(m_sleepMsOnGetNumberOfNotecardLines); | ||
13810 | return tid.ToString(); | 13668 | return tid.ToString(); |
13811 | } | 13669 | } |
13812 | 13670 | ||
@@ -13840,7 +13698,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
13840 | AsyncCommands.DataserverPlugin.DataserverReply( | 13698 | AsyncCommands.DataserverPlugin.DataserverReply( |
13841 | reqIdentifier, NotecardCache.GetLine(assetID, line, m_notecardLineReadCharsMax)); | 13699 | reqIdentifier, NotecardCache.GetLine(assetID, line, m_notecardLineReadCharsMax)); |
13842 | 13700 | ||
13843 | ScriptSleep(m_sleepMsOnGetNotecardLine); | ||
13844 | return tid.ToString(); | 13701 | return tid.ToString(); |
13845 | } | 13702 | } |
13846 | 13703 | ||
@@ -13859,7 +13716,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
13859 | reqIdentifier, NotecardCache.GetLine(assetID, line, m_notecardLineReadCharsMax)); | 13716 | reqIdentifier, NotecardCache.GetLine(assetID, line, m_notecardLineReadCharsMax)); |
13860 | }); | 13717 | }); |
13861 | 13718 | ||
13862 | ScriptSleep(m_sleepMsOnGetNotecardLine); | ||
13863 | return tid.ToString(); | 13719 | return tid.ToString(); |
13864 | } | 13720 | } |
13865 | 13721 | ||
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index 2c025c1..d897098 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | |||
@@ -139,8 +139,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
139 | internal TaskInventoryItem m_item; | 139 | internal TaskInventoryItem m_item; |
140 | internal bool m_OSFunctionsEnabled = false; | 140 | internal bool m_OSFunctionsEnabled = false; |
141 | internal ThreatLevel m_MaxThreatLevel = ThreatLevel.VeryLow; | 141 | internal ThreatLevel m_MaxThreatLevel = ThreatLevel.VeryLow; |
142 | internal float m_ScriptDelayFactor = 1.0f; | ||
143 | internal float m_ScriptDistanceFactor = 1.0f; | ||
144 | internal bool m_debuggerSafe = false; | 142 | internal bool m_debuggerSafe = false; |
145 | internal Dictionary<string, FunctionPerms > m_FunctionPerms = new Dictionary<string, FunctionPerms >(); | 143 | internal Dictionary<string, FunctionPerms > m_FunctionPerms = new Dictionary<string, FunctionPerms >(); |
146 | protected IUrlModule m_UrlModule = null; | 144 | protected IUrlModule m_UrlModule = null; |
@@ -161,11 +159,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
161 | // m_log.Warn("[OSSL] OSSL FUNCTIONS ENABLED"); | 159 | // m_log.Warn("[OSSL] OSSL FUNCTIONS ENABLED"); |
162 | } | 160 | } |
163 | 161 | ||
164 | m_ScriptDelayFactor = | ||
165 | m_ScriptEngine.Config.GetFloat("ScriptDelayFactor", 1.0f); | ||
166 | m_ScriptDistanceFactor = | ||
167 | m_ScriptEngine.Config.GetFloat("ScriptDistanceLimitFactor", 1.0f); | ||
168 | |||
169 | string risk = m_ScriptEngine.Config.GetString("OSFunctionThreatLevel", "VeryLow"); | 162 | string risk = m_ScriptEngine.Config.GetString("OSFunctionThreatLevel", "VeryLow"); |
170 | switch (risk) | 163 | switch (risk) |
171 | { | 164 | { |
@@ -473,13 +466,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
473 | OSSLShoutError(string.Format("Use of function {0} is deprecated. Use {1} instead.", function, replacement)); | 466 | OSSLShoutError(string.Format("Use of function {0} is deprecated. Use {1} instead.", function, replacement)); |
474 | } | 467 | } |
475 | 468 | ||
476 | protected void ScriptSleep(int delay) | 469 | //// protected void ScriptSleep(int delay) |
477 | { | 470 | //// { |
478 | delay = (int)((float)delay * m_ScriptDelayFactor); | 471 | //// delay = (int)((float)delay * m_ScriptDelayFactor); |
479 | if (delay == 0) | 472 | //// if (delay == 0) |
480 | return; | 473 | //// return; |
481 | System.Threading.Thread.Sleep(delay); | 474 | //// System.Threading.Thread.Sleep(delay); |
482 | } | 475 | //// } |
483 | 476 | ||
484 | public LSL_Integer osSetTerrainHeight(int x, int y, double val) | 477 | public LSL_Integer osSetTerrainHeight(int x, int y, double val) |
485 | { | 478 | { |
@@ -881,17 +874,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
881 | 874 | ||
882 | Vector3 pos = presence.AbsolutePosition; | 875 | Vector3 pos = presence.AbsolutePosition; |
883 | if(!checkAllowAgentTPbyLandOwner(agentId, pos)) | 876 | if(!checkAllowAgentTPbyLandOwner(agentId, pos)) |
884 | { | ||
885 | ScriptSleep(500); | ||
886 | return; | 877 | return; |
887 | } | ||
888 | 878 | ||
889 | if(regionName == World.RegionInfo.RegionName) | 879 | if(regionName == World.RegionInfo.RegionName) |
890 | { | 880 | { |
891 | // should be faster than going to threadpool | 881 | // should be faster than going to threadpool |
892 | World.RequestTeleportLocation(presence.ControllingClient, regionName, position, | 882 | World.RequestTeleportLocation(presence.ControllingClient, regionName, position, |
893 | lookat, (uint)TPFlags.ViaLocation); | 883 | lookat, (uint)TPFlags.ViaLocation); |
894 | ScriptSleep(500); | ||
895 | } | 884 | } |
896 | else | 885 | else |
897 | { | 886 | { |
@@ -902,7 +891,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
902 | presence.ControllingClient, regionName, position, | 891 | presence.ControllingClient, regionName, position, |
903 | lookat, (uint)TPFlags.ViaLocation), | 892 | lookat, (uint)TPFlags.ViaLocation), |
904 | null, "OSSL_Api.TeleportAgentByRegionCoords"); | 893 | null, "OSSL_Api.TeleportAgentByRegionCoords"); |
905 | ScriptSleep(5000); | ||
906 | } | 894 | } |
907 | } | 895 | } |
908 | } | 896 | } |
@@ -930,18 +918,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
930 | 918 | ||
931 | Vector3 pos = presence.AbsolutePosition; | 919 | Vector3 pos = presence.AbsolutePosition; |
932 | if(!checkAllowAgentTPbyLandOwner(agentId, pos)) | 920 | if(!checkAllowAgentTPbyLandOwner(agentId, pos)) |
933 | { | ||
934 | ScriptSleep(500); | ||
935 | return; | 921 | return; |
936 | } | ||
937 | 922 | ||
938 | Util.FireAndForget( | 923 | Util.FireAndForget( |
939 | o => World.RequestTeleportLocation( | 924 | o => World.RequestTeleportLocation( |
940 | presence.ControllingClient, regionHandle, | 925 | presence.ControllingClient, regionHandle, |
941 | position, lookat, (uint)TPFlags.ViaLocation), | 926 | position, lookat, (uint)TPFlags.ViaLocation), |
942 | null, "OSSL_Api.TeleportAgentByRegionName"); | 927 | null, "OSSL_Api.TeleportAgentByRegionName"); |
943 | |||
944 | ScriptSleep(5000); | ||
945 | } | 928 | } |
946 | } | 929 | } |
947 | 930 | ||
@@ -956,14 +939,10 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
956 | 939 | ||
957 | Vector3 pos = presence.AbsolutePosition; | 940 | Vector3 pos = presence.AbsolutePosition; |
958 | if(!checkAllowAgentTPbyLandOwner(agentId, pos)) | 941 | if(!checkAllowAgentTPbyLandOwner(agentId, pos)) |
959 | { | ||
960 | ScriptSleep(500); | ||
961 | return; | 942 | return; |
962 | } | ||
963 | 943 | ||
964 | World.RequestTeleportLocation(presence.ControllingClient, World.RegionInfo.RegionName, position, | 944 | World.RequestTeleportLocation(presence.ControllingClient, World.RegionInfo.RegionName, position, |
965 | lookat, (uint)TPFlags.ViaLocation); | 945 | lookat, (uint)TPFlags.ViaLocation); |
966 | ScriptSleep(500); | ||
967 | } | 946 | } |
968 | } | 947 | } |
969 | 948 | ||
@@ -3389,8 +3368,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3389 | if (region != null) | 3368 | if (region != null) |
3390 | key = region.TerrainImage; | 3369 | key = region.TerrainImage; |
3391 | 3370 | ||
3392 | ScriptSleep(1000); | ||
3393 | |||
3394 | return key.ToString(); | 3371 | return key.ToString(); |
3395 | } | 3372 | } |
3396 | 3373 | ||