diff --git a/BUILDING.md b/BUILDING.md index 5210b58f1f..d8deeeb237 100644 --- a/BUILDING.md +++ b/BUILDING.md @@ -19,10 +19,14 @@ Prereqs: From the distribution type: * ./runprebuild.sh - * nant (or xbuild) + * nant (or !* xbuild) * cd bin * copy OpenSim.ini.example to OpenSim.ini and other appropriate files in bin/config-include * run mono OpenSim.exe + !* xbuild option switches + !* clean: xbuild /target:clean + !* debug: (default) xbuild /property:Configuration=Debug + !* release: xbuild /property:Configuration=Release # Using Monodevelop diff --git a/OpenSim/Addons/Groups/Remote/GroupsServiceRobustConnector.cs b/OpenSim/Addons/Groups/Remote/GroupsServiceRobustConnector.cs index 55ae6dbc20..52b9728ecc 100644 --- a/OpenSim/Addons/Groups/Remote/GroupsServiceRobustConnector.cs +++ b/OpenSim/Addons/Groups/Remote/GroupsServiceRobustConnector.cs @@ -109,7 +109,7 @@ namespace OpenSim.Groups string method = request["METHOD"].ToString(); request.Remove("METHOD"); - m_log.DebugFormat("[Groups.Handler]: {0}", method); +// m_log.DebugFormat("[Groups.Handler]: {0}", method); switch (method) { case "PUTGROUP": diff --git a/OpenSim/Data/PGSQL/Properties/AssemblyInfo.cs b/OpenSim/Data/PGSQL/Properties/AssemblyInfo.cs index 27d06790ea..d2096a8cab 100644 --- a/OpenSim/Data/PGSQL/Properties/AssemblyInfo.cs +++ b/OpenSim/Data/PGSQL/Properties/AssemblyInfo.cs @@ -61,5 +61,5 @@ using System.Runtime.InteropServices; // You can specify all the values or you can default the Revision and Build Numbers // by using the '*' as shown below: -[assembly : AssemblyVersion("0.7.6.*")] +[assembly : AssemblyVersion("0.8.0.*")] diff --git a/OpenSim/Framework/Communications/RestClient.cs b/OpenSim/Framework/Communications/RestClient.cs index 89e6aa1cce..586400f2e9 100644 --- a/OpenSim/Framework/Communications/RestClient.cs +++ b/OpenSim/Framework/Communications/RestClient.cs @@ -296,6 +296,14 @@ namespace OpenSim.Framework.Communications #endregion Async communications with server + /// + /// Perform a synchronous request + /// + public Stream Request() + { + return Request(null); + } + /// /// Perform a synchronous request /// diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs index ce14b58a3e..7ac94a04e7 100644 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs @@ -147,8 +147,29 @@ namespace OpenSim.Framework public uint WorldLocX = 0; public uint WorldLocY = 0; public uint WorldLocZ = 0; + + /// + /// X dimension of the region. + /// + /// + /// If this is a varregion then the default size set here will be replaced when we load the region config. + /// public uint RegionSizeX = Constants.RegionSize; + + /// + /// X dimension of the region. + /// + /// + /// If this is a varregion then the default size set here will be replaced when we load the region config. + /// public uint RegionSizeY = Constants.RegionSize; + + /// + /// Z dimension of the region. + /// + /// + /// XXX: Unknown if this accounts for regions with negative Z. + /// public uint RegionSizeZ = Constants.RegionHeight; private Dictionary m_extraSettings = new Dictionary(); diff --git a/OpenSim/Region/ClientStack/Linden/Caps/Tests/WebFetchInvDescModuleTests.cs b/OpenSim/Region/ClientStack/Linden/Caps/Tests/WebFetchInvDescModuleTests.cs index edc5016064..ee1ea1a548 100644 --- a/OpenSim/Region/ClientStack/Linden/Caps/Tests/WebFetchInvDescModuleTests.cs +++ b/OpenSim/Region/ClientStack/Linden/Caps/Tests/WebFetchInvDescModuleTests.cs @@ -152,7 +152,7 @@ namespace OpenSim.Region.ClientStack.Linden.Caps.Tests // A sanity check that the response has the expected number of descendents for a default inventory // TODO: Need a more thorough check. - Assert.That((int)folderOsd["descendents"], Is.EqualTo(14)); + Assert.That((int)folderOsd["descendents"], Is.EqualTo(16)); } } } \ No newline at end of file diff --git a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs index b98afbcb3d..e4977cfdc0 100644 --- a/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs +++ b/OpenSim/Region/CoreModules/World/WorldMap/WorldMapModule.cs @@ -1578,12 +1578,20 @@ namespace OpenSim.Region.CoreModules.World.WorldMap private Byte[] GenerateOverlay() { - using (Bitmap overlay = new Bitmap(256, 256)) + // These need to be ints for bitmap generation + int regionSizeX = (int)m_scene.RegionInfo.RegionSizeX; + int regionSizeY = (int)m_scene.RegionInfo.RegionSizeY; + + int landTileSize = LandManagementModule.LandUnit; + int regionLandTilesX = regionSizeX / landTileSize; + int regionLandTilesY = regionSizeY / landTileSize; + + using (Bitmap overlay = new Bitmap(regionSizeX, regionSizeY)) { - bool[,] saleBitmap = new bool[64, 64]; - for (int x = 0 ; x < 64 ; x++) + bool[,] saleBitmap = new bool[regionLandTilesX, regionLandTilesY]; + for (int x = 0; x < regionLandTilesX; x++) { - for (int y = 0 ; y < 64 ; y++) + for (int y = 0; y < regionLandTilesY; y++) saleBitmap[x, y] = false; } @@ -1596,8 +1604,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap using (Graphics g = Graphics.FromImage(overlay)) { using (SolidBrush transparent = new SolidBrush(background)) - g.FillRectangle(transparent, 0, 0, 256, 256); - + g.FillRectangle(transparent, 0, 0, regionSizeX, regionSizeY); foreach (ILandObject land in parcels) { @@ -1620,12 +1627,16 @@ namespace OpenSim.Region.CoreModules.World.WorldMap using (SolidBrush yellow = new SolidBrush(Color.FromArgb(255, 249, 223, 9))) { - for (int x = 0 ; x < 64 ; x++) + for (int x = 0 ; x < regionLandTilesX ; x++) { - for (int y = 0 ; y < 64 ; y++) + for (int y = 0 ; y < regionLandTilesY ; y++) { if (saleBitmap[x, y]) - g.FillRectangle(yellow, x * 4, 252 - (y * 4), 4, 4); + g.FillRectangle( + yellow, x * landTileSize, + regionSizeX - landTileSize - (y * landTileSize), + landTileSize, + landTileSize); } } } @@ -1654,4 +1665,4 @@ namespace OpenSim.Region.CoreModules.World.WorldMap public uint itemtype; public ulong regionhandle; } -} +} \ No newline at end of file diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index 17f54c2d79..37353c1e3b 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs @@ -3257,7 +3257,11 @@ namespace OpenSim.Region.Framework.Scenes float distanceError = Vector3.Distance(OffsetPosition, expectedPosition); float speed = Velocity.Length(); - float velocidyDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity); + float velocityDiff = Vector3.Distance(lastVelocitySentToAllClients, Velocity); + +// m_log.DebugFormat( +// "[SCENE PRESENCE]: Delta-v {0}, lastVelocity {1}, Velocity {2} for {3} in {4}", +// velocidyDiff, lastVelocitySentToAllClients, Velocity, Name, Scene.Name); // assuming 5 ms. worst case precision for timer, use 2x that // for distance error threshold @@ -3265,8 +3269,12 @@ namespace OpenSim.Region.Framework.Scenes if (speed < 0.01f // allow rotation updates if avatar position is unchanged || Math.Abs(distanceError) > distanceErrorThreshold - || velocidyDiff > 0.01f) // did velocity change from last update? + || velocityDiff > 0.01f) // did velocity change from last update? { +// m_log.DebugFormat( +// "[SCENE PRESENCE]: Update triggered with speed {0}, distanceError {1}, distanceThreshold {2}, delta-v {3} for {4} in {5}", +// speed, distanceError, distanceErrorThreshold, velocidyDiff, Name, Scene.Name); + lastVelocitySentToAllClients = Velocity; lastTerseUpdateToAllClientsTick = currentTick; lastPositionSentToAllClients = OffsetPosition; diff --git a/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs b/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs index d059b97516..870c0bbce9 100644 --- a/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs +++ b/OpenSim/Region/OptionalModules/Scripting/RegionReadyModule/RegionReadyModule.cs @@ -105,8 +105,10 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady m_scene.LoginLock = true; m_scene.EventManager.OnEmptyScriptCompileQueue += OnEmptyScriptCompileQueue; - // Warn level because the region cannot be used while logins are disabled - m_log.WarnFormat("[RegionReady]: Region {0} - LOGINS DISABLED DURING INITIALIZATION.", m_scene.Name); + // This should always show up to the user but should not trigger warn/errors as these messages are + // expected and are not simulator problems. Ideally, there would be a status level in log4net but + // failing that, we will print out to console instead. + MainConsole.Instance.OutputFormat("Region {0} - LOGINS DISABLED DURING INITIALIZATION.", m_scene.Name); if (m_uri != string.Empty) { diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSCharacter.cs b/OpenSim/Region/Physics/BulletSPlugin/BSCharacter.cs index dfcd2bf43f..9b56fb432d 100644 --- a/OpenSim/Region/Physics/BulletSPlugin/BSCharacter.cs +++ b/OpenSim/Region/Physics/BulletSPlugin/BSCharacter.cs @@ -744,7 +744,18 @@ public sealed class BSCharacter : BSPhysObject // and will send agent updates to the clients if velocity changes by more than // 0.001m/s. Bullet introduces a lot of jitter in the velocity which causes many // extra updates. - if (!entprop.Velocity.ApproxEquals(RawVelocity, 0.1f)) + // + // XXX: Contrary to the above comment, setting an update threshold here above 0.4 actually introduces jitter to + // avatar movement rather than removes it. The larger the threshold, the bigger the jitter. + // This is most noticeable in level flight and can be seen with + // the "show updates" option in a viewer. With an update threshold, the RawVelocity cycles between a lower + // bound and an upper bound, where the difference between the two is enough to trigger a large delta v update + // and subsequently trigger an update in ScenePresence.SendTerseUpdateToAllClients(). The cause of this cycle (feedback?) + // has not yet been identified. + // + // If there is a threshold below 0.4 or no threshold check at all (as in ODE), then RawVelocity stays constant and extra + // updates are not triggered in ScenePresence.SendTerseUpdateToAllClients(). +// if (!entprop.Velocity.ApproxEquals(RawVelocity, 0.1f)) RawVelocity = entprop.Velocity; _acceleration = entprop.Acceleration; diff --git a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CompilerTest.cs b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CompilerTest.cs index badf82adc1..713b280497 100644 --- a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CompilerTest.cs +++ b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CompilerTest.cs @@ -25,6 +25,7 @@ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +using System; using System.IO; using System.CodeDom.Compiler; using System.Collections.Generic; @@ -48,6 +49,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools.Tests private CSharpCodeProvider m_CSCodeProvider; private CompilerParameters m_compilerParameters; private CompilerResults m_compilerResults; + private ResolveEventHandler m_resolveEventHandler; /// /// Creates a temporary directory where build artifacts are stored. @@ -67,7 +69,12 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools.Tests m_CSCodeProvider = new CSharpCodeProvider(); m_compilerParameters = new CompilerParameters(); - string rootPath = Path.Combine(Path.GetDirectoryName(System.AppDomain.CurrentDomain.BaseDirectory)); + string rootPath = System.AppDomain.CurrentDomain.BaseDirectory; + + m_resolveEventHandler = new ResolveEventHandler(AssemblyResolver.OnAssemblyResolve); + + System.AppDomain.CurrentDomain.AssemblyResolve += m_resolveEventHandler; + m_compilerParameters.ReferencedAssemblies.Add(Path.Combine(rootPath, "OpenSim.Region.ScriptEngine.Shared.dll")); m_compilerParameters.ReferencedAssemblies.Add(Path.Combine(rootPath, "OpenSim.Region.ScriptEngine.Shared.Api.Runtime.dll")); m_compilerParameters.ReferencedAssemblies.Add(Path.Combine(rootPath, "OpenMetaverseTypes.dll")); @@ -81,6 +88,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools.Tests [TestFixtureTearDown] public void CleanUp() { + System.AppDomain.CurrentDomain.AssemblyResolve -= m_resolveEventHandler; + if (Directory.Exists(m_testDir)) { // Blow away the temporary directory with artifacts. @@ -166,10 +175,11 @@ default m_compilerResults = m_CSCodeProvider.CompileAssemblyFromSource(m_compilerParameters, output); -// foreach (CompilerError compErr in m_compilerResults.Errors) -// { -// System.Console.WriteLine("Error: {0}", compErr); -// } + System.Console.WriteLine("ERRORS: {0}", m_compilerResults.Errors.Count); + foreach (CompilerError compErr in m_compilerResults.Errors) + { + System.Console.WriteLine("Error: {0}", compErr); + } Assert.AreEqual(0, m_compilerResults.Errors.Count); } diff --git a/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs b/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs index e258ddecde..5d65f67b08 100644 --- a/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs +++ b/OpenSim/Server/Handlers/Authentication/AuthenticationServerPostHandler.cs @@ -74,7 +74,7 @@ namespace OpenSim.Server.Handlers.Authentication protected override byte[] ProcessRequest(string path, Stream request, IOSHttpRequest httpRequest, IOSHttpResponse httpResponse) { - m_log.Error("[XXX]: Authenticating..."); +// m_log.Error("[XXX]: Authenticating..."); string[] p = SplitParams(path); if (p.Length > 0) diff --git a/OpenSim/Services/Connectors/Authentication/AuthenticationServicesConnector.cs b/OpenSim/Services/Connectors/Authentication/AuthenticationServicesConnector.cs index 56b6434273..c8a4912e8c 100644 --- a/OpenSim/Services/Connectors/Authentication/AuthenticationServicesConnector.cs +++ b/OpenSim/Services/Connectors/Authentication/AuthenticationServicesConnector.cs @@ -108,7 +108,7 @@ namespace OpenSim.Services.Connectors public bool Verify(UUID principalID, string token, int lifetime) { - m_log.Error("[XXX]: Verify"); +// m_log.Error("[XXX]: Verify"); Dictionary sendData = new Dictionary(); sendData["LIFETIME"] = lifetime.ToString(); sendData["PRINCIPAL"] = principalID.ToString(); diff --git a/bin/Robust.32BitLaunch.exe.config b/bin/Robust.32BitLaunch.exe.config index 95061e1938..0399a1bd34 100644 --- a/bin/Robust.32BitLaunch.exe.config +++ b/bin/Robust.32BitLaunch.exe.config @@ -17,7 +17,7 @@ - + diff --git a/bin/Robust.exe.config b/bin/Robust.exe.config index b9e01f1bc7..3a978b20d4 100644 --- a/bin/Robust.exe.config +++ b/bin/Robust.exe.config @@ -17,7 +17,7 @@ - + diff --git a/bin/pCampBot.exe.config b/bin/pCampBot.exe.config index 791299118b..89350b053d 100755 --- a/bin/pCampBot.exe.config +++ b/bin/pCampBot.exe.config @@ -11,7 +11,7 @@ - +