From 458c6b6f1687a63c7b443a8e76ee31da75c99247 Mon Sep 17 00:00:00 2001 From: mingchen Date: Thu, 7 Jun 2007 16:29:10 +0000 Subject: *Added EstateSettings.cs and moved many relevant variables from RegionInfoBase to EstateSettings class and added an EstateSettings objection to RegionInfoBase *Added a few missed copyright headers *Fixed a filename typo --- OpenSim/OpenSim.RegionServer/Simulator/Avatar.cs | 34 +++++++++++----------- .../Simulator/ParcelManager.cs | 3 -- .../OpenSim.RegionServer/Simulator/SceneObject.cs | 5 +--- OpenSim/OpenSim.RegionServer/Simulator/World.cs | 6 ++-- 4 files changed, 21 insertions(+), 27 deletions(-) (limited to 'OpenSim/OpenSim.RegionServer/Simulator') diff --git a/OpenSim/OpenSim.RegionServer/Simulator/Avatar.cs b/OpenSim/OpenSim.RegionServer/Simulator/Avatar.cs index 0135e26..65a9a63 100644 --- a/OpenSim/OpenSim.RegionServer/Simulator/Avatar.cs +++ b/OpenSim/OpenSim.RegionServer/Simulator/Avatar.cs @@ -425,14 +425,14 @@ namespace OpenSim.RegionServer.Simulator OpenSim.Framework.Console.MainConsole.Instance.Verbose("Avatar.cs:SendRegionhandshake() - Filling in RegionHandshake details"); handshake.RegionInfo.BillableFactor = 0; handshake.RegionInfo.IsEstateManager = false; - handshake.RegionInfo.TerrainHeightRange00 = regionInfo.m_regInfo.TerrainHeightRange00; - handshake.RegionInfo.TerrainHeightRange01 = regionInfo.m_regInfo.TerrainHeightRange01; - handshake.RegionInfo.TerrainHeightRange10 = regionInfo.m_regInfo.TerrainHeightRange10; - handshake.RegionInfo.TerrainHeightRange11 = regionInfo.m_regInfo.TerrainHeightRange11; - handshake.RegionInfo.TerrainStartHeight00 = regionInfo.m_regInfo.TerrainStartHeight00; - handshake.RegionInfo.TerrainStartHeight01 = regionInfo.m_regInfo.TerrainStartHeight01; - handshake.RegionInfo.TerrainStartHeight10 = regionInfo.m_regInfo.TerrainStartHeight10; - handshake.RegionInfo.TerrainStartHeight11 = regionInfo.m_regInfo.TerrainStartHeight11; + handshake.RegionInfo.TerrainHeightRange00 = regionInfo.m_regInfo.estateSettings.terrainHeightRangeNW; + handshake.RegionInfo.TerrainHeightRange01 = regionInfo.m_regInfo.estateSettings.terrainHeightRangeNE; + handshake.RegionInfo.TerrainHeightRange10 = regionInfo.m_regInfo.estateSettings.terrainHeightRangeSW; + handshake.RegionInfo.TerrainHeightRange11 = regionInfo.m_regInfo.estateSettings.terrainHeightRangeSE; + handshake.RegionInfo.TerrainStartHeight00 = regionInfo.m_regInfo.estateSettings.terrainStartHeightNW; + handshake.RegionInfo.TerrainStartHeight01 = regionInfo.m_regInfo.estateSettings.terrainStartHeightNE; + handshake.RegionInfo.TerrainStartHeight10 = regionInfo.m_regInfo.estateSettings.terrainStartHeightSW; + handshake.RegionInfo.TerrainStartHeight11 = regionInfo.m_regInfo.estateSettings.terrainStartHeightSE; handshake.RegionInfo.SimAccess = 13; handshake.RegionInfo.WaterHeight = m_regionWaterHeight; uint regionFlags = 72458694; @@ -442,15 +442,15 @@ namespace OpenSim.RegionServer.Simulator } handshake.RegionInfo.RegionFlags = regionFlags; handshake.RegionInfo.SimName = _enc.GetBytes(m_regionName + "\0"); - handshake.RegionInfo.SimOwner = new LLUUID("00000000-0000-0000-0000-000000000000"); - handshake.RegionInfo.TerrainBase0 = regionInfo.m_regInfo.TerrainBase0; - handshake.RegionInfo.TerrainBase1 = regionInfo.m_regInfo.TerrainBase1; - handshake.RegionInfo.TerrainBase2 = regionInfo.m_regInfo.TerrainBase2; - handshake.RegionInfo.TerrainBase3 = regionInfo.m_regInfo.TerrainBase3; - handshake.RegionInfo.TerrainDetail0 = regionInfo.m_regInfo.TerrainDetail0; - handshake.RegionInfo.TerrainDetail1 = regionInfo.m_regInfo.TerrainDetail1; - handshake.RegionInfo.TerrainDetail2 = regionInfo.m_regInfo.TerrainDetail2; - handshake.RegionInfo.TerrainDetail3 = regionInfo.m_regInfo.TerrainDetail3; + handshake.RegionInfo.SimOwner = regionInfo.m_regInfo.MasterAvatarAssignedUUID; + handshake.RegionInfo.TerrainBase0 = regionInfo.m_regInfo.estateSettings.terrainBase0; + handshake.RegionInfo.TerrainBase1 = regionInfo.m_regInfo.estateSettings.terrainBase1; + handshake.RegionInfo.TerrainBase2 = regionInfo.m_regInfo.estateSettings.terrainBase2; + handshake.RegionInfo.TerrainBase3 = regionInfo.m_regInfo.estateSettings.terrainBase3; + handshake.RegionInfo.TerrainDetail0 = regionInfo.m_regInfo.estateSettings.terrainDetail0; + handshake.RegionInfo.TerrainDetail1 = regionInfo.m_regInfo.estateSettings.terrainDetail1; + handshake.RegionInfo.TerrainDetail2 = regionInfo.m_regInfo.estateSettings.terrainDetail2; + handshake.RegionInfo.TerrainDetail3 = regionInfo.m_regInfo.estateSettings.terrainDetail3; handshake.RegionInfo.CacheID = new LLUUID("545ec0a5-5751-1026-8a0b-216e38a7ab37"); OpenSim.Framework.Console.MainConsole.Instance.Verbose("Avatar.cs:SendRegionHandshake() - Sending RegionHandshake packet"); diff --git a/OpenSim/OpenSim.RegionServer/Simulator/ParcelManager.cs b/OpenSim/OpenSim.RegionServer/Simulator/ParcelManager.cs index a9d4eea..6d432f1 100644 --- a/OpenSim/OpenSim.RegionServer/Simulator/ParcelManager.cs +++ b/OpenSim/OpenSim.RegionServer/Simulator/ParcelManager.cs @@ -284,7 +284,6 @@ namespace OpenSim.RegionServer.Simulator { end_x -= 4; end_y -= 4; - Console.WriteLine("Joining Parcels between (" + start_x + ", " + start_y + ") and (" + end_x + ", " + end_y + ")"); //NOTE: The following only connects the parcels in each corner and not all the parcels that are within the selection box! //This should be fixed later -- somewhat "incomplete code" --Ming @@ -315,7 +314,6 @@ namespace OpenSim.RegionServer.Simulator return false; } - Console.WriteLine("Performing Join on parcel: " + startParcel.parcelData.parcelName + " - " + startParcel.parcelData.area + "sqm and " + endParcel.parcelData.parcelName + " - " + endParcel.parcelData.area + "sqm"); //Same owners! Lets join them //Merge them to startParcel parcelList[startParcel.parcelData.localID].setParcelBitmap(Parcel.mergeParcelBitmaps(startParcel.getParcelBitmap(), endParcel.getParcelBitmap())); @@ -573,7 +571,6 @@ namespace OpenSim.RegionServer.Simulator if (remote_client.AgentID == parcelData.ownerID) { //Needs later group support - Console.WriteLine("Request for update - parcel #" + parcelData.localID); parcelData.authBuyerID = packet.ParcelData.AuthBuyerID; parcelData.category = (libsecondlife.Parcel.ParcelCategory)packet.ParcelData.Category; parcelData.parcelDesc = Helpers.FieldToUTF8String(packet.ParcelData.Desc); diff --git a/OpenSim/OpenSim.RegionServer/Simulator/SceneObject.cs b/OpenSim/OpenSim.RegionServer/Simulator/SceneObject.cs index 1ef91c9..ce2b50d 100644 --- a/OpenSim/OpenSim.RegionServer/Simulator/SceneObject.cs +++ b/OpenSim/OpenSim.RegionServer/Simulator/SceneObject.cs @@ -41,11 +41,8 @@ namespace OpenSim.RegionServer.Simulator { public class SceneObject : Entity { - private LLUUID rootUUID; private Dictionary ChildPrimitives = new Dictionary(); - private Dictionary m_clientThreads; - private World m_world; - + public SceneObject() { diff --git a/OpenSim/OpenSim.RegionServer/Simulator/World.cs b/OpenSim/OpenSim.RegionServer/Simulator/World.cs index 150a092..b4e4f49 100644 --- a/OpenSim/OpenSim.RegionServer/Simulator/World.cs +++ b/OpenSim/OpenSim.RegionServer/Simulator/World.cs @@ -463,7 +463,7 @@ namespace OpenSim.RegionServer.Simulator float[] map = this.localStorage.LoadWorld(); if (map == null) { - if (string.IsNullOrEmpty(this.m_regInfo.TerrainFile)) + if (string.IsNullOrEmpty(this.m_regInfo.estateSettings.terrainFile)) { Console.WriteLine("No default terrain, procedurally generating..."); this.Terrain.hills(); @@ -474,8 +474,8 @@ namespace OpenSim.RegionServer.Simulator { try { - this.Terrain.loadFromFileF32(this.m_regInfo.TerrainFile); - this.Terrain *= this.m_regInfo.TerrainMultiplier; + this.Terrain.loadFromFileF32(this.m_regInfo.estateSettings.terrainFile); + this.Terrain *= this.m_regInfo.estateSettings.terrainMultiplier; } catch (Exception e) { -- cgit v1.1