diff options
author | Melanie | 2013-08-07 23:29:42 +0100 |
---|---|---|
committer | Melanie | 2013-08-07 23:29:42 +0100 |
commit | 005c69511dac490a8353233423a3152abf5580dd (patch) | |
tree | abae7717af4af3ed7844f3747ab28398fdad9cdf /OpenSim/Region/CoreModules | |
parent | Merge branch 'avination-current' into careminster (diff) | |
parent | minor: add some method doc to ScenePresence fields used for entity transfer, ... (diff) | |
download | opensim-SC-005c69511dac490a8353233423a3152abf5580dd.zip opensim-SC-005c69511dac490a8353233423a3152abf5580dd.tar.gz opensim-SC-005c69511dac490a8353233423a3152abf5580dd.tar.bz2 opensim-SC-005c69511dac490a8353233423a3152abf5580dd.tar.xz |
Merge branch 'master' into careminster
Conflicts:
OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs
OpenSim/Region/Framework/Scenes/Scene.Inventory.cs
OpenSim/Region/Framework/Scenes/Scene.cs
Diffstat (limited to 'OpenSim/Region/CoreModules')
8 files changed, 119 insertions, 39 deletions
diff --git a/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs b/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs index 3764685..d9b0eff 100644 --- a/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs +++ b/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs | |||
@@ -166,7 +166,7 @@ namespace OpenSim.Region.CoreModules.Agent.TextureSender | |||
166 | 166 | ||
167 | // Do Decode! | 167 | // Do Decode! |
168 | if (decode) | 168 | if (decode) |
169 | Decode(assetID, j2kData); | 169 | Util.FireAndForget(delegate { Decode(assetID, j2kData); }); |
170 | } | 170 | } |
171 | } | 171 | } |
172 | 172 | ||
diff --git a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs index e1ca6cd..62b25d0 100644 --- a/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Attachments/AttachmentsModule.cs | |||
@@ -54,8 +54,8 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
54 | public int DebugLevel { get; set; } | 54 | public int DebugLevel { get; set; } |
55 | 55 | ||
56 | /// <summary> | 56 | /// <summary> |
57 | /// Period to sleep per 100 prims in order to avoid CPU spikes when an avatar with many attachments logs in | 57 | /// Period to sleep per 100 prims in order to avoid CPU spikes when an avatar with many attachments logs in/changes |
58 | /// or many avatars with a medium levels of attachments login simultaneously. | 58 | /// outfit or many avatars with a medium levels of attachments login/change outfit simultaneously. |
59 | /// </summary> | 59 | /// </summary> |
60 | /// <remarks> | 60 | /// <remarks> |
61 | /// A value of 0 will apply no pause. The pause is specified in milliseconds. | 61 | /// A value of 0 will apply no pause. The pause is specified in milliseconds. |
@@ -1094,7 +1094,19 @@ namespace OpenSim.Region.CoreModules.Avatar.Attachments | |||
1094 | } | 1094 | } |
1095 | 1095 | ||
1096 | if (tainted) | 1096 | if (tainted) |
1097 | objatt.HasGroupChanged = true; | 1097 | objatt.HasGroupChanged = true; |
1098 | |||
1099 | if (ThrottlePer100PrimsRezzed > 0) | ||
1100 | { | ||
1101 | int throttleMs = (int)Math.Round((float)objatt.PrimCount / 100 * ThrottlePer100PrimsRezzed); | ||
1102 | |||
1103 | if (DebugLevel > 0) | ||
1104 | m_log.DebugFormat( | ||
1105 | "[ATTACHMENTS MODULE]: Throttling by {0}ms after rez of {1} with {2} prims for attachment to {3} on point {4} in {5}", | ||
1106 | throttleMs, objatt.Name, objatt.PrimCount, sp.Name, attachmentPt, m_scene.Name); | ||
1107 | |||
1108 | Thread.Sleep(throttleMs); | ||
1109 | } | ||
1098 | 1110 | ||
1099 | return objatt; | 1111 | return objatt; |
1100 | } | 1112 | } |
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index df95bf0..4286eef 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |||
@@ -693,8 +693,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
693 | if (version.Equals("SIMULATION/0.2")) | 693 | if (version.Equals("SIMULATION/0.2")) |
694 | TransferAgent_V2(sp, agentCircuit, reg, finalDestination, endPoint, teleportFlags, oldRegionX, newRegionX, oldRegionY, newRegionY, version, out reason); | 694 | TransferAgent_V2(sp, agentCircuit, reg, finalDestination, endPoint, teleportFlags, oldRegionX, newRegionX, oldRegionY, newRegionY, version, out reason); |
695 | else | 695 | else |
696 | TransferAgent_V1(sp, agentCircuit, reg, finalDestination, endPoint, teleportFlags, oldRegionX, newRegionX, oldRegionY, newRegionY, version, out reason); | 696 | TransferAgent_V1(sp, agentCircuit, reg, finalDestination, endPoint, teleportFlags, oldRegionX, newRegionX, oldRegionY, newRegionY, version, out reason); |
697 | |||
698 | } | 697 | } |
699 | 698 | ||
700 | private void TransferAgent_V1(ScenePresence sp, AgentCircuitData agentCircuit, GridRegion reg, GridRegion finalDestination, | 699 | private void TransferAgent_V1(ScenePresence sp, AgentCircuitData agentCircuit, GridRegion reg, GridRegion finalDestination, |
@@ -703,7 +702,10 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
703 | ulong destinationHandle = finalDestination.RegionHandle; | 702 | ulong destinationHandle = finalDestination.RegionHandle; |
704 | AgentCircuitData currentAgentCircuit = sp.Scene.AuthenticateHandler.GetAgentCircuitData(sp.ControllingClient.CircuitCode); | 703 | AgentCircuitData currentAgentCircuit = sp.Scene.AuthenticateHandler.GetAgentCircuitData(sp.ControllingClient.CircuitCode); |
705 | 704 | ||
706 | m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Using TP V1"); | 705 | m_log.DebugFormat( |
706 | "[ENTITY TRANSFER MODULE]: Using TP V1 for {0} going from {1} to {2}", | ||
707 | sp.Name, Scene.Name, finalDestination.RegionName); | ||
708 | |||
707 | // Let's create an agent there if one doesn't exist yet. | 709 | // Let's create an agent there if one doesn't exist yet. |
708 | // NOTE: logout will always be false for a non-HG teleport. | 710 | // NOTE: logout will always be false for a non-HG teleport. |
709 | bool logout = false; | 711 | bool logout = false; |
@@ -961,6 +963,27 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
961 | return; | 963 | return; |
962 | } | 964 | } |
963 | 965 | ||
966 | if (m_entityTransferStateMachine.GetAgentTransferState(sp.UUID) == AgentTransferState.Cancelling) | ||
967 | { | ||
968 | m_interRegionTeleportCancels.Value++; | ||
969 | |||
970 | m_log.DebugFormat( | ||
971 | "[ENTITY TRANSFER MODULE]: Cancelled teleport of {0} to {1} from {2} after CreateAgent on client request", | ||
972 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | ||
973 | |||
974 | return; | ||
975 | } | ||
976 | else if (m_entityTransferStateMachine.GetAgentTransferState(sp.UUID) == AgentTransferState.Aborting) | ||
977 | { | ||
978 | m_interRegionTeleportAborts.Value++; | ||
979 | |||
980 | m_log.DebugFormat( | ||
981 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after CreateAgent due to previous client close.", | ||
982 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | ||
983 | |||
984 | return; | ||
985 | } | ||
986 | |||
964 | // Past this point we have to attempt clean up if the teleport fails, so update transfer state. | 987 | // Past this point we have to attempt clean up if the teleport fails, so update transfer state. |
965 | m_entityTransferStateMachine.UpdateInTransit(sp.UUID, AgentTransferState.Transferring); | 988 | m_entityTransferStateMachine.UpdateInTransit(sp.UUID, AgentTransferState.Transferring); |
966 | 989 | ||
@@ -1063,20 +1086,22 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1063 | if (!sp.DoNotCloseAfterTeleport) | 1086 | if (!sp.DoNotCloseAfterTeleport) |
1064 | { | 1087 | { |
1065 | // OK, it got this agent. Let's close everything | 1088 | // OK, it got this agent. Let's close everything |
1066 | m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Closing in agent {0} in region {1}", sp.Name, Scene.RegionInfo.RegionName); | 1089 | m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Closing in agent {0} in region {1}", sp.Name, Scene.Name); |
1067 | sp.CloseChildAgents(newRegionX, newRegionY); | 1090 | sp.CloseChildAgents(newRegionX, newRegionY); |
1068 | sp.Scene.IncomingCloseAgent(sp.UUID, false); | 1091 | sp.Scene.IncomingCloseAgent(sp.UUID, false); |
1069 | 1092 | ||
1070 | } | 1093 | } |
1071 | else | 1094 | else |
1072 | { | 1095 | { |
1073 | m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Not closing agent {0}, user is back in {0}", sp.Name, Scene.RegionInfo.RegionName); | 1096 | m_log.DebugFormat("[ENTITY TRANSFER MODULE]: Not closing agent {0}, user is back in {0}", sp.Name, Scene.Name); |
1074 | sp.DoNotCloseAfterTeleport = false; | 1097 | sp.DoNotCloseAfterTeleport = false; |
1075 | } | 1098 | } |
1076 | } | 1099 | } |
1077 | else | 1100 | else |
1101 | { | ||
1078 | // now we have a child agent in this region. | 1102 | // now we have a child agent in this region. |
1079 | sp.Reset(); | 1103 | sp.Reset(); |
1104 | } | ||
1080 | } | 1105 | } |
1081 | 1106 | ||
1082 | /// <summary> | 1107 | /// <summary> |
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs index 8f9800f..ce7ed26 100644 --- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs +++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/HGInventoryAccessModule.cs | |||
@@ -62,6 +62,8 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
62 | private string m_ThisGatekeeper; | 62 | private string m_ThisGatekeeper; |
63 | private bool m_RestrictInventoryAccessAbroad; | 63 | private bool m_RestrictInventoryAccessAbroad; |
64 | 64 | ||
65 | private bool m_bypassPermissions = true; | ||
66 | |||
65 | // private bool m_Initialized = false; | 67 | // private bool m_Initialized = false; |
66 | 68 | ||
67 | #region INonSharedRegionModule | 69 | #region INonSharedRegionModule |
@@ -100,6 +102,10 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
100 | } | 102 | } |
101 | else | 103 | else |
102 | m_log.Warn("[HG INVENTORY ACCESS MODULE]: HGInventoryAccessModule configs not found. ProfileServerURI not set!"); | 104 | m_log.Warn("[HG INVENTORY ACCESS MODULE]: HGInventoryAccessModule configs not found. ProfileServerURI not set!"); |
105 | |||
106 | m_bypassPermissions = !Util.GetConfigVarFromSections<bool>(source, "serverside_object_permissions", | ||
107 | new string[] { "Startup", "Permissions" }, true); | ||
108 | |||
103 | } | 109 | } |
104 | } | 110 | } |
105 | } | 111 | } |
@@ -114,6 +120,11 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
114 | scene.EventManager.OnNewInventoryItemUploadComplete += UploadInventoryItem; | 120 | scene.EventManager.OnNewInventoryItemUploadComplete += UploadInventoryItem; |
115 | scene.EventManager.OnTeleportStart += TeleportStart; | 121 | scene.EventManager.OnTeleportStart += TeleportStart; |
116 | scene.EventManager.OnTeleportFail += TeleportFail; | 122 | scene.EventManager.OnTeleportFail += TeleportFail; |
123 | |||
124 | // We're fgoing to enforce some stricter permissions if Outbound is false | ||
125 | scene.Permissions.OnTakeObject += CanTakeObject; | ||
126 | scene.Permissions.OnTakeCopyObject += CanTakeObject; | ||
127 | scene.Permissions.OnTransferUserInventory += OnTransferUserInventory; | ||
117 | } | 128 | } |
118 | 129 | ||
119 | #endregion | 130 | #endregion |
@@ -417,5 +428,36 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
417 | } | 428 | } |
418 | 429 | ||
419 | #endregion | 430 | #endregion |
431 | |||
432 | #region Permissions | ||
433 | |||
434 | private bool CanTakeObject(UUID objectID, UUID stealer, Scene scene) | ||
435 | { | ||
436 | if (m_bypassPermissions) return true; | ||
437 | |||
438 | if (!m_OutboundPermission && !UserManagementModule.IsLocalGridUser(stealer)) | ||
439 | { | ||
440 | SceneObjectGroup sog = null; | ||
441 | if (m_Scene.TryGetSceneObjectGroup(objectID, out sog) && sog.OwnerID == stealer) | ||
442 | return true; | ||
443 | |||
444 | return false; | ||
445 | } | ||
446 | |||
447 | return true; | ||
448 | } | ||
449 | |||
450 | private bool OnTransferUserInventory(UUID itemID, UUID userID, UUID recipientID) | ||
451 | { | ||
452 | if (m_bypassPermissions) return true; | ||
453 | |||
454 | if (!m_OutboundPermission && !UserManagementModule.IsLocalGridUser(recipientID)) | ||
455 | return false; | ||
456 | |||
457 | return true; | ||
458 | } | ||
459 | |||
460 | |||
461 | #endregion | ||
420 | } | 462 | } |
421 | } \ No newline at end of file | 463 | } \ No newline at end of file |
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs index aa00145..89bb037 100644 --- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs +++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs | |||
@@ -809,7 +809,7 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
809 | } | 809 | } |
810 | 810 | ||
811 | objlist.Add(g); | 811 | objlist.Add(g); |
812 | veclist.Add(new Vector3(0, 0, 0)); | 812 | veclist.Add(Vector3.Zero); |
813 | 813 | ||
814 | float offsetHeight = 0; | 814 | float offsetHeight = 0; |
815 | pos = m_Scene.GetNewRezLocation( | 815 | pos = m_Scene.GetNewRezLocation( |
diff --git a/OpenSim/Region/CoreModules/Scripting/ScriptModuleComms/ScriptModuleCommsModule.cs b/OpenSim/Region/CoreModules/Scripting/ScriptModuleComms/ScriptModuleCommsModule.cs index fccf053..bb304df 100644 --- a/OpenSim/Region/CoreModules/Scripting/ScriptModuleComms/ScriptModuleCommsModule.cs +++ b/OpenSim/Region/CoreModules/Scripting/ScriptModuleComms/ScriptModuleCommsModule.cs | |||
@@ -163,7 +163,7 @@ namespace OpenSim.Region.CoreModules.Scripting.ScriptModuleComms | |||
163 | 163 | ||
164 | public void RegisterScriptInvocation(object target, MethodInfo mi) | 164 | public void RegisterScriptInvocation(object target, MethodInfo mi) |
165 | { | 165 | { |
166 | m_log.DebugFormat("[MODULE COMMANDS] Register method {0} from type {1}", mi.Name, (target is Type) ? ((Type)target).Name : target.GetType().Name); | 166 | // m_log.DebugFormat("[MODULE COMMANDS] Register method {0} from type {1}", mi.Name, (target is Type) ? ((Type)target).Name : target.GetType().Name); |
167 | 167 | ||
168 | Type delegateType; | 168 | Type delegateType; |
169 | List<Type> typeArgs = mi.GetParameters() | 169 | List<Type> typeArgs = mi.GetParameters() |
@@ -325,7 +325,7 @@ namespace OpenSim.Region.CoreModules.Scripting.ScriptModuleComms | |||
325 | /// </summary> | 325 | /// </summary> |
326 | public void RegisterConstant(string cname, object value) | 326 | public void RegisterConstant(string cname, object value) |
327 | { | 327 | { |
328 | m_log.DebugFormat("[MODULE COMMANDS] register constant <{0}> with value {1}",cname,value.ToString()); | 328 | // m_log.DebugFormat("[MODULE COMMANDS] register constant <{0}> with value {1}",cname,value.ToString()); |
329 | lock (m_constants) | 329 | lock (m_constants) |
330 | { | 330 | { |
331 | m_constants.Add(cname,value); | 331 | m_constants.Add(cname,value); |
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs index a5adc29..a9aa73c 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs | |||
@@ -63,35 +63,41 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation | |||
63 | /// </summary> | 63 | /// </summary> |
64 | private bool m_ModuleEnabled = false; | 64 | private bool m_ModuleEnabled = false; |
65 | 65 | ||
66 | public LocalSimulationConnectorModule() | ||
67 | { | ||
68 | ServiceVersion = "SIMULATION/0.2"; | ||
69 | } | ||
70 | |||
71 | #region Region Module interface | 66 | #region Region Module interface |
72 | 67 | ||
73 | public void Initialise(IConfigSource config) | 68 | public void Initialise(IConfigSource configSource) |
74 | { | 69 | { |
75 | IConfig moduleConfig = config.Configs["Modules"]; | 70 | IConfig moduleConfig = configSource.Configs["Modules"]; |
76 | if (moduleConfig != null) | 71 | if (moduleConfig != null) |
77 | { | 72 | { |
78 | string name = moduleConfig.GetString("SimulationServices", ""); | 73 | string name = moduleConfig.GetString("SimulationServices", ""); |
79 | if (name == Name) | 74 | if (name == Name) |
80 | { | 75 | { |
81 | //IConfig userConfig = config.Configs["SimulationService"]; | 76 | InitialiseService(configSource); |
82 | //if (userConfig == null) | ||
83 | //{ | ||
84 | // m_log.Error("[AVATAR CONNECTOR]: SimulationService missing from OpenSim.ini"); | ||
85 | // return; | ||
86 | //} | ||
87 | 77 | ||
88 | m_ModuleEnabled = true; | 78 | m_ModuleEnabled = true; |
89 | 79 | ||
90 | m_log.Info("[SIMULATION CONNECTOR]: Local simulation enabled"); | 80 | m_log.Info("[LOCAL SIMULATION CONNECTOR]: Local simulation enabled."); |
91 | } | 81 | } |
92 | } | 82 | } |
93 | } | 83 | } |
94 | 84 | ||
85 | public void InitialiseService(IConfigSource configSource) | ||
86 | { | ||
87 | ServiceVersion = "SIMULATION/0.2"; | ||
88 | IConfig config = configSource.Configs["SimulationService"]; | ||
89 | if (config != null) | ||
90 | { | ||
91 | ServiceVersion = config.GetString("ConnectorProtocolVersion", ServiceVersion); | ||
92 | |||
93 | if (ServiceVersion != "SIMULATION/0.1" && ServiceVersion != "SIMULATION/0.2") | ||
94 | throw new Exception(string.Format("Invalid ConnectorProtocolVersion {0}", ServiceVersion)); | ||
95 | |||
96 | m_log.InfoFormat( | ||
97 | "[LOCAL SIMULATION CONNECTOR]: Initialzied with connector protocol version {0}", ServiceVersion); | ||
98 | } | ||
99 | } | ||
100 | |||
95 | public void PostInitialise() | 101 | public void PostInitialise() |
96 | { | 102 | { |
97 | } | 103 | } |
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs index a1ab3e3..8bd1d10 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs | |||
@@ -50,9 +50,9 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation | |||
50 | [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule", Id = "RemoteSimulationConnectorModule")] | 50 | [Extension(Path = "/OpenSim/RegionModules", NodeName = "RegionModule", Id = "RemoteSimulationConnectorModule")] |
51 | public class RemoteSimulationConnectorModule : ISharedRegionModule, ISimulationService | 51 | public class RemoteSimulationConnectorModule : ISharedRegionModule, ISimulationService |
52 | { | 52 | { |
53 | private bool initialized = false; | ||
54 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 53 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
55 | 54 | ||
55 | private bool initialized = false; | ||
56 | protected bool m_enabled = false; | 56 | protected bool m_enabled = false; |
57 | protected Scene m_aScene; | 57 | protected Scene m_aScene; |
58 | // RemoteSimulationConnector does not care about local regions; it delegates that to the Local module | 58 | // RemoteSimulationConnector does not care about local regions; it delegates that to the Local module |
@@ -64,27 +64,23 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation | |||
64 | 64 | ||
65 | #region Region Module interface | 65 | #region Region Module interface |
66 | 66 | ||
67 | public virtual void Initialise(IConfigSource config) | 67 | public virtual void Initialise(IConfigSource configSource) |
68 | { | 68 | { |
69 | 69 | IConfig moduleConfig = configSource.Configs["Modules"]; | |
70 | IConfig moduleConfig = config.Configs["Modules"]; | ||
71 | if (moduleConfig != null) | 70 | if (moduleConfig != null) |
72 | { | 71 | { |
73 | string name = moduleConfig.GetString("SimulationServices", ""); | 72 | string name = moduleConfig.GetString("SimulationServices", ""); |
74 | if (name == Name) | 73 | if (name == Name) |
75 | { | 74 | { |
76 | //IConfig userConfig = config.Configs["SimulationService"]; | 75 | m_localBackend = new LocalSimulationConnectorModule(); |
77 | //if (userConfig == null) | 76 | |
78 | //{ | 77 | m_localBackend.InitialiseService(configSource); |
79 | // m_log.Error("[AVATAR CONNECTOR]: SimulationService missing from OpenSim.ini"); | ||
80 | // return; | ||
81 | //} | ||
82 | 78 | ||
83 | m_remoteConnector = new SimulationServiceConnector(); | 79 | m_remoteConnector = new SimulationServiceConnector(); |
84 | 80 | ||
85 | m_enabled = true; | 81 | m_enabled = true; |
86 | 82 | ||
87 | m_log.Info("[SIMULATION CONNECTOR]: Remote simulation enabled"); | 83 | m_log.Info("[REMOTE SIMULATION CONNECTOR]: Remote simulation enabled."); |
88 | } | 84 | } |
89 | } | 85 | } |
90 | } | 86 | } |
@@ -142,8 +138,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation | |||
142 | } | 138 | } |
143 | 139 | ||
144 | protected virtual void InitOnce(Scene scene) | 140 | protected virtual void InitOnce(Scene scene) |
145 | { | 141 | { |
146 | m_localBackend = new LocalSimulationConnectorModule(); | ||
147 | m_aScene = scene; | 142 | m_aScene = scene; |
148 | //m_regionClient = new RegionToRegionClient(m_aScene, m_hyperlinkService); | 143 | //m_regionClient = new RegionToRegionClient(m_aScene, m_hyperlinkService); |
149 | m_thisIP = Util.GetHostFromDNS(scene.RegionInfo.ExternalHostName); | 144 | m_thisIP = Util.GetHostFromDNS(scene.RegionInfo.ExternalHostName); |