diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ClientStack/RegionApplicationBase.cs | 81 |
1 files changed, 0 insertions, 81 deletions
diff --git a/OpenSim/Region/ClientStack/RegionApplicationBase.cs b/OpenSim/Region/ClientStack/RegionApplicationBase.cs index 731e0e5..c1c212c 100644 --- a/OpenSim/Region/ClientStack/RegionApplicationBase.cs +++ b/OpenSim/Region/ClientStack/RegionApplicationBase.cs | |||
@@ -141,86 +141,5 @@ namespace OpenSim.Region.ClientStack | |||
141 | 141 | ||
142 | return physicsPluginManager.GetPhysicsScene(engine, meshEngine, config, osSceneIdentifier); | 142 | return physicsPluginManager.GetPhysicsScene(engine, meshEngine, config, osSceneIdentifier); |
143 | } | 143 | } |
144 | |||
145 | /// <summary> | ||
146 | /// Create a scene and its initial base structures. | ||
147 | /// </summary> | ||
148 | /// <param name="regionInfo"></param> | ||
149 | /// <param name="clientServer"> </param> | ||
150 | /// <returns></returns> | ||
151 | protected Scene SetupScene(RegionInfo regionInfo, out IClientNetworkServer clientServer) | ||
152 | { | ||
153 | return SetupScene(regionInfo, 0, null, out clientServer); | ||
154 | } | ||
155 | |||
156 | /// <summary> | ||
157 | /// Create a scene and its initial base structures. | ||
158 | /// </summary> | ||
159 | /// TODO: Really configSource shouldn't be passed in here, but should be moved up to BaseOpenSimServer and | ||
160 | /// made common to all the servers. | ||
161 | /// | ||
162 | /// <param name="regionInfo"></param> | ||
163 | /// <param name="proxyOffset"></param> | ||
164 | /// <param name="configSource"></param> | ||
165 | /// <param name="clientServer"> </param> | ||
166 | /// <returns></returns> | ||
167 | protected Scene SetupScene( | ||
168 | RegionInfo regionInfo, int proxyOffset, IConfigSource configSource, out IClientNetworkServer clientServer) | ||
169 | { | ||
170 | AgentCircuitManager circuitManager = new AgentCircuitManager(); | ||
171 | IPAddress listenIP = regionInfo.InternalEndPoint.Address; | ||
172 | //if (!IPAddress.TryParse(regionInfo.InternalEndPoint, out listenIP)) | ||
173 | // listenIP = IPAddress.Parse("0.0.0.0"); | ||
174 | |||
175 | uint port = (uint) regionInfo.InternalEndPoint.Port; | ||
176 | |||
177 | clientServer | ||
178 | = m_clientStackManager.CreateServer( | ||
179 | listenIP, ref port, proxyOffset, regionInfo.m_allow_alternate_ports, configSource, | ||
180 | m_assetCache, circuitManager); | ||
181 | |||
182 | regionInfo.InternalEndPoint.Port = (int)port; | ||
183 | |||
184 | Scene scene = CreateScene(regionInfo, m_storageManager, circuitManager); | ||
185 | |||
186 | clientServer.AddScene(scene); | ||
187 | |||
188 | scene.LoadWorldMap(); | ||
189 | |||
190 | scene.PhysicsScene = GetPhysicsScene(scene.RegionInfo.RegionName); | ||
191 | scene.PhysicsScene.SetTerrain(scene.Heightmap.GetFloatsSerialised()); | ||
192 | scene.PhysicsScene.SetWaterLevel((float)regionInfo.RegionSettings.WaterHeight); | ||
193 | |||
194 | // TODO: Remove this cruft once MasterAvatar is fully deprecated | ||
195 | //Master Avatar Setup | ||
196 | UserProfileData masterAvatar; | ||
197 | if (scene.RegionInfo.MasterAvatarAssignedUUID == UUID.Zero) | ||
198 | { | ||
199 | masterAvatar = | ||
200 | m_commsManager.UserService.SetupMasterUser(scene.RegionInfo.MasterAvatarFirstName, | ||
201 | scene.RegionInfo.MasterAvatarLastName, | ||
202 | scene.RegionInfo.MasterAvatarSandboxPassword); | ||
203 | } | ||
204 | else | ||
205 | { | ||
206 | masterAvatar = m_commsManager.UserService.SetupMasterUser(scene.RegionInfo.MasterAvatarAssignedUUID); | ||
207 | scene.RegionInfo.MasterAvatarFirstName = masterAvatar.FirstName; | ||
208 | scene.RegionInfo.MasterAvatarLastName = masterAvatar.SurName; | ||
209 | } | ||
210 | |||
211 | if (masterAvatar == null) | ||
212 | { | ||
213 | m_log.Info("[PARCEL]: No master avatar found, using null."); | ||
214 | scene.RegionInfo.MasterAvatarAssignedUUID = UUID.Zero; | ||
215 | } | ||
216 | else | ||
217 | { | ||
218 | m_log.InfoFormat("[PARCEL]: Found master avatar {0} {1} [" + masterAvatar.ID.ToString() + "]", | ||
219 | scene.RegionInfo.MasterAvatarFirstName, scene.RegionInfo.MasterAvatarLastName); | ||
220 | scene.RegionInfo.MasterAvatarAssignedUUID = masterAvatar.ID; | ||
221 | } | ||
222 | |||
223 | return scene; | ||
224 | } | ||
225 | } | 144 | } |
226 | } | 145 | } |