diff options
author | mingchen | 2007-08-03 00:14:11 +0000 |
---|---|---|
committer | mingchen | 2007-08-03 00:14:11 +0000 |
commit | 1c68c7a37f60983f61cddc2bf8b1e9b793c4fd2b (patch) | |
tree | 758b28c9bc755223c679a5bdada137e0ea4ffeb8 /OpenSim/Framework/General | |
parent | Fixes flying glitch (hang) when crossing region boundaries (diff) | |
download | opensim-SC_OLD-1c68c7a37f60983f61cddc2bf8b1e9b793c4fd2b.zip opensim-SC_OLD-1c68c7a37f60983f61cddc2bf8b1e9b793c4fd2b.tar.gz opensim-SC_OLD-1c68c7a37f60983f61cddc2bf8b1e9b793c4fd2b.tar.bz2 opensim-SC_OLD-1c68c7a37f60983f61cddc2bf8b1e9b793c4fd2b.tar.xz |
*Estate settings are now saved in their own configuration file called estate_settings.xml using the configuration system.
Diffstat (limited to 'OpenSim/Framework/General')
-rw-r--r-- | OpenSim/Framework/General/Configuration/ConfigurationMember.cs | 10 | ||||
-rw-r--r-- | OpenSim/Framework/General/Types/EstateSettings.cs | 713 | ||||
-rw-r--r-- | OpenSim/Framework/General/Types/RegionInfo.cs | 8 |
3 files changed, 685 insertions, 46 deletions
diff --git a/OpenSim/Framework/General/Configuration/ConfigurationMember.cs b/OpenSim/Framework/General/Configuration/ConfigurationMember.cs index eb5465f..c94fd8e 100644 --- a/OpenSim/Framework/General/Configuration/ConfigurationMember.cs +++ b/OpenSim/Framework/General/Configuration/ConfigurationMember.cs | |||
@@ -64,7 +64,7 @@ namespace OpenSim.Framework.Configuration | |||
64 | configOption.configurationType = configuration_type; | 64 | configOption.configurationType = configuration_type; |
65 | configOption.configurationUseDefaultNoPrompt = use_default_no_prompt; | 65 | configOption.configurationUseDefaultNoPrompt = use_default_no_prompt; |
66 | 66 | ||
67 | if (configuration_key != "" && configuration_question != "") | 67 | if ((configuration_key != "" && configuration_question != "") || (configuration_key != "" && use_default_no_prompt)) |
68 | { | 68 | { |
69 | if (!configurationOptions.Contains(configOption)) | 69 | if (!configurationOptions.Contains(configOption)) |
70 | { | 70 | { |
@@ -375,5 +375,13 @@ namespace OpenSim.Framework.Configuration | |||
375 | pluginAssembly = null; | 375 | pluginAssembly = null; |
376 | return plug; | 376 | return plug; |
377 | } | 377 | } |
378 | |||
379 | public void forceSetConfigurationOption(string configuration_key, string configuration_value) | ||
380 | { | ||
381 | this.configurationPlugin.LoadData(); | ||
382 | this.configurationPlugin.SetAttribute(configuration_key, configuration_value); | ||
383 | this.configurationPlugin.Commit(); | ||
384 | this.configurationPlugin.Close(); | ||
385 | } | ||
378 | } | 386 | } |
379 | } | 387 | } |
diff --git a/OpenSim/Framework/General/Types/EstateSettings.cs b/OpenSim/Framework/General/Types/EstateSettings.cs index 25b3b18..ac173a9 100644 --- a/OpenSim/Framework/General/Types/EstateSettings.cs +++ b/OpenSim/Framework/General/Types/EstateSettings.cs | |||
@@ -27,67 +27,706 @@ | |||
27 | */ | 27 | */ |
28 | 28 | ||
29 | using libsecondlife; | 29 | using libsecondlife; |
30 | 30 | using OpenSim.Framework.Configuration; | |
31 | namespace OpenSim.Framework.Types | 31 | namespace OpenSim.Framework.Types |
32 | { | 32 | { |
33 | public class EstateSettings | 33 | public class EstateSettings |
34 | { | 34 | { |
35 | |||
35 | //Settings to this island | 36 | //Settings to this island |
36 | public float billableFactor = (float)0.0; | 37 | private float m_billableFactor; |
37 | public uint estateID = 0; | 38 | public float billableFactor |
38 | public uint parentEstateID = 0; | 39 | { |
40 | get | ||
41 | { | ||
42 | return m_billableFactor; | ||
43 | } | ||
44 | set | ||
45 | { | ||
46 | m_billableFactor = value; | ||
47 | configMember.forceSetConfigurationOption("billable_factor", m_billableFactor.ToString()); | ||
48 | } | ||
49 | } | ||
50 | |||
51 | |||
52 | private uint m_estateID; | ||
53 | public uint estateID | ||
54 | { | ||
55 | get | ||
56 | { | ||
57 | return m_estateID; | ||
58 | } | ||
59 | set | ||
60 | { | ||
61 | m_estateID = value; | ||
62 | configMember.forceSetConfigurationOption("estate_id", m_estateID.ToString()); | ||
63 | } | ||
64 | } | ||
65 | |||
66 | |||
67 | private uint m_parentEstateID; | ||
68 | public uint parentEstateID | ||
69 | { | ||
70 | get | ||
71 | { | ||
72 | return m_parentEstateID; | ||
73 | } | ||
74 | set | ||
75 | { | ||
76 | m_parentEstateID = value; | ||
77 | configMember.forceSetConfigurationOption("parent_estate_id", m_parentEstateID.ToString()); | ||
78 | } | ||
79 | } | ||
80 | |||
81 | private byte m_maxAgents; | ||
82 | public byte maxAgents | ||
83 | { | ||
84 | get | ||
85 | { | ||
86 | return m_maxAgents; | ||
87 | } | ||
88 | set | ||
89 | { | ||
90 | m_maxAgents = value; | ||
91 | configMember.forceSetConfigurationOption("max_agents", m_maxAgents.ToString()); | ||
92 | } | ||
93 | } | ||
94 | |||
95 | private float m_objectBonusFactor; | ||
96 | public float objectBonusFactor | ||
97 | { | ||
98 | get | ||
99 | { | ||
100 | return m_objectBonusFactor; | ||
101 | } | ||
102 | set | ||
103 | { | ||
104 | m_objectBonusFactor = value; | ||
105 | configMember.forceSetConfigurationOption("object_bonus_factor", m_objectBonusFactor.ToString()); | ||
106 | } | ||
107 | } | ||
108 | |||
109 | private int m_redirectGridX; | ||
110 | public int redirectGridX | ||
111 | { | ||
112 | get | ||
113 | { | ||
114 | return m_redirectGridX; | ||
115 | } | ||
116 | set | ||
117 | { | ||
118 | m_redirectGridX = value; | ||
119 | configMember.forceSetConfigurationOption("redirect_grid_x", m_redirectGridX.ToString()); | ||
120 | } | ||
121 | } | ||
122 | |||
123 | private int m_redirectGridY; | ||
124 | public int redirectGridY | ||
125 | { | ||
126 | get | ||
127 | { | ||
128 | return m_redirectGridY; | ||
129 | } | ||
130 | set | ||
131 | { | ||
132 | m_redirectGridY = value; | ||
133 | configMember.forceSetConfigurationOption("redirect_grid_y", m_redirectGridY.ToString()); | ||
134 | } | ||
135 | } | ||
136 | |||
137 | private Simulator.RegionFlags m_regionFlags; | ||
138 | public Simulator.RegionFlags regionFlags | ||
139 | { | ||
140 | get | ||
141 | { | ||
142 | return m_regionFlags; | ||
143 | } | ||
144 | set | ||
145 | { | ||
146 | m_regionFlags = value; | ||
147 | configMember.forceSetConfigurationOption("region_flags", m_regionFlags.ToString()); | ||
148 | } | ||
149 | } | ||
150 | |||
39 | 151 | ||
40 | public byte maxAgents = 40; | 152 | private Simulator.SimAccess m_simAccess; |
41 | public float objectBonusFactor = (float)1.0; | 153 | public Simulator.SimAccess simAccess |
154 | { | ||
155 | get | ||
156 | { | ||
157 | return m_simAccess; | ||
158 | } | ||
159 | set | ||
160 | { | ||
161 | m_simAccess = value; | ||
162 | configMember.forceSetConfigurationOption("sim_access", m_simAccess.ToString()); | ||
163 | } | ||
164 | } | ||
42 | 165 | ||
43 | public int redirectGridX = 0; //?? | 166 | private float m_sunHour; |
44 | public int redirectGridY = 0; //?? | 167 | public float sunHour |
45 | public Simulator.RegionFlags regionFlags = Simulator.RegionFlags.None; //Booleam values of various region settings | 168 | { |
46 | public Simulator.SimAccess simAccess = Simulator.SimAccess.Mature; //Is sim PG, Mature, etc? Mature by default. | 169 | get |
47 | public float sunHour = 0; | 170 | { |
171 | return m_sunHour; | ||
172 | } | ||
173 | set | ||
174 | { | ||
175 | m_sunHour = value; | ||
176 | configMember.forceSetConfigurationOption("sun_hour", m_sunHour.ToString()); | ||
177 | } | ||
178 | } | ||
48 | 179 | ||
49 | public float terrainRaiseLimit = 0; | 180 | private float m_terrainRaiseLimit; |
50 | public float terrainLowerLimit = 0; | 181 | public float terrainRaiseLimit |
182 | { | ||
183 | get | ||
184 | { | ||
185 | return m_terrainRaiseLimit; | ||
186 | } | ||
187 | set | ||
188 | { | ||
189 | m_terrainRaiseLimit = value; | ||
190 | configMember.forceSetConfigurationOption("terrain_raise_limit", m_terrainRaiseLimit.ToString()); | ||
191 | } | ||
192 | } | ||
51 | 193 | ||
52 | public bool useFixedSun = false; | 194 | private float m_terrainLowerLimit; |
53 | public int pricePerMeter = 1; | 195 | public float terrainLowerLimit |
196 | { | ||
197 | get | ||
198 | { | ||
199 | return m_terrainLowerLimit; | ||
200 | } | ||
201 | set | ||
202 | { | ||
203 | m_terrainLowerLimit = value; | ||
204 | configMember.forceSetConfigurationOption("terrain_lower_limit", m_terrainLowerLimit.ToString()); | ||
205 | } | ||
206 | } | ||
54 | 207 | ||
55 | public ushort regionWaterHeight = 20; | 208 | private bool m_useFixedSun; |
56 | public bool regionAllowTerraform = true; | 209 | public bool useFixedSun |
210 | { | ||
211 | get | ||
212 | { | ||
213 | return m_useFixedSun; | ||
214 | } | ||
215 | set | ||
216 | { | ||
217 | m_useFixedSun = value; | ||
218 | configMember.forceSetConfigurationOption("use_fixed_sun", m_useFixedSun.ToString()); | ||
219 | } | ||
220 | } | ||
57 | 221 | ||
222 | |||
223 | private int m_pricePerMeter; | ||
224 | public int pricePerMeter | ||
225 | { | ||
226 | get | ||
227 | { | ||
228 | return m_pricePerMeter; | ||
229 | } | ||
230 | set | ||
231 | { | ||
232 | m_pricePerMeter = value; | ||
233 | configMember.forceSetConfigurationOption("price_per_meter", m_pricePerMeter.ToString()); | ||
234 | } | ||
235 | } | ||
236 | |||
237 | |||
238 | private ushort m_regionWaterHeight; | ||
239 | public ushort regionWaterHeight | ||
240 | { | ||
241 | get | ||
242 | { | ||
243 | return m_regionWaterHeight; | ||
244 | } | ||
245 | set | ||
246 | { | ||
247 | m_regionWaterHeight = value; | ||
248 | configMember.forceSetConfigurationOption("region_water_height", m_regionWaterHeight.ToString()); | ||
249 | } | ||
250 | } | ||
251 | |||
252 | |||
253 | private bool m_regionAllowTerraform; | ||
254 | public bool regionAllowTerraform | ||
255 | { | ||
256 | get | ||
257 | { | ||
258 | return m_regionAllowTerraform; | ||
259 | } | ||
260 | set | ||
261 | { | ||
262 | m_regionAllowTerraform = value; | ||
263 | configMember.forceSetConfigurationOption("region_allow_terraform", m_regionAllowTerraform.ToString()); | ||
264 | } | ||
265 | } | ||
266 | |||
267 | |||
58 | // Region Information | 268 | // Region Information |
59 | // Low resolution 'base' textures. No longer used. | 269 | // Low resolution 'base' textures. No longer used. |
60 | public LLUUID terrainBase0 = new LLUUID("b8d3965a-ad78-bf43-699b-bff8eca6c975"); // Default | 270 | private LLUUID m_terrainBase0; |
61 | public LLUUID terrainBase1 = new LLUUID("abb783e6-3e93-26c0-248a-247666855da3"); // Default | 271 | public LLUUID terrainBase0 |
62 | public LLUUID terrainBase2 = new LLUUID("179cdabd-398a-9b6b-1391-4dc333ba321f"); // Default | 272 | { |
63 | public LLUUID terrainBase3 = new LLUUID("beb169c7-11ea-fff2-efe5-0f24dc881df2"); // Default | 273 | get |
274 | { | ||
275 | return m_terrainBase0; | ||
276 | } | ||
277 | set | ||
278 | { | ||
279 | m_terrainBase0 = value; | ||
280 | configMember.forceSetConfigurationOption("terrain_base_0", m_terrainBase0.ToString()); | ||
281 | } | ||
282 | } | ||
283 | |||
284 | private LLUUID m_terrainBase1; | ||
285 | public LLUUID terrainBase1 | ||
286 | { | ||
287 | get | ||
288 | { | ||
289 | return m_terrainBase1; | ||
290 | } | ||
291 | set | ||
292 | { | ||
293 | m_terrainBase1 = value; | ||
294 | configMember.forceSetConfigurationOption("terrain_base_1", m_terrainBase1.ToString()); | ||
295 | } | ||
296 | } | ||
297 | |||
298 | private LLUUID m_terrainBase2; | ||
299 | public LLUUID terrainBase2 | ||
300 | { | ||
301 | get | ||
302 | { | ||
303 | return m_terrainBase2; | ||
304 | } | ||
305 | set | ||
306 | { | ||
307 | m_terrainBase2 = value; | ||
308 | configMember.forceSetConfigurationOption("terrain_base_2", m_terrainBase2.ToString()); | ||
309 | } | ||
310 | } | ||
311 | |||
312 | private LLUUID m_terrainBase3; | ||
313 | public LLUUID terrainBase3 | ||
314 | { | ||
315 | get | ||
316 | { | ||
317 | return m_terrainBase3; | ||
318 | } | ||
319 | set | ||
320 | { | ||
321 | m_terrainBase3 = value; | ||
322 | configMember.forceSetConfigurationOption("terrain_base_3", m_terrainBase3.ToString()); | ||
323 | } | ||
324 | } | ||
325 | |||
64 | 326 | ||
65 | // Higher resolution terrain textures | 327 | // Higher resolution terrain textures |
66 | public LLUUID terrainDetail0 = new LLUUID("00000000-0000-0000-0000-000000000000"); | 328 | private LLUUID m_terrainDetail0; |
67 | public LLUUID terrainDetail1 = new LLUUID("00000000-0000-0000-0000-000000000000"); | 329 | public LLUUID terrainDetail0 |
68 | public LLUUID terrainDetail2 = new LLUUID("00000000-0000-0000-0000-000000000000"); | 330 | { |
69 | public LLUUID terrainDetail3 = new LLUUID("00000000-0000-0000-0000-000000000000"); | 331 | get |
332 | { | ||
333 | return m_terrainDetail0; | ||
334 | } | ||
335 | set | ||
336 | { | ||
337 | |||
338 | m_terrainDetail0 = value; | ||
339 | configMember.forceSetConfigurationOption("terrain_detail_0", m_terrainDetail0.ToString()); | ||
340 | } | ||
341 | } | ||
342 | |||
343 | private LLUUID m_terrainDetail1; | ||
344 | public LLUUID terrainDetail1 | ||
345 | { | ||
346 | get | ||
347 | { | ||
348 | return m_terrainDetail1; | ||
349 | } | ||
350 | set | ||
351 | { | ||
352 | m_terrainDetail1 = value; | ||
353 | configMember.forceSetConfigurationOption("terrain_detail_1", m_terrainDetail1.ToString()); | ||
354 | } | ||
355 | } | ||
356 | private LLUUID m_terrainDetail2; | ||
357 | public LLUUID terrainDetail2 | ||
358 | { | ||
359 | get | ||
360 | { | ||
361 | return m_terrainDetail2; | ||
362 | } | ||
363 | set | ||
364 | { | ||
365 | m_terrainDetail2 = value; | ||
366 | configMember.forceSetConfigurationOption("terrain_detail_2", m_terrainDetail2.ToString()); | ||
367 | } | ||
368 | } | ||
369 | private LLUUID m_terrainDetail3; | ||
370 | public LLUUID terrainDetail3 | ||
371 | { | ||
372 | get | ||
373 | { | ||
374 | return m_terrainDetail3; | ||
375 | } | ||
376 | set | ||
377 | { | ||
378 | m_terrainDetail3 = value; | ||
379 | configMember.forceSetConfigurationOption("terrain_detail_3", m_terrainDetail3.ToString()); | ||
380 | } | ||
381 | } | ||
70 | 382 | ||
71 | // First quad - each point is bilinearly interpolated at each meter of terrain | 383 | // First quad - each point is bilinearly interpolated at each meter of terrain |
72 | public float terrainStartHeight0 = 10.0f; | 384 | private float m_terrainStartHeight0; |
73 | public float terrainStartHeight1 = 10.0f; | 385 | public float terrainStartHeight0 |
74 | public float terrainStartHeight2 = 10.0f; | 386 | { |
75 | public float terrainStartHeight3 = 10.0f; | 387 | get |
388 | { | ||
389 | return m_terrainStartHeight0; | ||
390 | } | ||
391 | set | ||
392 | { | ||
393 | m_terrainStartHeight0 = value; | ||
394 | configMember.forceSetConfigurationOption("terrain_start_height_0", m_terrainStartHeight0.ToString()); | ||
395 | } | ||
396 | } | ||
76 | 397 | ||
398 | |||
399 | private float m_terrainStartHeight1; | ||
400 | public float terrainStartHeight1 | ||
401 | { | ||
402 | get | ||
403 | { | ||
404 | return m_terrainStartHeight1; | ||
405 | } | ||
406 | set | ||
407 | { | ||
408 | m_terrainStartHeight1 = value; | ||
409 | configMember.forceSetConfigurationOption("terrain_start_height_1", m_terrainStartHeight1.ToString()); | ||
410 | } | ||
411 | } | ||
412 | |||
413 | private float m_terrainStartHeight2; | ||
414 | public float terrainStartHeight2 | ||
415 | { | ||
416 | get | ||
417 | { | ||
418 | return m_terrainStartHeight2; | ||
419 | } | ||
420 | set | ||
421 | { | ||
422 | m_terrainStartHeight2 = value; | ||
423 | configMember.forceSetConfigurationOption("terrain_start_height_2", m_terrainStartHeight2.ToString()); | ||
424 | } | ||
425 | } | ||
426 | |||
427 | private float m_terrainStartHeight3; | ||
428 | public float terrainStartHeight3 | ||
429 | { | ||
430 | get | ||
431 | { | ||
432 | return m_terrainStartHeight3; | ||
433 | } | ||
434 | set | ||
435 | { | ||
436 | m_terrainStartHeight3 = value; | ||
437 | configMember.forceSetConfigurationOption("terrain_start_height_3", m_terrainStartHeight3.ToString()); | ||
438 | } | ||
439 | } | ||
77 | // Second quad - also bilinearly interpolated. | 440 | // Second quad - also bilinearly interpolated. |
78 | // Terrain texturing is done that: | 441 | // Terrain texturing is done that: |
79 | // 0..3 (0 = base0, 3 = base3) = (terrain[x,y] - start[x,y]) / range[x,y] | 442 | // 0..3 (0 = base0, 3 = base3) = (terrain[x,y] - start[x,y]) / range[x,y] |
80 | public float terrainHeightRange0 = 60.0f; //00 | 443 | private float m_terrainHeightRange0; |
81 | public float terrainHeightRange1 = 60.0f; //01 | 444 | public float terrainHeightRange0 |
82 | public float terrainHeightRange2 = 60.0f; //10 | 445 | { |
83 | public float terrainHeightRange3 = 60.0f; //11 | 446 | get |
447 | { | ||
448 | return m_terrainHeightRange0; | ||
449 | } | ||
450 | set | ||
451 | { | ||
452 | m_terrainHeightRange0 = value; | ||
453 | configMember.forceSetConfigurationOption("terrain_height_range_0", m_terrainHeightRange0.ToString()); | ||
454 | } | ||
455 | } | ||
84 | 456 | ||
457 | private float m_terrainHeightRange1; | ||
458 | public float terrainHeightRange1 | ||
459 | { | ||
460 | get | ||
461 | { | ||
462 | return m_terrainHeightRange1; | ||
463 | } | ||
464 | set | ||
465 | { | ||
466 | m_terrainHeightRange1 = value; | ||
467 | configMember.forceSetConfigurationOption("terrain_height_range_1", m_terrainHeightRange1.ToString()); | ||
468 | } | ||
469 | } | ||
470 | |||
471 | private float m_terrainHeightRange2; | ||
472 | public float terrainHeightRange2 | ||
473 | { | ||
474 | get | ||
475 | { | ||
476 | return m_terrainHeightRange2; | ||
477 | } | ||
478 | set | ||
479 | { | ||
480 | m_terrainHeightRange2 = value; | ||
481 | configMember.forceSetConfigurationOption("terrain_height_range_2", m_terrainHeightRange2.ToString()); | ||
482 | } | ||
483 | } | ||
484 | |||
485 | private float m_terrainHeightRange3; | ||
486 | public float terrainHeightRange3 | ||
487 | { | ||
488 | get | ||
489 | { | ||
490 | return m_terrainHeightRange3; | ||
491 | } | ||
492 | set | ||
493 | { | ||
494 | m_terrainHeightRange3 = value; | ||
495 | configMember.forceSetConfigurationOption("terrain_height_range_3", m_terrainHeightRange3.ToString()); | ||
496 | } | ||
497 | } | ||
85 | // Terrain Default (Must be in F32 Format!) | 498 | // Terrain Default (Must be in F32 Format!) |
86 | public string terrainFile = "default.r32"; | 499 | private string m_terrainFile; |
87 | public double terrainMultiplier = 60.0; | 500 | public string terrainFile |
88 | public float waterHeight = (float)20.0; | 501 | { |
502 | get | ||
503 | { | ||
504 | return m_terrainFile; | ||
505 | } | ||
506 | set | ||
507 | { | ||
508 | m_terrainFile = value; | ||
509 | configMember.forceSetConfigurationOption("terrain_file", m_terrainFile.ToString()); | ||
510 | } | ||
511 | } | ||
512 | |||
513 | private double m_terrainMultiplier; | ||
514 | public double terrainMultiplier | ||
515 | { | ||
516 | get | ||
517 | { | ||
518 | return m_terrainMultiplier; | ||
519 | } | ||
520 | set | ||
521 | { | ||
522 | m_terrainMultiplier = value; | ||
523 | configMember.forceSetConfigurationOption("terrain_multiplier", m_terrainMultiplier.ToString()); | ||
524 | } | ||
525 | } | ||
526 | |||
527 | private float m_waterHeight; | ||
528 | public float waterHeight | ||
529 | { | ||
530 | get | ||
531 | { | ||
532 | return m_waterHeight; | ||
533 | } | ||
534 | set | ||
535 | { | ||
536 | m_waterHeight = value; | ||
537 | configMember.forceSetConfigurationOption("water_height", m_waterHeight.ToString()); | ||
538 | } | ||
539 | } | ||
540 | |||
541 | private LLUUID m_terrainImageID; | ||
542 | public LLUUID terrainImageID | ||
543 | { | ||
544 | get | ||
545 | { | ||
546 | return m_terrainImageID; | ||
547 | } | ||
548 | set | ||
549 | { | ||
550 | m_terrainImageID = value; | ||
551 | configMember.forceSetConfigurationOption("terrain_image_id", m_terrainImageID.ToString()); | ||
552 | } | ||
553 | } | ||
554 | private ConfigurationMember configMember; | ||
555 | public EstateSettings() | ||
556 | { | ||
557 | configMember = new ConfigurationMember("estate_settings.xml", "ESTATE SETTINGS", this.loadConfigurationOptions, this.handleIncomingConfiguration); | ||
558 | configMember.performConfigurationRetrieve(); | ||
559 | } | ||
560 | |||
561 | public void loadConfigurationOptions() | ||
562 | { | ||
563 | |||
564 | configMember.addConfigurationOption("billable_factor", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "","0.0",true); | ||
565 | configMember.addConfigurationOption("estate_id", ConfigurationOption.ConfigurationTypes.TYPE_UINT32, "","0",true); | ||
566 | configMember.addConfigurationOption("parent_estate_id", ConfigurationOption.ConfigurationTypes.TYPE_UINT32, "", "0", true); | ||
567 | configMember.addConfigurationOption("max_agents", ConfigurationOption.ConfigurationTypes.TYPE_BYTE, "", "40", true); | ||
568 | |||
569 | configMember.addConfigurationOption("object_bonus_factor", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "1.0", true); | ||
570 | configMember.addConfigurationOption("redirect_grid_x", ConfigurationOption.ConfigurationTypes.TYPE_INT32, "", "0", true); | ||
571 | configMember.addConfigurationOption("redirect_grid_y", ConfigurationOption.ConfigurationTypes.TYPE_INT32, "", "0", true); | ||
572 | configMember.addConfigurationOption("region_flags", ConfigurationOption.ConfigurationTypes.TYPE_UINT32, "", "0", true); | ||
573 | configMember.addConfigurationOption("sim_access", ConfigurationOption.ConfigurationTypes.TYPE_BYTE, "", "21", true); | ||
574 | configMember.addConfigurationOption("sun_hour", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "0", true); | ||
575 | configMember.addConfigurationOption("terrain_raise_limit", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "0", true); | ||
576 | configMember.addConfigurationOption("terrain_lower_limit", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "0", true); | ||
577 | configMember.addConfigurationOption("use_fixed_sun", ConfigurationOption.ConfigurationTypes.TYPE_BOOLEAN, "", "false", true); | ||
578 | configMember.addConfigurationOption("price_per_meter", ConfigurationOption.ConfigurationTypes.TYPE_UINT32, "", "1", true); | ||
579 | configMember.addConfigurationOption("region_water_height", ConfigurationOption.ConfigurationTypes.TYPE_UINT16, "", "20", true); | ||
580 | configMember.addConfigurationOption("region_allow_terraform", ConfigurationOption.ConfigurationTypes.TYPE_BOOLEAN, "", "true", true); | ||
581 | |||
582 | configMember.addConfigurationOption("terrain_base_0", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "b8d3965a-ad78-bf43-699b-bff8eca6c975", true); | ||
583 | configMember.addConfigurationOption("terrain_base_1", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "abb783e6-3e93-26c0-248a-247666855da3", true); | ||
584 | configMember.addConfigurationOption("terrain_base_2", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "179cdabd-398a-9b6b-1391-4dc333ba321f", true); | ||
585 | configMember.addConfigurationOption("terrain_base_3", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "beb169c7-11ea-fff2-efe5-0f24dc881df2", true); | ||
586 | |||
587 | configMember.addConfigurationOption("terrain_detail_0", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "00000000-0000-0000-0000-000000000000", true); | ||
588 | configMember.addConfigurationOption("terrain_detail_1", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "00000000-0000-0000-0000-000000000000", true); | ||
589 | configMember.addConfigurationOption("terrain_detail_2", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "00000000-0000-0000-0000-000000000000", true); | ||
590 | configMember.addConfigurationOption("terrain_detail_3", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "00000000-0000-0000-0000-000000000000", true); | ||
591 | |||
592 | configMember.addConfigurationOption("terrain_start_height_0", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "10.0", true); | ||
593 | configMember.addConfigurationOption("terrain_start_height_1", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "10.0", true); | ||
594 | configMember.addConfigurationOption("terrain_start_height_2", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "10.0", true); | ||
595 | configMember.addConfigurationOption("terrain_start_height_3", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "10.0", true); | ||
596 | |||
597 | configMember.addConfigurationOption("terrain_height_range_0", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "60.0", true); | ||
598 | configMember.addConfigurationOption("terrain_height_range_1", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "60.0", true); | ||
599 | configMember.addConfigurationOption("terrain_height_range_2", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "60.0", true); | ||
600 | configMember.addConfigurationOption("terrain_height_range_3", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "60.0", true); | ||
601 | |||
602 | configMember.addConfigurationOption("terrain_file", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "", "default.r32", true); | ||
603 | configMember.addConfigurationOption("terrain_multiplier", ConfigurationOption.ConfigurationTypes.TYPE_FLOAT, "", "60.0", true); | ||
604 | configMember.addConfigurationOption("water_height", ConfigurationOption.ConfigurationTypes.TYPE_DOUBLE, "", "20.0", true); | ||
605 | configMember.addConfigurationOption("terrain_image_id", ConfigurationOption.ConfigurationTypes.TYPE_LLUUID, "", "00000000-0000-0000-0000-000000000000", true); | ||
606 | |||
607 | } | ||
608 | |||
609 | public bool handleIncomingConfiguration(string configuration_key, object configuration_result) | ||
610 | { | ||
611 | switch (configuration_key) | ||
612 | { | ||
613 | case "billable_factor": | ||
614 | this.m_billableFactor = (float)configuration_result; | ||
615 | break; | ||
616 | case "estate_id": | ||
617 | this.m_estateID = (uint)configuration_result; | ||
618 | break; | ||
619 | case "parent_estate_id": | ||
620 | this.m_parentEstateID = (uint)configuration_result; | ||
621 | break; | ||
622 | case "max_agents": | ||
623 | this.m_maxAgents = (byte)configuration_result; | ||
624 | break; | ||
625 | |||
626 | case "object_bonus_factor": | ||
627 | this.m_objectBonusFactor = (float)configuration_result; | ||
628 | break; | ||
629 | case "redirect_grid_x": | ||
630 | this.m_redirectGridX = (int)configuration_result; | ||
631 | break; | ||
632 | case "redirect_grid_y": | ||
633 | this.m_redirectGridY = (int)configuration_result; | ||
634 | break; | ||
635 | case "region_flags": | ||
636 | this.m_regionFlags = (Simulator.RegionFlags)((uint)configuration_result); | ||
637 | break; | ||
638 | case "sim_access": | ||
639 | this.m_simAccess = (Simulator.SimAccess)((byte)configuration_result); | ||
640 | break; | ||
641 | case "sun_hour": | ||
642 | this.m_sunHour = (float)configuration_result; | ||
643 | break; | ||
644 | case "terrain_raise_limit": | ||
645 | this.m_terrainRaiseLimit = (float)configuration_result; | ||
646 | break; | ||
647 | case "terrain_lower_limit": | ||
648 | this.m_terrainLowerLimit = (float)configuration_result; | ||
649 | break; | ||
650 | case "use_fixed_sun": | ||
651 | this.m_useFixedSun = (bool)configuration_result; | ||
652 | break; | ||
653 | case "price_per_meter": | ||
654 | this.m_pricePerMeter = System.Convert.ToInt32(configuration_result); | ||
655 | break; | ||
656 | case "region_water_height": | ||
657 | this.m_regionWaterHeight = (ushort)configuration_result; | ||
658 | break; | ||
659 | case "region_allow_terraform": | ||
660 | this.m_regionAllowTerraform = (bool)configuration_result; | ||
661 | break; | ||
662 | |||
663 | case "terrain_base_0": | ||
664 | this.m_terrainBase0 = (LLUUID)configuration_result; | ||
665 | break; | ||
666 | case "terrain_base_1": | ||
667 | this.m_terrainBase1 = (LLUUID)configuration_result; | ||
668 | break; | ||
669 | case "terrain_base_2": | ||
670 | this.m_terrainBase2 = (LLUUID)configuration_result; | ||
671 | break; | ||
672 | case "terrain_base_3": | ||
673 | this.m_terrainBase3 = (LLUUID)configuration_result; | ||
674 | break; | ||
675 | |||
676 | case "terrain_detail_0": | ||
677 | this.m_terrainDetail0 = (LLUUID)configuration_result; | ||
678 | break; | ||
679 | case "terrain_detail_1": | ||
680 | this.m_terrainDetail1 = (LLUUID)configuration_result; | ||
681 | break; | ||
682 | case "terrain_detail_2": | ||
683 | this.m_terrainDetail2 = (LLUUID)configuration_result; | ||
684 | break; | ||
685 | case "terrain_detail_3": | ||
686 | this.m_terrainDetail3 = (LLUUID)configuration_result; | ||
687 | break; | ||
688 | |||
689 | case "terrain_start_height_0": | ||
690 | this.m_terrainStartHeight0 = (float)configuration_result; | ||
691 | break; | ||
692 | case "terrain_start_height_1": | ||
693 | this.m_terrainStartHeight1 = (float)configuration_result; | ||
694 | break; | ||
695 | case "terrain_start_height_2": | ||
696 | this.m_terrainStartHeight2 = (float)configuration_result; | ||
697 | break; | ||
698 | case "terrain_start_height_3": | ||
699 | this.m_terrainStartHeight3 = (float)configuration_result; | ||
700 | break; | ||
701 | |||
702 | case "terrain_height_range_0": | ||
703 | this.m_terrainHeightRange0 = (float)configuration_result; | ||
704 | break; | ||
705 | case "terrain_height_range_1": | ||
706 | this.m_terrainHeightRange1 = (float)configuration_result; | ||
707 | break; | ||
708 | case "terrain_height_range_2": | ||
709 | this.m_terrainHeightRange2 = (float)configuration_result; | ||
710 | break; | ||
711 | case "terrain_height_range_3": | ||
712 | this.m_terrainHeightRange3 = (float)configuration_result; | ||
713 | break; | ||
89 | 714 | ||
90 | public LLUUID terrainImageID = LLUUID.Zero; // the assetID that is the current Map image for this region | 715 | case "terrain_file": |
716 | this.m_terrainFile = (string)configuration_result; | ||
717 | break; | ||
718 | case "terrain_multiplier": | ||
719 | this.m_terrainMultiplier = System.Convert.ToDouble(configuration_result); | ||
720 | break; | ||
721 | case "water_height": | ||
722 | float.TryParse(((double)configuration_result).ToString(),out this.m_waterHeight); | ||
723 | break; | ||
724 | case "terrain_image_id": | ||
725 | this.m_terrainImageID = (LLUUID)configuration_result; | ||
726 | break; | ||
727 | } | ||
91 | 728 | ||
729 | return true; | ||
730 | } | ||
92 | } | 731 | } |
93 | } | 732 | } |
diff --git a/OpenSim/Framework/General/Types/RegionInfo.cs b/OpenSim/Framework/General/Types/RegionInfo.cs index ef05534..297e324 100644 --- a/OpenSim/Framework/General/Types/RegionInfo.cs +++ b/OpenSim/Framework/General/Types/RegionInfo.cs | |||
@@ -172,8 +172,6 @@ namespace OpenSim.Framework.Types | |||
172 | configMember.addConfigurationOption("internal_ip_address", ConfigurationOption.ConfigurationTypes.TYPE_IP_ADDRESS, "Internal IP Address for incoming UDP client connections", "0.0.0.0", false); | 172 | configMember.addConfigurationOption("internal_ip_address", ConfigurationOption.ConfigurationTypes.TYPE_IP_ADDRESS, "Internal IP Address for incoming UDP client connections", "0.0.0.0", false); |
173 | configMember.addConfigurationOption("internal_ip_port", ConfigurationOption.ConfigurationTypes.TYPE_INT32, "Internal IP Port for incoming UDP client connections", "9000", false); | 173 | configMember.addConfigurationOption("internal_ip_port", ConfigurationOption.ConfigurationTypes.TYPE_INT32, "Internal IP Port for incoming UDP client connections", "9000", false); |
174 | configMember.addConfigurationOption("external_host_name", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "External Host Name", "127.0.0.1", false); | 174 | configMember.addConfigurationOption("external_host_name", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "External Host Name", "127.0.0.1", false); |
175 | configMember.addConfigurationOption("terrain_file", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "Default Terrain File", "default.r32", false); | ||
176 | configMember.addConfigurationOption("terrain_multiplier", ConfigurationOption.ConfigurationTypes.TYPE_DOUBLE, "Terrain Height Multiplier", "60.0", false); | ||
177 | configMember.addConfigurationOption("master_avatar_first", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "First Name of Master Avatar", "Test", false); | 175 | configMember.addConfigurationOption("master_avatar_first", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "First Name of Master Avatar", "Test", false); |
178 | configMember.addConfigurationOption("master_avatar_last", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "Last Name of Master Avatar", "User", false); | 176 | configMember.addConfigurationOption("master_avatar_last", ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, "Last Name of Master Avatar", "User", false); |
179 | configMember.addConfigurationOption("master_avatar_pass", ConfigurationOption.ConfigurationTypes.TYPE_STRING, "(Sandbox Mode Only)Password for Master Avatar account", "test", false); | 177 | configMember.addConfigurationOption("master_avatar_pass", ConfigurationOption.ConfigurationTypes.TYPE_STRING, "(Sandbox Mode Only)Password for Master Avatar account", "test", false); |
@@ -216,12 +214,6 @@ namespace OpenSim.Framework.Types | |||
216 | this.m_externalHostName = Util.GetLocalHost().ToString(); | 214 | this.m_externalHostName = Util.GetLocalHost().ToString(); |
217 | } | 215 | } |
218 | break; | 216 | break; |
219 | case "terrain_file": | ||
220 | this.estateSettings.terrainFile = (string)configuration_result; | ||
221 | break; | ||
222 | case "terrain_multiplier": | ||
223 | this.estateSettings.terrainMultiplier = (double)configuration_result; | ||
224 | break; | ||
225 | case "master_avatar_first": | 217 | case "master_avatar_first": |
226 | this.MasterAvatarFirstName = (string)configuration_result; | 218 | this.MasterAvatarFirstName = (string)configuration_result; |
227 | break; | 219 | break; |