diff options
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index f5089aa..8903c3b 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -8023,6 +8023,26 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
8023 | return ScriptBaseClass.LSL_STATUS_OK; | 8023 | return ScriptBaseClass.LSL_STATUS_OK; |
8024 | } | 8024 | } |
8025 | 8025 | ||
8026 | public LSL_Integer llClearPrimMedia(LSL_Integer face) | ||
8027 | { | ||
8028 | m_host.AddScriptLPS(1); | ||
8029 | ScriptSleep(1000); | ||
8030 | |||
8031 | // LSL Spec http://wiki.secondlife.com/wiki/LlClearPrimMedia says to fail silently if face is invalid | ||
8032 | // Assuming silently fail means sending back LSL_STATUS_OK. Ideally, need to check this. | ||
8033 | // FIXME: Don't perform the media check directly | ||
8034 | if (face < 0 || face > m_host.GetNumberOfSides() - 1) | ||
8035 | return ScriptBaseClass.LSL_STATUS_OK; | ||
8036 | |||
8037 | IMoapModule module = m_ScriptEngine.World.RequestModuleInterface<IMoapModule>(); | ||
8038 | if (null == module) | ||
8039 | throw new Exception("Media on a prim functions not available"); | ||
8040 | |||
8041 | module.ClearMediaEntry(m_host, face); | ||
8042 | |||
8043 | return ScriptBaseClass.LSL_STATUS_OK; | ||
8044 | } | ||
8045 | |||
8026 | // <remarks> | 8046 | // <remarks> |
8027 | // <para> | 8047 | // <para> |
8028 | // The .NET definition of base 64 is: | 8048 | // The .NET definition of base 64 is: |