From 8edcc844c443a8d2567d2ca1e468fa3324272b98 Mon Sep 17 00:00:00 2001 From: lbsa71 Date: Wed, 20 Jun 2007 11:41:45 +0000 Subject: * re-added SimpleApp projects * made them work (yay!) * some cleanup --- OpenSim/Examples/SimpleApp/Program.cs | 21 +++++++-- OpenSim/Examples/SimpleApp/SimpleApp.csproj | 6 ++- OpenSim/Examples/SimpleApp/SimpleApp.exe.build | 1 + OpenSim/Examples/SimpleApp2/Program.cs | 21 ++++++++- OpenSim/Examples/SimpleApp2/SimpleApp2.csproj | 53 +++++++++++++--------- OpenSim/Examples/SimpleApp2/SimpleApp2.exe.build | 1 + .../OpenSim.LocalCommunications.csproj.user | 12 ----- 7 files changed, 76 insertions(+), 39 deletions(-) delete mode 100644 OpenSim/OpenSim.LocalCommunications/OpenSim.LocalCommunications.csproj.user (limited to 'OpenSim') diff --git a/OpenSim/Examples/SimpleApp/Program.cs b/OpenSim/Examples/SimpleApp/Program.cs index ed1f063..1d0702d 100644 --- a/OpenSim/Examples/SimpleApp/Program.cs +++ b/OpenSim/Examples/SimpleApp/Program.cs @@ -18,6 +18,7 @@ namespace SimpleApp class Program : IAssetReceiver, conscmd_callback { private ConsoleBase m_console; + AuthenticateSessionsBase m_circuitManager; private void Run() { @@ -34,7 +35,7 @@ namespace SimpleApp loginServer.Startup(); loginServer.SetSessionHandler( AddNewSessionHandler ); - AuthenticateSessionsBase localSessions = new AuthenticateSessionsBase(); + m_circuitManager = new AuthenticateSessionsBase(); InventoryCache inventoryCache = new InventoryCache(); @@ -44,7 +45,7 @@ namespace SimpleApp AssetCache assetCache = new AssetCache(assetServer); - UDPServer udpServer = new UDPServer(simPort, assetCache, inventoryCache, m_console, localSessions ); + UDPServer udpServer = new UDPServer(simPort, assetCache, inventoryCache, m_console, m_circuitManager ); PacketServer packetServer = new PacketServer( udpServer, (uint) simPort ); udpServer.ServerListener(); @@ -69,7 +70,21 @@ namespace SimpleApp private bool AddNewSessionHandler(ulong regionHandle, Login loginData) { - m_console.WriteLine( LogPriority.NORMAL, "Region [{0}] recieved Login from [{1}] [{2}]", regionHandle, loginData.First, loginData.Last ); + m_console.WriteLine(LogPriority.NORMAL, "Region [{0}] recieved Login from [{1}] [{2}]", regionHandle, loginData.First, loginData.Last); + + AgentCircuitData agent = new AgentCircuitData(); + agent.AgentID = loginData.Agent; + agent.firstname = loginData.First; + agent.lastname = loginData.Last; + agent.SessionID = loginData.Session; + agent.SecureSessionID = loginData.SecureSession; + agent.circuitcode = loginData.CircuitCode; + agent.BaseFolder = loginData.BaseFolder; + agent.InventoryFolder = loginData.InventoryFolder; + agent.startpos = new LLVector3(128, 128, 70); + + m_circuitManager.AddNewCircuit(agent.circuitcode, agent); + return true; } diff --git a/OpenSim/Examples/SimpleApp/SimpleApp.csproj b/OpenSim/Examples/SimpleApp/SimpleApp.csproj index eddb29e..810ecd4 100644 --- a/OpenSim/Examples/SimpleApp/SimpleApp.csproj +++ b/OpenSim/Examples/SimpleApp/SimpleApp.csproj @@ -50,7 +50,7 @@ False 4096 True - bin\ + ..\..\..\bin\ False False False @@ -62,6 +62,10 @@ ..\..\..\bin\libsecondlife.dll False + + OpenSim.World.dll + False + System.dll False diff --git a/OpenSim/Examples/SimpleApp/SimpleApp.exe.build b/OpenSim/Examples/SimpleApp/SimpleApp.exe.build index 922c557..b024219 100644 --- a/OpenSim/Examples/SimpleApp/SimpleApp.exe.build +++ b/OpenSim/Examples/SimpleApp/SimpleApp.exe.build @@ -27,6 +27,7 @@ + diff --git a/OpenSim/Examples/SimpleApp2/Program.cs b/OpenSim/Examples/SimpleApp2/Program.cs index 88b7b17..85ce703 100644 --- a/OpenSim/Examples/SimpleApp2/Program.cs +++ b/OpenSim/Examples/SimpleApp2/Program.cs @@ -20,6 +20,7 @@ namespace SimpleApp2 private ConsoleBase m_console; private RegionInfo m_regionInfo; private float[] m_map; + private AuthenticateSessionsBase m_circuitManager; private void Run() { @@ -34,10 +35,11 @@ namespace SimpleApp2 string simAddr = "127.0.0.1"; int simPort = 9000; + m_circuitManager = new AuthenticateSessionsBase(); + LoginServer loginServer = new LoginServer(simAddr, simPort, 0, 0, false); loginServer.Startup(); - AuthenticateSessionsBase localSessions = new AuthenticateSessionsBase(); loginServer.SetSessionHandler( AddNewSessionHandler ); InventoryCache inventoryCache = new InventoryCache(); @@ -48,7 +50,7 @@ namespace SimpleApp2 AssetCache assetCache = new AssetCache(assetServer); - UDPServer udpServer = new UDPServer(simPort, assetCache, inventoryCache, m_console, localSessions); + UDPServer udpServer = new UDPServer(simPort, assetCache, inventoryCache, m_console, m_circuitManager ); PacketServer packetServer = new MyPacketServer(m_map, udpServer, (uint) simPort ); udpServer.ServerListener(); @@ -89,6 +91,20 @@ namespace SimpleApp2 private bool AddNewSessionHandler(ulong regionHandle, Login loginData) { m_console.WriteLine(LogPriority.NORMAL, "Region [{0}] recieved Login from [{1}] [{2}]", regionHandle, loginData.First, loginData.Last); + + AgentCircuitData agent = new AgentCircuitData(); + agent.AgentID = loginData.Agent; + agent.firstname = loginData.First; + agent.lastname = loginData.Last; + agent.SessionID = loginData.Session; + agent.SecureSessionID = loginData.SecureSession; + agent.circuitcode = loginData.CircuitCode; + agent.BaseFolder = loginData.BaseFolder; + agent.InventoryFolder = loginData.InventoryFolder; + agent.startpos = new LLVector3(128, 128, 70); + + m_circuitManager.AddNewCircuit(agent.circuitcode, agent); + return true; } @@ -99,6 +115,7 @@ namespace SimpleApp2 app.Run(); } + #region IWorld Members void IWorld.AddNewAvatar(IClientAPI remoteClient, LLUUID agentID, bool child) diff --git a/OpenSim/Examples/SimpleApp2/SimpleApp2.csproj b/OpenSim/Examples/SimpleApp2/SimpleApp2.csproj index 404cb55..5c6e192 100644 --- a/OpenSim/Examples/SimpleApp2/SimpleApp2.csproj +++ b/OpenSim/Examples/SimpleApp2/SimpleApp2.csproj @@ -1,4 +1,4 @@ - + Local 8.0.50727 @@ -6,7 +6,8 @@ {24DF2448-0000-0000-0000-000000000000} Debug AnyCPU - + + SimpleApp2 @@ -15,9 +16,11 @@ IE50 false Exe - + + SimpleApp2 - + + @@ -28,7 +31,8 @@ TRACE;DEBUG - + + True 4096 False @@ -37,7 +41,8 @@ False False 4 - + + False @@ -46,31 +51,37 @@ TRACE - + + False 4096 True - bin\ + ..\..\..\bin\ False False False 4 - + + - + ..\..\..\bin\libsecondlife.dll False - + + OpenSim.World.dll + False + + System.dll False - + ..\..\..\bin\System.Data.dll False - + System.Xml.dll False @@ -80,43 +91,43 @@ OpenSim.Caches {1938EB12-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False OpenSim.Framework {8ACA2445-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False OpenSim.Framework.Console {A7CD0630-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False OpenSim.GridInterfaces.Local {546099CD-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False OpenSim.RegionServer {632E1BFD-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False OpenSim.Servers {8BB20F0A-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False XMLRPC {8E81D43C-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False @@ -140,4 +151,4 @@ - + \ No newline at end of file diff --git a/OpenSim/Examples/SimpleApp2/SimpleApp2.exe.build b/OpenSim/Examples/SimpleApp2/SimpleApp2.exe.build index 8116f04..dc5cc2a 100644 --- a/OpenSim/Examples/SimpleApp2/SimpleApp2.exe.build +++ b/OpenSim/Examples/SimpleApp2/SimpleApp2.exe.build @@ -28,6 +28,7 @@ + diff --git a/OpenSim/OpenSim.LocalCommunications/OpenSim.LocalCommunications.csproj.user b/OpenSim/OpenSim.LocalCommunications/OpenSim.LocalCommunications.csproj.user deleted file mode 100644 index 5941547..0000000 --- a/OpenSim/OpenSim.LocalCommunications/OpenSim.LocalCommunications.csproj.user +++ /dev/null @@ -1,12 +0,0 @@ - - - Debug - AnyCPU - C:\New Folder\second-life-viewer\opensim-dailys2\opensim15-06\Sugilite\bin\ - 8.0.50727 - ProjectFiles - 0 - - - - -- cgit v1.1