diff options
author | Melanie | 2012-03-07 00:58:01 +0000 |
---|---|---|
committer | Melanie | 2012-03-07 00:58:01 +0000 |
commit | 5884d080623fddb3ee50b8215d896bdee3fa31a4 (patch) | |
tree | 4fccfda980c385e697b9fda3162bbfd2eb564b08 /OpenSim | |
parent | Merge branch 'master' into careminster (diff) | |
download | opensim-SC_OLD-5884d080623fddb3ee50b8215d896bdee3fa31a4.zip opensim-SC_OLD-5884d080623fddb3ee50b8215d896bdee3fa31a4.tar.gz opensim-SC_OLD-5884d080623fddb3ee50b8215d896bdee3fa31a4.tar.bz2 opensim-SC_OLD-5884d080623fddb3ee50b8215d896bdee3fa31a4.tar.xz |
Fix merge issue
Diffstat (limited to 'OpenSim')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 155 |
1 files changed, 79 insertions, 76 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index fc72946..d016887 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -653,99 +653,102 @@ namespace OpenSim.Region.Framework.Scenes | |||
653 | 653 | ||
654 | // Region config overrides global config | 654 | // Region config overrides global config |
655 | // | 655 | // |
656 | if (m_config.Configs["Startup"] != null) | 656 | try |
657 | { | 657 | { |
658 | IConfig startupConfig = m_config.Configs["Startup"]; | 658 | if (m_config.Configs["Startup"] != null) |
659 | { | ||
660 | IConfig startupConfig = m_config.Configs["Startup"]; | ||
659 | 661 | ||
660 | m_defaultDrawDistance = startupConfig.GetFloat("DefaultDrawDistance",m_defaultDrawDistance); | 662 | m_defaultDrawDistance = startupConfig.GetFloat("DefaultDrawDistance",m_defaultDrawDistance); |
661 | m_useBackup = startupConfig.GetBoolean("UseSceneBackup", m_useBackup); | 663 | m_useBackup = startupConfig.GetBoolean("UseSceneBackup", m_useBackup); |
662 | if (!m_useBackup) | 664 | if (!m_useBackup) |
663 | m_log.InfoFormat("[SCENE]: Backup has been disabled for {0}", RegionInfo.RegionName); | 665 | m_log.InfoFormat("[SCENE]: Backup has been disabled for {0}", RegionInfo.RegionName); |
664 | 666 | ||
665 | //Animation states | 667 | //Animation states |
666 | m_useFlySlow = startupConfig.GetBoolean("enableflyslow", false); | 668 | m_useFlySlow = startupConfig.GetBoolean("enableflyslow", false); |
667 | 669 | ||
668 | PhysicalPrims = startupConfig.GetBoolean("physical_prim", true); | 670 | PhysicalPrims = startupConfig.GetBoolean("physical_prim", true); |
669 | CollidablePrims = startupConfig.GetBoolean("collidable_prim", true); | 671 | CollidablePrims = startupConfig.GetBoolean("collidable_prim", true); |
670 | 672 | ||
671 | m_maxNonphys = startupConfig.GetFloat("NonphysicalPrimMax", m_maxNonphys); | 673 | m_maxNonphys = startupConfig.GetFloat("NonphysicalPrimMax", m_maxNonphys); |
672 | if (RegionInfo.NonphysPrimMax > 0) | 674 | if (RegionInfo.NonphysPrimMax > 0) |
673 | { | 675 | { |
674 | m_maxNonphys = RegionInfo.NonphysPrimMax; | 676 | m_maxNonphys = RegionInfo.NonphysPrimMax; |
675 | } | 677 | } |
676 | 678 | ||
677 | m_maxPhys = startupConfig.GetFloat("PhysicalPrimMax", m_maxPhys); | 679 | m_maxPhys = startupConfig.GetFloat("PhysicalPrimMax", m_maxPhys); |
678 | 680 | ||
679 | if (RegionInfo.PhysPrimMax > 0) | 681 | if (RegionInfo.PhysPrimMax > 0) |
680 | { | 682 | { |
681 | m_maxPhys = RegionInfo.PhysPrimMax; | 683 | m_maxPhys = RegionInfo.PhysPrimMax; |
682 | } | 684 | } |
683 | 685 | ||
684 | // Here, if clamping is requested in either global or | 686 | // Here, if clamping is requested in either global or |
685 | // local config, it will be used | 687 | // local config, it will be used |
686 | // | 688 | // |
687 | m_clampPrimSize = startupConfig.GetBoolean("ClampPrimSize", m_clampPrimSize); | 689 | m_clampPrimSize = startupConfig.GetBoolean("ClampPrimSize", m_clampPrimSize); |
688 | if (RegionInfo.ClampPrimSize) | 690 | if (RegionInfo.ClampPrimSize) |
689 | { | 691 | { |
690 | m_clampPrimSize = true; | 692 | m_clampPrimSize = true; |
691 | } | 693 | } |
692 | 694 | ||
693 | m_trustBinaries = startupConfig.GetBoolean("TrustBinaries", m_trustBinaries); | 695 | m_trustBinaries = startupConfig.GetBoolean("TrustBinaries", m_trustBinaries); |
694 | m_allowScriptCrossings = startupConfig.GetBoolean("AllowScriptCrossing", m_allowScriptCrossings); | 696 | m_allowScriptCrossings = startupConfig.GetBoolean("AllowScriptCrossing", m_allowScriptCrossings); |
695 | m_dontPersistBefore = | 697 | m_dontPersistBefore = |
696 | startupConfig.GetLong("MinimumTimeBeforePersistenceConsidered", DEFAULT_MIN_TIME_FOR_PERSISTENCE); | 698 | startupConfig.GetLong("MinimumTimeBeforePersistenceConsidered", DEFAULT_MIN_TIME_FOR_PERSISTENCE); |
697 | m_dontPersistBefore *= 10000000; | 699 | m_dontPersistBefore *= 10000000; |
698 | m_persistAfter = | 700 | m_persistAfter = |
699 | startupConfig.GetLong("MaximumTimeBeforePersistenceConsidered", DEFAULT_MAX_TIME_FOR_PERSISTENCE); | 701 | startupConfig.GetLong("MaximumTimeBeforePersistenceConsidered", DEFAULT_MAX_TIME_FOR_PERSISTENCE); |
700 | m_persistAfter *= 10000000; | 702 | m_persistAfter *= 10000000; |
701 | 703 | ||
702 | m_defaultScriptEngine = startupConfig.GetString("DefaultScriptEngine", "XEngine"); | 704 | m_defaultScriptEngine = startupConfig.GetString("DefaultScriptEngine", "XEngine"); |
703 | m_log.InfoFormat("[SCENE]: Default script engine {0}", m_defaultScriptEngine); | 705 | m_log.InfoFormat("[SCENE]: Default script engine {0}", m_defaultScriptEngine); |
704 | 706 | ||
705 | IConfig packetConfig = m_config.Configs["PacketPool"]; | 707 | IConfig packetConfig = m_config.Configs["PacketPool"]; |
706 | if (packetConfig != null) | 708 | if (packetConfig != null) |
707 | { | 709 | { |
708 | PacketPool.Instance.RecyclePackets = packetConfig.GetBoolean("RecyclePackets", true); | 710 | PacketPool.Instance.RecyclePackets = packetConfig.GetBoolean("RecyclePackets", true); |
709 | PacketPool.Instance.RecycleDataBlocks = packetConfig.GetBoolean("RecycleDataBlocks", true); | 711 | PacketPool.Instance.RecycleDataBlocks = packetConfig.GetBoolean("RecycleDataBlocks", true); |
710 | } | 712 | } |
711 | 713 | ||
712 | m_strictAccessControl = startupConfig.GetBoolean("StrictAccessControl", m_strictAccessControl); | 714 | m_strictAccessControl = startupConfig.GetBoolean("StrictAccessControl", m_strictAccessControl); |
713 | m_seeIntoBannedRegion = startupConfig.GetBoolean("SeeIntoBannedRegion", m_seeIntoBannedRegion); | 715 | m_seeIntoBannedRegion = startupConfig.GetBoolean("SeeIntoBannedRegion", m_seeIntoBannedRegion); |
714 | CombineRegions = startupConfig.GetBoolean("CombineContiguousRegions", false); | 716 | CombineRegions = startupConfig.GetBoolean("CombineContiguousRegions", false); |
715 | 717 | ||
716 | m_generateMaptiles = startupConfig.GetBoolean("GenerateMaptiles", true); | 718 | m_generateMaptiles = startupConfig.GetBoolean("GenerateMaptiles", true); |
717 | if (m_generateMaptiles) | 719 | if (m_generateMaptiles) |
718 | { | ||
719 | int maptileRefresh = startupConfig.GetInt("MaptileRefresh", 0); | ||
720 | if (maptileRefresh != 0) | ||
721 | { | 720 | { |
722 | m_mapGenerationTimer.Interval = maptileRefresh * 1000; | 721 | int maptileRefresh = startupConfig.GetInt("MaptileRefresh", 0); |
723 | m_mapGenerationTimer.Elapsed += RegenerateMaptileAndReregister; | 722 | if (maptileRefresh != 0) |
724 | m_mapGenerationTimer.AutoReset = true; | 723 | { |
725 | m_mapGenerationTimer.Start(); | 724 | m_mapGenerationTimer.Interval = maptileRefresh * 1000; |
725 | m_mapGenerationTimer.Elapsed += RegenerateMaptileAndReregister; | ||
726 | m_mapGenerationTimer.AutoReset = true; | ||
727 | m_mapGenerationTimer.Start(); | ||
728 | } | ||
726 | } | 729 | } |
727 | } | 730 | else |
728 | else | ||
729 | { | ||
730 | string tile = startupConfig.GetString("MaptileStaticUUID", UUID.Zero.ToString()); | ||
731 | UUID tileID; | ||
732 | |||
733 | if (UUID.TryParse(tile, out tileID)) | ||
734 | { | 731 | { |
735 | RegionInfo.RegionSettings.TerrainImageID = tileID; | 732 | string tile = startupConfig.GetString("MaptileStaticUUID", UUID.Zero.ToString()); |
733 | UUID tileID; | ||
734 | |||
735 | if (UUID.TryParse(tile, out tileID)) | ||
736 | { | ||
737 | RegionInfo.RegionSettings.TerrainImageID = tileID; | ||
738 | } | ||
736 | } | 739 | } |
737 | } | ||
738 | 740 | ||
739 | MinFrameTime = startupConfig.GetFloat( "MinFrameTime", MinFrameTime); | 741 | MinFrameTime = startupConfig.GetFloat( "MinFrameTime", MinFrameTime); |
740 | m_update_backup = startupConfig.GetInt( "UpdateStorageEveryNFrames", m_update_backup); | 742 | m_update_backup = startupConfig.GetInt( "UpdateStorageEveryNFrames", m_update_backup); |
741 | m_update_coarse_locations = startupConfig.GetInt( "UpdateCoarseLocationsEveryNFrames", m_update_coarse_locations); | 743 | m_update_coarse_locations = startupConfig.GetInt( "UpdateCoarseLocationsEveryNFrames", m_update_coarse_locations); |
742 | m_update_entitymovement = startupConfig.GetInt( "UpdateEntityMovementEveryNFrames", m_update_entitymovement); | 744 | m_update_entitymovement = startupConfig.GetInt( "UpdateEntityMovementEveryNFrames", m_update_entitymovement); |
743 | m_update_events = startupConfig.GetInt( "UpdateEventsEveryNFrames", m_update_events); | 745 | m_update_events = startupConfig.GetInt( "UpdateEventsEveryNFrames", m_update_events); |
744 | m_update_objects = startupConfig.GetInt( "UpdateObjectsEveryNFrames", m_update_objects); | 746 | m_update_objects = startupConfig.GetInt( "UpdateObjectsEveryNFrames", m_update_objects); |
745 | m_update_physics = startupConfig.GetInt( "UpdatePhysicsEveryNFrames", m_update_physics); | 747 | m_update_physics = startupConfig.GetInt( "UpdatePhysicsEveryNFrames", m_update_physics); |
746 | m_update_presences = startupConfig.GetInt( "UpdateAgentsEveryNFrames", m_update_presences); | 748 | m_update_presences = startupConfig.GetInt( "UpdateAgentsEveryNFrames", m_update_presences); |
747 | m_update_terrain = startupConfig.GetInt( "UpdateTerrainEveryNFrames", m_update_terrain); | 749 | m_update_terrain = startupConfig.GetInt( "UpdateTerrainEveryNFrames", m_update_terrain); |
748 | m_update_temp_cleaning = startupConfig.GetInt( "UpdateTempCleaningEveryNFrames", m_update_temp_cleaning); | 750 | m_update_temp_cleaning = startupConfig.GetInt( "UpdateTempCleaningEveryNFrames", m_update_temp_cleaning); |
751 | } | ||
749 | } | 752 | } |
750 | catch (Exception e) | 753 | catch (Exception e) |
751 | { | 754 | { |