aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/Api/Implementation
diff options
context:
space:
mode:
authorMelanie Thielker2010-06-11 17:42:16 +0200
committerMelanie2010-06-11 17:42:41 +0100
commit7c4cf46bacadae56e7cfcc07d243b1c5f5cb98ce (patch)
tree7341db0368b492d9ed311e6f62a110ffb065ce23 /OpenSim/Region/ScriptEngine/Shared/Api/Implementation
parentRename cm* function set to ls* (for LightShare) (diff)
downloadopensim-SC_OLD-7c4cf46bacadae56e7cfcc07d243b1c5f5cb98ce.zip
opensim-SC_OLD-7c4cf46bacadae56e7cfcc07d243b1c5f5cb98ce.tar.gz
opensim-SC_OLD-7c4cf46bacadae56e7cfcc07d243b1c5f5cb98ce.tar.bz2
opensim-SC_OLD-7c4cf46bacadae56e7cfcc07d243b1c5f5cb98ce.tar.xz
Rename CM files to LS
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/Api/Implementation')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LS_Api.cs (renamed from OpenSim/Region/ScriptEngine/Shared/Api/Implementation/CM_Api.cs)30
1 files changed, 15 insertions, 15 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/CM_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LS_Api.cs
index 9a99f5e..fe71ed5 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/CM_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LS_Api.cs
@@ -54,13 +54,13 @@ using LSL_Vector = OpenSim.Region.ScriptEngine.Shared.LSL_Types.Vector3;
54namespace OpenSim.Region.ScriptEngine.Shared.Api 54namespace OpenSim.Region.ScriptEngine.Shared.Api
55{ 55{
56 [Serializable] 56 [Serializable]
57 public class CM_Api : MarshalByRefObject, ICM_Api, IScriptApi 57 public class LS_Api : MarshalByRefObject, ILS_Api, IScriptApi
58 { 58 {
59 internal IScriptEngine m_ScriptEngine; 59 internal IScriptEngine m_ScriptEngine;
60 internal SceneObjectPart m_host; 60 internal SceneObjectPart m_host;
61 internal uint m_localID; 61 internal uint m_localID;
62 internal UUID m_itemID; 62 internal UUID m_itemID;
63 internal bool m_CMFunctionsEnabled = false; 63 internal bool m_LSFunctionsEnabled = false;
64 internal IScriptModuleComms m_comms = null; 64 internal IScriptModuleComms m_comms = null;
65 65
66 public void Initialize(IScriptEngine ScriptEngine, SceneObjectPart host, uint localID, UUID itemID) 66 public void Initialize(IScriptEngine ScriptEngine, SceneObjectPart host, uint localID, UUID itemID)
@@ -71,11 +71,11 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
71 m_itemID = itemID; 71 m_itemID = itemID;
72 72
73 if (m_ScriptEngine.Config.GetBoolean("AllowLightShareFunctions", false)) 73 if (m_ScriptEngine.Config.GetBoolean("AllowLightShareFunctions", false))
74 m_CMFunctionsEnabled = true; 74 m_LSFunctionsEnabled = true;
75 75
76 m_comms = m_ScriptEngine.World.RequestModuleInterface<IScriptModuleComms>(); 76 m_comms = m_ScriptEngine.World.RequestModuleInterface<IScriptModuleComms>();
77 if (m_comms == null) 77 if (m_comms == null)
78 m_CMFunctionsEnabled = false; 78 m_LSFunctionsEnabled = false;
79 } 79 }
80 80
81 public override Object InitializeLifetimeService() 81 public override Object InitializeLifetimeService()
@@ -100,7 +100,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
100 //Dumps an error message on the debug console. 100 //Dumps an error message on the debug console.
101 // 101 //
102 102
103 internal void CMShoutError(string message) 103 internal void LSShoutError(string message)
104 { 104 {
105 if (message.Length > 1023) 105 if (message.Length > 1023)
106 message = message.Substring(0, 1023); 106 message = message.Substring(0, 1023);
@@ -118,9 +118,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
118 /// <returns>List of windlight parameters</returns> 118 /// <returns>List of windlight parameters</returns>
119 public LSL_List lsGetWindlightScene(LSL_List rules) 119 public LSL_List lsGetWindlightScene(LSL_List rules)
120 { 120 {
121 if (!m_CMFunctionsEnabled) 121 if (!m_LSFunctionsEnabled)
122 { 122 {
123 CMShoutError("LightShare functions are not enabled."); 123 LSShoutError("LightShare functions are not enabled.");
124 return new LSL_List(); 124 return new LSL_List();
125 } 125 }
126 m_host.AddScriptLPS(1); 126 m_host.AddScriptLPS(1);
@@ -442,14 +442,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
442 /// <returns>success: true or false</returns> 442 /// <returns>success: true or false</returns>
443 public int lsSetWindlightScene(LSL_List rules) 443 public int lsSetWindlightScene(LSL_List rules)
444 { 444 {
445 if (!m_CMFunctionsEnabled) 445 if (!m_LSFunctionsEnabled)
446 { 446 {
447 CMShoutError("LightShare functions are not enabled."); 447 LSShoutError("LightShare functions are not enabled.");
448 return 0; 448 return 0;
449 } 449 }
450 if (!World.RegionInfo.EstateSettings.IsEstateManager(m_host.OwnerID) && World.GetScenePresence(m_host.OwnerID).GodLevel < 200) 450 if (!World.RegionInfo.EstateSettings.IsEstateManager(m_host.OwnerID) && World.GetScenePresence(m_host.OwnerID).GodLevel < 200)
451 { 451 {
452 CMShoutError("lsSetWindlightScene can only be used by estate managers or owners."); 452 LSShoutError("lsSetWindlightScene can only be used by estate managers or owners.");
453 return 0; 453 return 0;
454 } 454 }
455 int success = 0; 455 int success = 0;
@@ -462,7 +462,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
462 } 462 }
463 else 463 else
464 { 464 {
465 CMShoutError("Windlight module is disabled"); 465 LSShoutError("Windlight module is disabled");
466 return 0; 466 return 0;
467 } 467 }
468 return success; 468 return success;
@@ -474,14 +474,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
474 /// <returns>success: true or false</returns> 474 /// <returns>success: true or false</returns>
475 public int lsSetWindlightSceneTargeted(LSL_List rules, LSL_Key target) 475 public int lsSetWindlightSceneTargeted(LSL_List rules, LSL_Key target)
476 { 476 {
477 if (!m_CMFunctionsEnabled) 477 if (!m_LSFunctionsEnabled)
478 { 478 {
479 CMShoutError("LightShare functions are not enabled."); 479 LSShoutError("LightShare functions are not enabled.");
480 return 0; 480 return 0;
481 } 481 }
482 if (!World.RegionInfo.EstateSettings.IsEstateManager(m_host.OwnerID) && World.GetScenePresence(m_host.OwnerID).GodLevel < 200) 482 if (!World.RegionInfo.EstateSettings.IsEstateManager(m_host.OwnerID) && World.GetScenePresence(m_host.OwnerID).GodLevel < 200)
483 { 483 {
484 CMShoutError("lsSetWindlightSceneTargeted can only be used by estate managers or owners."); 484 LSShoutError("lsSetWindlightSceneTargeted can only be used by estate managers or owners.");
485 return 0; 485 return 0;
486 } 486 }
487 int success = 0; 487 int success = 0;
@@ -494,7 +494,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
494 } 494 }
495 else 495 else
496 { 496 {
497 CMShoutError("Windlight module is disabled"); 497 LSShoutError("Windlight module is disabled");
498 return 0; 498 return 0;
499 } 499 }
500 return success; 500 return success;