mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 22:26:09 +08:00
Fixed SimpleApp - aka thankgoditssundaycommit
* Updated SimpleApp with various introduced dependencies * Extracted ScenePrescence creation in Scene * removed try-catchall from UserManagerBase (that actually hid a bug) * Refactored RegionInfo * handle is calculated * it will explode upon accessing x,y,ip,port,externalip if not explicitly initialized * Removed superfluous 'ref' keywords * Removed a shitload of 'catch Exception e' that causes build warnings * Lots of small refactorings, renames et c * Ignored some bins
This commit is contained in:
@@ -14,6 +14,7 @@ using OpenSim.Region.Caches;
|
||||
using OpenSim.Framework.Communications;
|
||||
using OpenSim.Region.Communications.Local;
|
||||
using OpenSim.Region.ClientStack;
|
||||
using OpenSim.Region.Physics.BasicPhysicsPlugin;
|
||||
|
||||
namespace SimpleApp
|
||||
{
|
||||
@@ -32,11 +33,7 @@ namespace SimpleApp
|
||||
|
||||
string simAddr = "127.0.0.1";
|
||||
int simPort = 9000;
|
||||
/*
|
||||
LoginServer loginServer = new LoginServer( simAddr, simPort, 0, 0, false );
|
||||
loginServer.Startup();
|
||||
loginServer.SetSessionHandler( AddNewSessionHandler );*/
|
||||
|
||||
|
||||
m_circuitManager = new AuthenticateSessionsBase();
|
||||
|
||||
InventoryCache inventoryCache = new InventoryCache();
|
||||
@@ -53,18 +50,17 @@ namespace SimpleApp
|
||||
|
||||
ClientView.TerrainManager = new TerrainManager(new SecondLife());
|
||||
|
||||
CommunicationsManager communicationsManager = new CommunicationsLocal(null);
|
||||
NetworkServersInfo serverInfo = new NetworkServersInfo();
|
||||
CommunicationsLocal communicationsManager = new CommunicationsLocal(serverInfo);
|
||||
|
||||
RegionInfo regionInfo = new RegionInfo( 1000, 1000, simAddr, simPort, simAddr );
|
||||
|
||||
RegionInfo regionInfo = new RegionInfo( );
|
||||
BaseHttpServer httpServer = new BaseHttpServer(simPort);
|
||||
udpServer.LocalWorld = new MyWorld( packetServer.ClientAPIs, regionInfo, m_circuitManager, communicationsManager, assetCache, httpServer );
|
||||
MyWorld world = new MyWorld(packetServer.ClientAPIs, regionInfo, m_circuitManager, communicationsManager, assetCache, httpServer);
|
||||
world.PhysScene = new BasicScene();
|
||||
udpServer.LocalWorld = world;
|
||||
|
||||
// World world = new World(udpServer.PacketServer.ClientAPIs, regionInfo);
|
||||
// PhysicsScene physicsScene = new NullPhysicsScene();
|
||||
// world.PhysicsScene = physicsScene;
|
||||
// udpServer.LocalWorld = world;
|
||||
|
||||
// httpServer.AddXmlRPCHandler( "login_to_simulator", loginServer.XmlRpcLoginMethod );
|
||||
httpServer.AddXmlRPCHandler("login_to_simulator", communicationsManager.UserServices.XmlRpcLoginMethod );
|
||||
httpServer.Start();
|
||||
|
||||
m_log.WriteLine( LogPriority.NORMAL, "Press enter to quit.");
|
||||
|
||||
Reference in New Issue
Block a user