mirror of
https://github.com/opensim/opensim.git
synced 2026-07-31 22:05:36 +08:00
Implemented plugin support for ClientStack, with LindenUDP as the default plugin. This makes it easy for developers to experiment with alternative communication protocols
This commit is contained in:
@@ -35,7 +35,6 @@ using OpenSim.Framework;
|
||||
using OpenSim.Framework.Communications;
|
||||
using OpenSim.Framework.Communications.Cache;
|
||||
using OpenSim.Framework.Servers;
|
||||
using OpenSim.Region.ClientStack.LindenUDP;
|
||||
using OpenSim.Region.Environment;
|
||||
using OpenSim.Region.Environment.Scenes;
|
||||
using OpenSim.Region.Physics.Manager;
|
||||
@@ -64,6 +63,8 @@ namespace OpenSim.Region.ClientStack
|
||||
protected StorageManager m_storageManager;
|
||||
protected string m_storageConnectionString;
|
||||
|
||||
protected ClientStackManager m_clientStackManager;
|
||||
|
||||
// An attribute to indicate whether prim inventories should be persisted.
|
||||
// Probably will be temporary until this stops being experimental.
|
||||
protected bool m_storagePersistPrimInventories;
|
||||
@@ -77,10 +78,10 @@ namespace OpenSim.Region.ClientStack
|
||||
{
|
||||
base.Startup();
|
||||
|
||||
LLClientView.TerrainManager = new TerrainManager(new SecondLife());
|
||||
|
||||
m_storageManager = CreateStorageManager(m_storageConnectionString);
|
||||
|
||||
m_clientStackManager = CreateClientStackManager();
|
||||
|
||||
Initialize();
|
||||
|
||||
m_httpServer = new BaseHttpServer(m_httpServerPort);
|
||||
@@ -101,6 +102,7 @@ namespace OpenSim.Region.ClientStack
|
||||
// protected abstract ConsoleBase CreateConsole();
|
||||
protected abstract PhysicsScene GetPhysicsScene();
|
||||
protected abstract StorageManager CreateStorageManager(string connectionstring);
|
||||
protected abstract ClientStackManager CreateClientStackManager();
|
||||
|
||||
protected PhysicsScene GetPhysicsScene(string engine, string meshEngine, IConfigSource config)
|
||||
{
|
||||
@@ -123,7 +125,7 @@ namespace OpenSim.Region.ClientStack
|
||||
// listenIP = IPAddress.Parse("0.0.0.0");
|
||||
|
||||
uint port = (uint) regionInfo.InternalEndPoint.Port;
|
||||
clientServer = new LLUDPServer(listenIP, ref port, proxyOffset, regionInfo.m_allow_alternate_ports, m_assetCache, circuitManager);
|
||||
clientServer = m_clientStackManager.CreateServer(listenIP, ref port, proxyOffset, regionInfo.m_allow_alternate_ports, m_assetCache, circuitManager);
|
||||
regionInfo.InternalEndPoint.Port = (int)port;
|
||||
|
||||
Scene scene = CreateScene(regionInfo, m_storageManager, circuitManager);
|
||||
|
||||
Reference in New Issue
Block a user