diff options
Diffstat (limited to 'OpenSim/Framework/RegionInfo.cs')
-rw-r--r-- | OpenSim/Framework/RegionInfo.cs | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs index 239ce3d..f05e2e6 100644 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs | |||
@@ -40,6 +40,7 @@ using OpenSim.Framework.Console; | |||
40 | 40 | ||
41 | namespace OpenSim.Framework | 41 | namespace OpenSim.Framework |
42 | { | 42 | { |
43 | [Serializable] | ||
43 | public class RegionLightShareData : ICloneable | 44 | public class RegionLightShareData : ICloneable |
44 | { | 45 | { |
45 | public bool valid = false; | 46 | public bool valid = false; |
@@ -347,6 +348,7 @@ namespace OpenSim.Framework | |||
347 | 348 | ||
348 | public bool commFailTF = false; | 349 | public bool commFailTF = false; |
349 | public ConfigurationMember configMember; | 350 | public ConfigurationMember configMember; |
351 | public string DataStore = String.Empty; | ||
350 | public string RegionFile = String.Empty; | 352 | public string RegionFile = String.Empty; |
351 | public bool isSandbox = false; | 353 | public bool isSandbox = false; |
352 | public bool Persistent = true; | 354 | public bool Persistent = true; |
@@ -751,6 +753,10 @@ namespace OpenSim.Framework | |||
751 | m_regionLocX = Convert.ToUInt32(locationElements[0]); | 753 | m_regionLocX = Convert.ToUInt32(locationElements[0]); |
752 | m_regionLocY = Convert.ToUInt32(locationElements[1]); | 754 | m_regionLocY = Convert.ToUInt32(locationElements[1]); |
753 | 755 | ||
756 | |||
757 | // Datastore (is this implemented? Omitted from example!) | ||
758 | DataStore = config.GetString("Datastore", String.Empty); | ||
759 | |||
754 | // Internal IP | 760 | // Internal IP |
755 | IPAddress address; | 761 | IPAddress address; |
756 | 762 | ||
@@ -849,6 +855,9 @@ namespace OpenSim.Framework | |||
849 | string location = String.Format("{0},{1}", m_regionLocX, m_regionLocY); | 855 | string location = String.Format("{0},{1}", m_regionLocX, m_regionLocY); |
850 | config.Set("Location", location); | 856 | config.Set("Location", location); |
851 | 857 | ||
858 | if (DataStore != String.Empty) | ||
859 | config.Set("Datastore", DataStore); | ||
860 | |||
852 | config.Set("InternalAddress", m_internalEndPoint.Address.ToString()); | 861 | config.Set("InternalAddress", m_internalEndPoint.Address.ToString()); |
853 | config.Set("InternalPort", m_internalEndPoint.Port); | 862 | config.Set("InternalPort", m_internalEndPoint.Port); |
854 | 863 | ||
@@ -1007,6 +1016,9 @@ namespace OpenSim.Framework | |||
1007 | configMember.addConfigurationOption("object_capacity", ConfigurationOption.ConfigurationTypes.TYPE_INT32, | 1016 | configMember.addConfigurationOption("object_capacity", ConfigurationOption.ConfigurationTypes.TYPE_INT32, |
1008 | "Max objects this sim will hold", "0", true); | 1017 | "Max objects this sim will hold", "0", true); |
1009 | 1018 | ||
1019 | configMember.addConfigurationOption("agent_capacity", ConfigurationOption.ConfigurationTypes.TYPE_INT32, | ||
1020 | "Max agents this sim will hold", "0", true); | ||
1021 | |||
1010 | configMember.addConfigurationOption("scope_id", ConfigurationOption.ConfigurationTypes.TYPE_UUID, | 1022 | configMember.addConfigurationOption("scope_id", ConfigurationOption.ConfigurationTypes.TYPE_UUID, |
1011 | "Scope ID for this region", UUID.Zero.ToString(), true); | 1023 | "Scope ID for this region", UUID.Zero.ToString(), true); |
1012 | 1024 | ||
@@ -1031,6 +1043,9 @@ namespace OpenSim.Framework | |||
1031 | case "sim_location_y": | 1043 | case "sim_location_y": |
1032 | m_regionLocY = (uint) configuration_result; | 1044 | m_regionLocY = (uint) configuration_result; |
1033 | break; | 1045 | break; |
1046 | case "datastore": | ||
1047 | DataStore = (string) configuration_result; | ||
1048 | break; | ||
1034 | case "internal_ip_address": | 1049 | case "internal_ip_address": |
1035 | IPAddress address = (IPAddress) configuration_result; | 1050 | IPAddress address = (IPAddress) configuration_result; |
1036 | m_internalEndPoint = new IPEndPoint(address, 0); | 1051 | m_internalEndPoint = new IPEndPoint(address, 0); |
@@ -1181,6 +1196,11 @@ namespace OpenSim.Framework | |||
1181 | return regionInfo; | 1196 | return regionInfo; |
1182 | } | 1197 | } |
1183 | 1198 | ||
1199 | public int getInternalEndPointPort() | ||
1200 | { | ||
1201 | return m_internalEndPoint.Port; | ||
1202 | } | ||
1203 | |||
1184 | public Dictionary<string, object> ToKeyValuePairs() | 1204 | public Dictionary<string, object> ToKeyValuePairs() |
1185 | { | 1205 | { |
1186 | Dictionary<string, object> kvp = new Dictionary<string, object>(); | 1206 | Dictionary<string, object> kvp = new Dictionary<string, object>(); |
@@ -1199,4 +1219,4 @@ namespace OpenSim.Framework | |||
1199 | return kvp; | 1219 | return kvp; |
1200 | } | 1220 | } |
1201 | } | 1221 | } |
1202 | } \ No newline at end of file | 1222 | } |