aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2010-07-12 22:00:45 +0100
committerJustin Clark-Casey (justincc)2010-07-12 22:00:45 +0100
commit4b0c5711b5099f3611783e103629deaa9033cd7f (patch)
tree9d76a505de68e386ea7f0db46ba9e9f2f822cfaf /OpenSim/Region/ScriptEngine/Shared
parentfix issue with GetMediaEntry if the face requested wasn't set to a media texture (diff)
downloadopensim-SC_OLD-4b0c5711b5099f3611783e103629deaa9033cd7f.zip
opensim-SC_OLD-4b0c5711b5099f3611783e103629deaa9033cd7f.tar.gz
opensim-SC_OLD-4b0c5711b5099f3611783e103629deaa9033cd7f.tar.bz2
opensim-SC_OLD-4b0c5711b5099f3611783e103629deaa9033cd7f.tar.xz
implement llClearPrimMedia()
untested
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs20
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 ff2f6a2..4773a50 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: