Merge branch 'presence-refactor' of ssh://diva@opensimulator.org/var/git/opensim into presence-refactor
commit
de91a9e09b
|
@ -128,6 +128,7 @@ what it is today.
|
||||||
* YZh
|
* YZh
|
||||||
* Zackary Geers aka Kunnis Basiat
|
* Zackary Geers aka Kunnis Basiat
|
||||||
* Zha Ewry
|
* Zha Ewry
|
||||||
|
* ziah
|
||||||
|
|
||||||
|
|
||||||
= LSL Devs =
|
= LSL Devs =
|
||||||
|
|
|
@ -524,7 +524,7 @@ namespace OpenSim.Data.Tests
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
[Test]
|
//[Test]
|
||||||
public void T016_RandomSogWithSceneParts()
|
public void T016_RandomSogWithSceneParts()
|
||||||
{
|
{
|
||||||
PropertyScrambler<SceneObjectPart> scrambler =
|
PropertyScrambler<SceneObjectPart> scrambler =
|
||||||
|
|
|
@ -302,9 +302,9 @@ namespace OpenSim.Framework.Console
|
||||||
if (!UUID.TryParse(post["ID"].ToString(), out id))
|
if (!UUID.TryParse(post["ID"].ToString(), out id))
|
||||||
return reply;
|
return reply;
|
||||||
|
|
||||||
lock(m_Connections)
|
lock (m_Connections)
|
||||||
{
|
{
|
||||||
if(!m_Connections.ContainsKey(id))
|
if (!m_Connections.ContainsKey(id))
|
||||||
return reply;
|
return reply;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -483,7 +483,6 @@ namespace OpenSim.Framework
|
||||||
else
|
else
|
||||||
m_externalHostName = externalName;
|
m_externalHostName = externalName;
|
||||||
|
|
||||||
|
|
||||||
m_regionType = config.GetString("RegionType", String.Empty);
|
m_regionType = config.GetString("RegionType", String.Empty);
|
||||||
|
|
||||||
// Prim stuff
|
// Prim stuff
|
||||||
|
|
|
@ -589,11 +589,17 @@ namespace OpenSim.Framework
|
||||||
|
|
||||||
public static IPAddress GetLocalHost()
|
public static IPAddress GetLocalHost()
|
||||||
{
|
{
|
||||||
string dnsAddress = "localhost";
|
IPAddress[] iplist = GetLocalHosts();
|
||||||
|
|
||||||
IPAddress[] hosts = Dns.GetHostEntry(dnsAddress).AddressList;
|
if (iplist.Length == 0) // No accessible external interfaces
|
||||||
|
{
|
||||||
|
IPAddress[] loopback = Dns.GetHostAddresses("localhost");
|
||||||
|
IPAddress localhost = loopback[0];
|
||||||
|
|
||||||
foreach (IPAddress host in hosts)
|
return localhost;
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach (IPAddress host in iplist)
|
||||||
{
|
{
|
||||||
if (!IPAddress.IsLoopback(host) && host.AddressFamily == AddressFamily.InterNetwork)
|
if (!IPAddress.IsLoopback(host) && host.AddressFamily == AddressFamily.InterNetwork)
|
||||||
{
|
{
|
||||||
|
@ -601,15 +607,15 @@ namespace OpenSim.Framework
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (hosts.Length > 0)
|
if (iplist.Length > 0)
|
||||||
{
|
{
|
||||||
foreach (IPAddress host in hosts)
|
foreach (IPAddress host in iplist)
|
||||||
{
|
{
|
||||||
if (host.AddressFamily == AddressFamily.InterNetwork)
|
if (host.AddressFamily == AddressFamily.InterNetwork)
|
||||||
return host;
|
return host;
|
||||||
}
|
}
|
||||||
// Well all else failed...
|
// Well all else failed...
|
||||||
return hosts[0];
|
return iplist[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
|
|
|
@ -194,6 +194,8 @@ namespace OpenSim
|
||||||
|
|
||||||
PrintFileToConsole("startuplogo.txt");
|
PrintFileToConsole("startuplogo.txt");
|
||||||
|
|
||||||
|
m_log.InfoFormat("[NETWORK]: Using {0} as SYSTEMIP", Util.GetLocalHost().ToString());
|
||||||
|
|
||||||
// For now, start at the 'root' level by default
|
// For now, start at the 'root' level by default
|
||||||
if (m_sceneManager.Scenes.Count == 1) // If there is only one region, select it
|
if (m_sceneManager.Scenes.Count == 1) // If there is only one region, select it
|
||||||
ChangeSelectedRegion("region",
|
ChangeSelectedRegion("region",
|
||||||
|
@ -624,7 +626,6 @@ namespace OpenSim
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Load, Unload, and list Region modules in use
|
/// Load, Unload, and list Region modules in use
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -924,7 +925,6 @@ namespace OpenSim
|
||||||
scene.RegionInfo.RegionLocX,
|
scene.RegionInfo.RegionLocX,
|
||||||
scene.RegionInfo.RegionLocY,
|
scene.RegionInfo.RegionLocY,
|
||||||
scene.RegionInfo.InternalEndPoint.Port));
|
scene.RegionInfo.InternalEndPoint.Port));
|
||||||
|
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -69,7 +69,7 @@ namespace Flotsam.RegionModules.AssetCache
|
||||||
|
|
||||||
private readonly List<char> m_InvalidChars = new List<char>();
|
private readonly List<char> m_InvalidChars = new List<char>();
|
||||||
|
|
||||||
private int m_LogLevel = 1;
|
private int m_LogLevel = 0;
|
||||||
private ulong m_HitRateDisplay = 1; // How often to display hit statistics, given in requests
|
private ulong m_HitRateDisplay = 1; // How often to display hit statistics, given in requests
|
||||||
|
|
||||||
private static ulong m_Requests;
|
private static ulong m_Requests;
|
||||||
|
@ -156,7 +156,7 @@ namespace Flotsam.RegionModules.AssetCache
|
||||||
m_WaitOnInprogressTimeout = assetConfig.GetInt("WaitOnInprogressTimeout", 3000);
|
m_WaitOnInprogressTimeout = assetConfig.GetInt("WaitOnInprogressTimeout", 3000);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
m_LogLevel = assetConfig.GetInt("LogLevel", 1);
|
m_LogLevel = assetConfig.GetInt("LogLevel", 0);
|
||||||
m_HitRateDisplay = (ulong)assetConfig.GetInt("HitRateDisplay", 1000);
|
m_HitRateDisplay = (ulong)assetConfig.GetInt("HitRateDisplay", 1000);
|
||||||
|
|
||||||
m_FileExpiration = TimeSpan.FromHours(assetConfig.GetDouble("FileCacheTimeout", m_DefaultFileExpiration));
|
m_FileExpiration = TimeSpan.FromHours(assetConfig.GetDouble("FileCacheTimeout", m_DefaultFileExpiration));
|
||||||
|
|
|
@ -159,7 +159,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Combat.CombatModule
|
||||||
avatar.Invulnerable = true;
|
avatar.Invulnerable = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -131,7 +131,20 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
{
|
{
|
||||||
if (CheckPresence(userInfo.PrincipalID))
|
if (CheckPresence(userInfo.PrincipalID))
|
||||||
{
|
{
|
||||||
new InventoryArchiveWriteRequest(id, this, m_aScene, userInfo, invPath, saveStream).Execute();
|
try
|
||||||
|
{
|
||||||
|
new InventoryArchiveWriteRequest(id, this, m_aScene, userInfo, invPath, saveStream).Execute();
|
||||||
|
}
|
||||||
|
catch (EntryPointNotFoundException e)
|
||||||
|
{
|
||||||
|
m_log.ErrorFormat(
|
||||||
|
"[ARCHIVER]: Mismatch between Mono and zlib1g library version when trying to create compression stream."
|
||||||
|
+ "If you've manually installed Mono, have you appropriately updated zlib1g as well?");
|
||||||
|
m_log.Error(e);
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -156,7 +169,20 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
{
|
{
|
||||||
if (CheckPresence(userInfo.PrincipalID))
|
if (CheckPresence(userInfo.PrincipalID))
|
||||||
{
|
{
|
||||||
new InventoryArchiveWriteRequest(id, this, m_aScene, userInfo, invPath, savePath).Execute();
|
try
|
||||||
|
{
|
||||||
|
new InventoryArchiveWriteRequest(id, this, m_aScene, userInfo, invPath, savePath).Execute();
|
||||||
|
}
|
||||||
|
catch (EntryPointNotFoundException e)
|
||||||
|
{
|
||||||
|
m_log.ErrorFormat(
|
||||||
|
"[ARCHIVER]: Mismatch between Mono and zlib1g library version when trying to create compression stream."
|
||||||
|
+ "If you've manually installed Mono, have you appropriately updated zlib1g as well?");
|
||||||
|
m_log.Error(e);
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -181,8 +207,22 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
{
|
{
|
||||||
if (CheckPresence(userInfo.PrincipalID))
|
if (CheckPresence(userInfo.PrincipalID))
|
||||||
{
|
{
|
||||||
InventoryArchiveReadRequest request =
|
InventoryArchiveReadRequest request;
|
||||||
new InventoryArchiveReadRequest(m_aScene, userInfo, invPath, loadStream);
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
request = new InventoryArchiveReadRequest(m_aScene, userInfo, invPath, loadStream);
|
||||||
|
}
|
||||||
|
catch (EntryPointNotFoundException e)
|
||||||
|
{
|
||||||
|
m_log.ErrorFormat(
|
||||||
|
"[ARCHIVER]: Mismatch between Mono and zlib1g library version when trying to create compression stream."
|
||||||
|
+ "If you've manually installed Mono, have you appropriately updated zlib1g as well?");
|
||||||
|
m_log.Error(e);
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
UpdateClientWithLoadedNodes(userInfo, request.Execute());
|
UpdateClientWithLoadedNodes(userInfo, request.Execute());
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -209,8 +249,22 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
|
||||||
{
|
{
|
||||||
if (CheckPresence(userInfo.PrincipalID))
|
if (CheckPresence(userInfo.PrincipalID))
|
||||||
{
|
{
|
||||||
InventoryArchiveReadRequest request =
|
InventoryArchiveReadRequest request;
|
||||||
new InventoryArchiveReadRequest(m_aScene, userInfo, invPath, loadPath);
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
request = new InventoryArchiveReadRequest(m_aScene, userInfo, invPath, loadPath);
|
||||||
|
}
|
||||||
|
catch (EntryPointNotFoundException e)
|
||||||
|
{
|
||||||
|
m_log.ErrorFormat(
|
||||||
|
"[ARCHIVER]: Mismatch between Mono and zlib1g library version when trying to create compression stream."
|
||||||
|
+ "If you've manually installed Mono, have you appropriately updated zlib1g as well?");
|
||||||
|
m_log.Error(e);
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
UpdateClientWithLoadedNodes(userInfo, request.Execute());
|
UpdateClientWithLoadedNodes(userInfo, request.Execute());
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -108,7 +108,7 @@ namespace OpenSim.Region.CoreModules.World
|
||||||
{
|
{
|
||||||
foreach (Scene s in m_SceneList)
|
foreach (Scene s in m_SceneList)
|
||||||
{
|
{
|
||||||
if(!ProcessCommand(s, cmd))
|
if (!ProcessCommand(s, cmd))
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,7 +74,19 @@ namespace OpenSim.Region.CoreModules.World.Archiver
|
||||||
public ArchiveReadRequest(Scene scene, string loadPath, bool merge, Guid requestId)
|
public ArchiveReadRequest(Scene scene, string loadPath, bool merge, Guid requestId)
|
||||||
{
|
{
|
||||||
m_scene = scene;
|
m_scene = scene;
|
||||||
m_loadStream = new GZipStream(GetStream(loadPath), CompressionMode.Decompress);
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
m_loadStream = new GZipStream(GetStream(loadPath), CompressionMode.Decompress);
|
||||||
|
}
|
||||||
|
catch (EntryPointNotFoundException e)
|
||||||
|
{
|
||||||
|
m_log.ErrorFormat(
|
||||||
|
"[ARCHIVER]: Mismatch between Mono and zlib1g library version when trying to create compression stream."
|
||||||
|
+ "If you've manually installed Mono, have you appropriately updated zlib1g as well?");
|
||||||
|
m_log.Error(e);
|
||||||
|
}
|
||||||
|
|
||||||
m_errorMessage = String.Empty;
|
m_errorMessage = String.Empty;
|
||||||
m_merge = merge;
|
m_merge = merge;
|
||||||
m_requestId = requestId;
|
m_requestId = requestId;
|
||||||
|
|
|
@ -65,7 +65,19 @@ namespace OpenSim.Region.CoreModules.World.Archiver
|
||||||
public ArchiveWriteRequestPreparation(Scene scene, string savePath, Guid requestId)
|
public ArchiveWriteRequestPreparation(Scene scene, string savePath, Guid requestId)
|
||||||
{
|
{
|
||||||
m_scene = scene;
|
m_scene = scene;
|
||||||
m_saveStream = new GZipStream(new FileStream(savePath, FileMode.Create), CompressionMode.Compress);
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
m_saveStream = new GZipStream(new FileStream(savePath, FileMode.Create), CompressionMode.Compress);
|
||||||
|
}
|
||||||
|
catch (EntryPointNotFoundException e)
|
||||||
|
{
|
||||||
|
m_log.ErrorFormat(
|
||||||
|
"[ARCHIVER]: Mismatch between Mono and zlib1g library version when trying to create compression stream."
|
||||||
|
+ "If you've manually installed Mono, have you appropriately updated zlib1g as well?");
|
||||||
|
m_log.Error(e);
|
||||||
|
}
|
||||||
|
|
||||||
m_requestId = requestId;
|
m_requestId = requestId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -262,7 +262,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
/// Returns a new unallocated local ID
|
/// Returns a new unallocated local ID
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns>A brand new local ID</returns>
|
/// <returns>A brand new local ID</returns>
|
||||||
protected internal uint AllocateLocalId()
|
public uint AllocateLocalId()
|
||||||
{
|
{
|
||||||
uint myID;
|
uint myID;
|
||||||
|
|
||||||
|
|
|
@ -546,7 +546,7 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
if (m_rootPart.Shape.PCode != 9 || m_rootPart.Shape.State == 0)
|
if (m_rootPart.Shape.PCode != 9 || m_rootPart.Shape.State == 0)
|
||||||
m_rootPart.ParentID = 0;
|
m_rootPart.ParentID = 0;
|
||||||
if (m_rootPart.LocalId==0)
|
if (m_rootPart.LocalId == 0)
|
||||||
m_rootPart.LocalId = m_scene.AllocateLocalId();
|
m_rootPart.LocalId = m_scene.AllocateLocalId();
|
||||||
|
|
||||||
// No need to lock here since the object isn't yet in a scene
|
// No need to lock here since the object isn't yet in a scene
|
||||||
|
@ -1505,6 +1505,9 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
/// <param name="part"></param>
|
/// <param name="part"></param>
|
||||||
internal void SendPartFullUpdate(IClientAPI remoteClient, SceneObjectPart part, uint clientFlags)
|
internal void SendPartFullUpdate(IClientAPI remoteClient, SceneObjectPart part, uint clientFlags)
|
||||||
{
|
{
|
||||||
|
// m_log.DebugFormat(
|
||||||
|
// "[SOG]: Sendinging part full update to {0} for {1} {2}", remoteClient.Name, part.Name, part.LocalId);
|
||||||
|
|
||||||
if (m_rootPart.UUID == part.UUID)
|
if (m_rootPart.UUID == part.UUID)
|
||||||
{
|
{
|
||||||
if (IsAttachment)
|
if (IsAttachment)
|
||||||
|
@ -2297,7 +2300,6 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
AttachToBackup();
|
AttachToBackup();
|
||||||
|
|
||||||
|
|
||||||
// Here's the deal, this is ABSOLUTELY CRITICAL so the physics scene gets the update about the
|
// Here's the deal, this is ABSOLUTELY CRITICAL so the physics scene gets the update about the
|
||||||
// position of linkset prims. IF YOU CHANGE THIS, YOU MUST TEST colliding with just linked and
|
// position of linkset prims. IF YOU CHANGE THIS, YOU MUST TEST colliding with just linked and
|
||||||
// unmoved prims!
|
// unmoved prims!
|
||||||
|
@ -2312,9 +2314,10 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
/// an independent SceneObjectGroup.
|
/// an independent SceneObjectGroup.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="partID"></param>
|
/// <param name="partID"></param>
|
||||||
public void DelinkFromGroup(uint partID)
|
/// <returns>The object group of the newly delinked prim. Null if part could not be found</returns>
|
||||||
|
public SceneObjectGroup DelinkFromGroup(uint partID)
|
||||||
{
|
{
|
||||||
DelinkFromGroup(partID, true);
|
return DelinkFromGroup(partID, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -2323,29 +2326,40 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="partID"></param>
|
/// <param name="partID"></param>
|
||||||
/// <param name="sendEvents"></param>
|
/// <param name="sendEvents"></param>
|
||||||
public void DelinkFromGroup(uint partID, bool sendEvents)
|
/// <returns>The object group of the newly delinked prim. Null if part could not be found</returns>
|
||||||
|
public SceneObjectGroup DelinkFromGroup(uint partID, bool sendEvents)
|
||||||
{
|
{
|
||||||
SceneObjectPart linkPart = GetChildPart(partID);
|
SceneObjectPart linkPart = GetChildPart(partID);
|
||||||
|
|
||||||
if (linkPart != null)
|
if (linkPart != null)
|
||||||
{
|
{
|
||||||
DelinkFromGroup(linkPart, sendEvents);
|
return DelinkFromGroup(linkPart, sendEvents);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
m_log.InfoFormat("[SCENE OBJECT GROUP]: " +
|
m_log.WarnFormat("[SCENE OBJECT GROUP]: " +
|
||||||
"DelinkFromGroup(): Child prim {0} not found in object {1}, {2}",
|
"DelinkFromGroup(): Child prim {0} not found in object {1}, {2}",
|
||||||
partID, LocalId, UUID);
|
partID, LocalId, UUID);
|
||||||
|
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void DelinkFromGroup(SceneObjectPart linkPart, bool sendEvents)
|
/// <summary>
|
||||||
|
/// Delink the given prim from this group. The delinked prim is established as
|
||||||
|
/// an independent SceneObjectGroup.
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="partID"></param>
|
||||||
|
/// <param name="sendEvents"></param>
|
||||||
|
/// <returns>The object group of the newly delinked prim.</returns>
|
||||||
|
public SceneObjectGroup DelinkFromGroup(SceneObjectPart linkPart, bool sendEvents)
|
||||||
{
|
{
|
||||||
linkPart.ClearUndoState();
|
|
||||||
// m_log.DebugFormat(
|
// m_log.DebugFormat(
|
||||||
// "[SCENE OBJECT GROUP]: Delinking part {0}, {1} from group with root part {2}, {3}",
|
// "[SCENE OBJECT GROUP]: Delinking part {0}, {1} from group with root part {2}, {3}",
|
||||||
// linkPart.Name, linkPart.UUID, RootPart.Name, RootPart.UUID);
|
// linkPart.Name, linkPart.UUID, RootPart.Name, RootPart.UUID);
|
||||||
|
|
||||||
|
linkPart.ClearUndoState();
|
||||||
|
|
||||||
Quaternion worldRot = linkPart.GetWorldRotation();
|
Quaternion worldRot = linkPart.GetWorldRotation();
|
||||||
|
|
||||||
// Remove the part from this object
|
// Remove the part from this object
|
||||||
|
@ -2397,6 +2411,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
//HasGroupChanged = true;
|
//HasGroupChanged = true;
|
||||||
//ScheduleGroupForFullUpdate();
|
//ScheduleGroupForFullUpdate();
|
||||||
|
|
||||||
|
return objectGroup;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -2435,7 +2451,6 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
part.LinkNum = linkNum;
|
part.LinkNum = linkNum;
|
||||||
|
|
||||||
|
|
||||||
part.OffsetPosition = part.GroupPosition - AbsolutePosition;
|
part.OffsetPosition = part.GroupPosition - AbsolutePosition;
|
||||||
|
|
||||||
Quaternion rootRotation = m_rootPart.RotationOffset;
|
Quaternion rootRotation = m_rootPart.RotationOffset;
|
||||||
|
|
|
@ -1241,14 +1241,6 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (m_pos.X < 0)
|
|
||||||
m_pos.X = 128;
|
|
||||||
if (m_pos.Y < 0)
|
|
||||||
m_pos.Y = 128;
|
|
||||||
if (m_pos.X > Scene.WestBorders[0].BorderLine.X)
|
|
||||||
m_pos.X = 128;
|
|
||||||
if (m_pos.Y > Scene.NorthBorders[0].BorderLine.Y)
|
|
||||||
m_pos.Y = 128;
|
|
||||||
m_LastFinitePos = m_pos;
|
m_LastFinitePos = m_pos;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2818,16 +2810,19 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
{
|
{
|
||||||
if (!needsTransit)
|
if (!needsTransit)
|
||||||
{
|
{
|
||||||
Vector3 pos = AbsolutePosition;
|
if (m_requestedSitTargetUUID == UUID.Zero)
|
||||||
if (AbsolutePosition.X < 0)
|
{
|
||||||
pos.X += Velocity.Y;
|
Vector3 pos = AbsolutePosition;
|
||||||
else if (AbsolutePosition.X > Constants.RegionSize)
|
if (AbsolutePosition.X < 0)
|
||||||
pos.X -= Velocity.Y;
|
pos.X += Velocity.X;
|
||||||
if (AbsolutePosition.Y < 0)
|
else if (AbsolutePosition.X > Constants.RegionSize)
|
||||||
pos.Y += Velocity.Y;
|
pos.X -= Velocity.X;
|
||||||
else if (AbsolutePosition.Y > Constants.RegionSize)
|
if (AbsolutePosition.Y < 0)
|
||||||
pos.Y -= Velocity.Y;
|
pos.Y += Velocity.Y;
|
||||||
AbsolutePosition = pos;
|
else if (AbsolutePosition.Y > Constants.RegionSize)
|
||||||
|
pos.Y -= Velocity.Y;
|
||||||
|
AbsolutePosition = pos;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (neighbor > 0)
|
else if (neighbor > 0)
|
||||||
|
|
|
@ -50,7 +50,6 @@ using OpenSim.Region.Framework.Scenes;
|
||||||
using Caps = OpenSim.Framework.Capabilities.Caps;
|
using Caps = OpenSim.Framework.Capabilities.Caps;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
|
|
||||||
|
|
||||||
namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
{
|
{
|
||||||
public class FreeSwitchVoiceModule : IRegionModule, IVoiceModule
|
public class FreeSwitchVoiceModule : IRegionModule, IVoiceModule
|
||||||
|
@ -203,10 +202,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
FreeSwitchSLVoiceBuddyHTTPHandler);
|
FreeSwitchSLVoiceBuddyHTTPHandler);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
m_log.InfoFormat("[FreeSwitchVoice] using FreeSwitch server {0}", m_freeSwitchRealm);
|
m_log.InfoFormat("[FreeSwitchVoice] using FreeSwitch server {0}", m_freeSwitchRealm);
|
||||||
|
|
||||||
m_FreeSwitchDirectory = new FreeSwitchDirectory();
|
m_FreeSwitchDirectory = new FreeSwitchDirectory();
|
||||||
|
@ -234,8 +229,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
OnRegisterCaps(scene, agentID, caps);
|
OnRegisterCaps(scene, agentID, caps);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
ServicePointManager.ServerCertificateValidationCallback += CustomCertificateValidation;
|
ServicePointManager.ServerCertificateValidationCallback += CustomCertificateValidation;
|
||||||
|
@ -254,7 +247,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
m_log.Error("[FreeSwitchVoice]: Certificate validation handler change not supported. You may get ssl certificate validation errors teleporting from your region to some SSL regions.");
|
m_log.Error("[FreeSwitchVoice]: Certificate validation handler change not supported. You may get ssl certificate validation errors teleporting from your region to some SSL regions.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -455,8 +447,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
throw new Exception(String.Format("region \"{0}\": avatar \"{1}\": land data not yet available",
|
throw new Exception(String.Format("region \"{0}\": avatar \"{1}\": land data not yet available",
|
||||||
scene.RegionInfo.RegionName, avatarName));
|
scene.RegionInfo.RegionName, avatarName));
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// get channel_uri: check first whether estate
|
// get channel_uri: check first whether estate
|
||||||
// settings allow voice, then whether parcel allows
|
// settings allow voice, then whether parcel allows
|
||||||
// voice, if all do retrieve or obtain the parcel
|
// voice, if all do retrieve or obtain the parcel
|
||||||
|
@ -508,7 +498,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Callback for a client request for ChatSessionRequest
|
/// Callback for a client request for ChatSessionRequest
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -551,7 +540,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
int fwdresponsecode = 200;
|
int fwdresponsecode = 200;
|
||||||
string fwdresponsecontenttype = "text/xml";
|
string fwdresponsecontenttype = "text/xml";
|
||||||
|
|
||||||
|
|
||||||
HttpWebRequest forwardreq = (HttpWebRequest)WebRequest.Create(forwardaddress);
|
HttpWebRequest forwardreq = (HttpWebRequest)WebRequest.Create(forwardaddress);
|
||||||
forwardreq.Method = method;
|
forwardreq.Method = method;
|
||||||
forwardreq.ContentType = contenttype;
|
forwardreq.ContentType = contenttype;
|
||||||
|
@ -712,7 +700,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
pos++;
|
pos++;
|
||||||
if (s == userid)
|
if (s == userid)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -786,8 +773,8 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
// split string
|
// split string
|
||||||
string [] nvps = body.Split(new Char [] {'&'});
|
string [] nvps = body.Split(new Char [] {'&'});
|
||||||
|
|
||||||
foreach (string s in nvps) {
|
foreach (string s in nvps)
|
||||||
|
{
|
||||||
if (s.Trim() != "")
|
if (s.Trim() != "")
|
||||||
{
|
{
|
||||||
string [] nvp = s.Split(new Char [] {'='});
|
string [] nvp = s.Split(new Char [] {'='});
|
||||||
|
@ -800,7 +787,6 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
|
|
||||||
private string ChannelUri(Scene scene, LandData land)
|
private string ChannelUri(Scene scene, LandData land)
|
||||||
{
|
{
|
||||||
|
|
||||||
string channelUri = null;
|
string channelUri = null;
|
||||||
|
|
||||||
string landUUID;
|
string landUUID;
|
||||||
|
@ -852,11 +838,10 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
|
||||||
|
|
||||||
private static bool CustomCertificateValidation(object sender, X509Certificate cert, X509Chain chain, SslPolicyErrors error)
|
private static bool CustomCertificateValidation(object sender, X509Certificate cert, X509Chain chain, SslPolicyErrors error)
|
||||||
{
|
{
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public class MonoCert : ICertificatePolicy
|
public class MonoCert : ICertificatePolicy
|
||||||
{
|
{
|
||||||
#region ICertificatePolicy Members
|
#region ICertificatePolicy Members
|
||||||
|
|
|
@ -34,6 +34,9 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
{
|
{
|
||||||
public interface IAvatar : IEntity
|
public interface IAvatar : IEntity
|
||||||
{
|
{
|
||||||
|
|
||||||
|
bool IsChildAgent { get; }
|
||||||
|
|
||||||
//// <value>
|
//// <value>
|
||||||
/// Array of worn attachments, empty but not null, if no attachments are worn
|
/// Array of worn attachments, empty but not null, if no attachments are worn
|
||||||
/// </value>
|
/// </value>
|
||||||
|
|
|
@ -70,6 +70,11 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule
|
||||||
set { GetSP().TeleportWithMomentum(value); }
|
set { GetSP().TeleportWithMomentum(value); }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool IsChildAgent
|
||||||
|
{
|
||||||
|
get { return GetSP().IsChildAgent; }
|
||||||
|
}
|
||||||
|
|
||||||
#region IAvatar implementation
|
#region IAvatar implementation
|
||||||
public IAvatarAttachment[] Attachments
|
public IAvatarAttachment[] Attachments
|
||||||
{
|
{
|
||||||
|
|
|
@ -72,23 +72,23 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
|
|
||||||
|
|
||||||
// Vehicle properties
|
// Vehicle properties
|
||||||
private Vehicle m_type = Vehicle.TYPE_NONE; // If a 'VEHICLE', and what kind
|
private Vehicle m_type = Vehicle.TYPE_NONE; // If a 'VEHICLE', and what kind
|
||||||
// private Quaternion m_referenceFrame = Quaternion.Identity; // Axis modifier
|
// private Quaternion m_referenceFrame = Quaternion.Identity; // Axis modifier
|
||||||
private VehicleFlag m_flags = (VehicleFlag) 0; // Boolean settings:
|
private VehicleFlag m_flags = (VehicleFlag) 0; // Boolean settings:
|
||||||
// HOVER_TERRAIN_ONLY
|
// HOVER_TERRAIN_ONLY
|
||||||
// HOVER_GLOBAL_HEIGHT
|
// HOVER_GLOBAL_HEIGHT
|
||||||
// NO_DEFLECTION_UP
|
// NO_DEFLECTION_UP
|
||||||
// HOVER_WATER_ONLY
|
// HOVER_WATER_ONLY
|
||||||
// HOVER_UP_ONLY
|
// HOVER_UP_ONLY
|
||||||
// LIMIT_MOTOR_UP
|
// LIMIT_MOTOR_UP
|
||||||
// LIMIT_ROLL_ONLY
|
// LIMIT_ROLL_ONLY
|
||||||
private VehicleFlag m_Hoverflags = (VehicleFlag)0;
|
private VehicleFlag m_Hoverflags = (VehicleFlag)0;
|
||||||
private Vector3 m_BlockingEndPoint = Vector3.Zero;
|
private Vector3 m_BlockingEndPoint = Vector3.Zero;
|
||||||
private Quaternion m_RollreferenceFrame = Quaternion.Identity;
|
private Quaternion m_RollreferenceFrame = Quaternion.Identity;
|
||||||
// Linear properties
|
// Linear properties
|
||||||
private Vector3 m_linearMotorDirection = Vector3.Zero; // velocity requested by LSL, decayed by time
|
private Vector3 m_linearMotorDirection = Vector3.Zero; // velocity requested by LSL, decayed by time
|
||||||
private Vector3 m_linearMotorDirectionLASTSET = Vector3.Zero; // velocity requested by LSL
|
private Vector3 m_linearMotorDirectionLASTSET = Vector3.Zero; // velocity requested by LSL
|
||||||
private Vector3 m_dir = Vector3.Zero; // velocity applied to body
|
private Vector3 m_dir = Vector3.Zero; // velocity applied to body
|
||||||
private Vector3 m_linearFrictionTimescale = Vector3.Zero;
|
private Vector3 m_linearFrictionTimescale = Vector3.Zero;
|
||||||
private float m_linearMotorDecayTimescale = 0;
|
private float m_linearMotorDecayTimescale = 0;
|
||||||
private float m_linearMotorTimescale = 0;
|
private float m_linearMotorTimescale = 0;
|
||||||
|
@ -98,14 +98,14 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
// private Vector3 m_linearMotorOffset = Vector3.Zero;
|
// private Vector3 m_linearMotorOffset = Vector3.Zero;
|
||||||
|
|
||||||
//Angular properties
|
//Angular properties
|
||||||
private Vector3 m_angularMotorDirection = Vector3.Zero; // angular velocity requested by LSL motor
|
private Vector3 m_angularMotorDirection = Vector3.Zero; // angular velocity requested by LSL motor
|
||||||
private int m_angularMotorApply = 0; // application frame counter
|
private int m_angularMotorApply = 0; // application frame counter
|
||||||
private Vector3 m_angularMotorVelocity = Vector3.Zero; // current angular motor velocity
|
private Vector3 m_angularMotorVelocity = Vector3.Zero; // current angular motor velocity
|
||||||
private float m_angularMotorTimescale = 0; // motor angular velocity ramp up rate
|
private float m_angularMotorTimescale = 0; // motor angular velocity ramp up rate
|
||||||
private float m_angularMotorDecayTimescale = 0; // motor angular velocity decay rate
|
private float m_angularMotorDecayTimescale = 0; // motor angular velocity decay rate
|
||||||
private Vector3 m_angularFrictionTimescale = Vector3.Zero; // body angular velocity decay rate
|
private Vector3 m_angularFrictionTimescale = Vector3.Zero; // body angular velocity decay rate
|
||||||
private Vector3 m_lastAngularVelocity = Vector3.Zero; // what was last applied to body
|
private Vector3 m_lastAngularVelocity = Vector3.Zero; // what was last applied to body
|
||||||
// private Vector3 m_lastVertAttractor = Vector3.Zero; // what VA was last applied to body
|
// private Vector3 m_lastVertAttractor = Vector3.Zero; // what VA was last applied to body
|
||||||
|
|
||||||
//Deflection properties
|
//Deflection properties
|
||||||
// private float m_angularDeflectionEfficiency = 0;
|
// private float m_angularDeflectionEfficiency = 0;
|
||||||
|
@ -123,14 +123,14 @@ namespace OpenSim.Region.Physics.OdePlugin
|
||||||
// private float m_VhoverEfficiency = 0f;
|
// private float m_VhoverEfficiency = 0f;
|
||||||
private float m_VhoverTimescale = 0f;
|
private float m_VhoverTimescale = 0f;
|
||||||
private float m_VhoverTargetHeight = -1.0f; // if <0 then no hover, else its the current target height
|
private float m_VhoverTargetHeight = -1.0f; // if <0 then no hover, else its the current target height
|
||||||
private float m_VehicleBuoyancy = 0f; //KF: m_VehicleBuoyancy is set by VEHICLE_BUOYANCY for a vehicle.
|
private float m_VehicleBuoyancy = 0f; //KF: m_VehicleBuoyancy is set by VEHICLE_BUOYANCY for a vehicle.
|
||||||
// Modifies gravity. Slider between -1 (double-gravity) and 1 (full anti-gravity)
|
// Modifies gravity. Slider between -1 (double-gravity) and 1 (full anti-gravity)
|
||||||
// KF: So far I have found no good method to combine a script-requested .Z velocity and gravity.
|
// KF: So far I have found no good method to combine a script-requested .Z velocity and gravity.
|
||||||
// Therefore only m_VehicleBuoyancy=1 (0g) will use the script-requested .Z velocity.
|
// Therefore only m_VehicleBuoyancy=1 (0g) will use the script-requested .Z velocity.
|
||||||
|
|
||||||
//Attractor properties
|
//Attractor properties
|
||||||
private float m_verticalAttractionEfficiency = 1.0f; // damped
|
private float m_verticalAttractionEfficiency = 1.0f; // damped
|
||||||
private float m_verticalAttractionTimescale = 500f; // Timescale > 300 means no vert attractor.
|
private float m_verticalAttractionTimescale = 500f; // Timescale > 300 means no vert attractor.
|
||||||
|
|
||||||
internal void ProcessFloatVehicleParam(Vehicle pParam, float pValue)
|
internal void ProcessFloatVehicleParam(Vehicle pParam, float pValue)
|
||||||
{
|
{
|
||||||
|
|
|
@ -8192,38 +8192,38 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
|
||||||
{
|
{
|
||||||
m_host.AddScriptLPS(1);
|
m_host.AddScriptLPS(1);
|
||||||
if (m_ScriptEngine.Config.GetBoolean("AllowGodFunctions", false))
|
if (m_ScriptEngine.Config.GetBoolean("AllowGodFunctions", false))
|
||||||
{
|
{
|
||||||
if (World.Permissions.CanRunConsoleCommand(m_host.OwnerID))
|
if (World.Permissions.CanRunConsoleCommand(m_host.OwnerID))
|
||||||
{
|
{
|
||||||
lock (m_host.TaskInventory)
|
lock (m_host.TaskInventory)
|
||||||
{
|
{
|
||||||
foreach (KeyValuePair<UUID, TaskInventoryItem> inv in m_host.TaskInventory)
|
foreach (KeyValuePair<UUID, TaskInventoryItem> inv in m_host.TaskInventory)
|
||||||
{
|
{
|
||||||
if (inv.Value.Name == item)
|
if (inv.Value.Name == item)
|
||||||
{
|
{
|
||||||
switch (mask)
|
switch (mask)
|
||||||
{
|
{
|
||||||
case 0:
|
case 0:
|
||||||
inv.Value.BasePermissions = (uint)value;
|
inv.Value.BasePermissions = (uint)value;
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
inv.Value.CurrentPermissions = (uint)value;
|
inv.Value.CurrentPermissions = (uint)value;
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
inv.Value.GroupPermissions = (uint)value;
|
inv.Value.GroupPermissions = (uint)value;
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
inv.Value.EveryonePermissions = (uint)value;
|
inv.Value.EveryonePermissions = (uint)value;
|
||||||
break;
|
break;
|
||||||
case 4:
|
case 4:
|
||||||
inv.Value.NextPermissions = (uint)value;
|
inv.Value.NextPermissions = (uint)value;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public LSL_String llGetInventoryCreator(string item)
|
public LSL_String llGetInventoryCreator(string item)
|
||||||
|
|
|
@ -207,7 +207,7 @@ namespace OpenSim.Server.Handlers.Asset
|
||||||
if (!request.ContainsKey("PRINCIPAL"))
|
if (!request.ContainsKey("PRINCIPAL"))
|
||||||
return FailureResult();
|
return FailureResult();
|
||||||
|
|
||||||
if(m_InventoryService.CreateUserInventory(new UUID(request["PRINCIPAL"].ToString())))
|
if (m_InventoryService.CreateUserInventory(new UUID(request["PRINCIPAL"].ToString())))
|
||||||
result["RESULT"] = "True";
|
result["RESULT"] = "True";
|
||||||
else
|
else
|
||||||
result["RESULT"] = "False";
|
result["RESULT"] = "False";
|
||||||
|
|
Loading…
Reference in New Issue