diff options
author | Mic Bowman | 2012-03-15 13:16:02 -0700 |
---|---|---|
committer | Mic Bowman | 2012-03-15 13:16:02 -0700 |
commit | 402ff75d781d6f4e38eee8884d7b4411bb756c9b (patch) | |
tree | d51e46418d1edab07c762dc0b7c37bb0c6333177 /OpenSim/Region/ScriptEngine/Shared/Api/Runtime | |
parent | Remove property/field duplication in ScriptInstance where it's unnecessary. (diff) | |
download | opensim-SC_OLD-402ff75d781d6f4e38eee8884d7b4411bb756c9b.zip opensim-SC_OLD-402ff75d781d6f4e38eee8884d7b4411bb756c9b.tar.gz opensim-SC_OLD-402ff75d781d6f4e38eee8884d7b4411bb756c9b.tar.bz2 opensim-SC_OLD-402ff75d781d6f4e38eee8884d7b4411bb756c9b.tar.xz |
Adds a new script command 'modInvoke' to invoke registered functions
from region modules. The LSL translator is extended to generate the
modInvoke format of commands for directly inlined function calls.
A region module can register a function Test() with the name "Test".
LSL code can call that function as "Test()". The compiler will translate
that invocation into modInvoke("Test", ...)
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Runtime/MOD_Stub.cs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/MOD_Stub.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/MOD_Stub.cs index 6525c76..04b7f14 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/MOD_Stub.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/MOD_Stub.cs | |||
@@ -58,6 +58,21 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase | |||
58 | m_MOD_Functions = (IMOD_Api)api; | 58 | m_MOD_Functions = (IMOD_Api)api; |
59 | } | 59 | } |
60 | 60 | ||
61 | public string modInvokeS(string fname, params object[] parms) | ||
62 | { | ||
63 | return m_MOD_Functions.modInvokeS(fname, parms); | ||
64 | } | ||
65 | |||
66 | public int modInvokeI(string fname, params object[] parms) | ||
67 | { | ||
68 | return m_MOD_Functions.modInvokeI(fname, parms); | ||
69 | } | ||
70 | |||
71 | public float modInvokeF(string fname, params object[] parms) | ||
72 | { | ||
73 | return m_MOD_Functions.modInvokeF(fname, parms); | ||
74 | } | ||
75 | |||
61 | public string modSendCommand(string module, string command, string k) | 76 | public string modSendCommand(string module, string command, string k) |
62 | { | 77 | { |
63 | return m_MOD_Functions.modSendCommand(module, command, k); | 78 | return m_MOD_Functions.modSendCommand(module, command, k); |