After hours of searching for a bug, it works - User accounts in sandbox mode, currently they are not persistent between restarts (ie restarting opensim.exe) but should be persistent between sessions (login/ logout).

Use the -account command line arg to enable them and then create new accounts through the web interface
This commit is contained in:
MW
2007-03-28 18:10:52 +00:00
parent c3ae2a721b
commit 35fa85069e
15 changed files with 216 additions and 33 deletions

View File

@@ -30,8 +30,8 @@ namespace OpenSim.UserServer
public override void CustomiseResponse(ref System.Collections.Hashtable response, UserProfile theUser)
{
uint circode = (uint)response["circuit_code"];
theUser.AddSimCircuit(circode, LLUUID.Random());
Int32 circode = (Int32)response["circuit_code"];
theUser.AddSimCircuit((uint)circode, LLUUID.Random());
response["home"] = "{'region_handle':[r" + (997 * 256).ToString() + ",r" + (996 * 256).ToString() + "], 'position':[r" + theUser.homepos.X.ToString() + ",r" + theUser.homepos.Y.ToString() + ",r" + theUser.homepos.Z.ToString() + "], 'look_at':[r" + theUser.homelookat.X.ToString() + ",r" + theUser.homelookat.Y.ToString() + ",r" + theUser.homelookat.Z.ToString() + "]}";
response["sim_port"] = m_port;
response["sim_ip"] = m_ipAddr;
@@ -40,18 +40,18 @@ namespace OpenSim.UserServer
string first;
string last;
if (response.Contains("first"))
if (response.Contains("first_name"))
{
first = (string)response["first"];
first = (string)response["first_name"];
}
else
{
first = "test";
}
if (response.Contains("last"))
if (response.Contains("last_name"))
{
last = (string)response["last"];
last = (string)response["last_name"];
}
else
{
@@ -67,12 +67,14 @@ namespace OpenSim.UserServer
_login.Last = last;
_login.Agent = new LLUUID((string)response["agent_id"]) ;
_login.Session = new LLUUID((string)response["session_id"]);
_login.SecureSession = new LLUUID((string)response["secure_session_id"]);
_login.BaseFolder = null;
_login.InventoryFolder = new LLUUID((string)Inventory1["folder_id"]);
//working on local computer if so lets add to the gridserver's list of sessions?
if (m_gridServer.GetName() == "Local")
{
Console.WriteLine("adding login data to gridserver");
((LocalGridBase)this.m_gridServer).AddNewSession(_login);
}
}