diff options
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Scene.cs')
-rwxr-xr-x | OpenSim/Region/Framework/Scenes/Scene.cs | 93 |
1 files changed, 47 insertions, 46 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index aac791d..58f3b61 100755 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -2796,56 +2796,57 @@ namespace OpenSim.Region.Framework.Scenes | |||
2796 | return false; | 2796 | return false; |
2797 | } | 2797 | } |
2798 | 2798 | ||
2799 | /* not in use, outdate by async method | ||
2800 | /// <summary> | ||
2801 | /// Move the given scene object into a new region depending on which region its absolute position has moved | ||
2802 | /// into. | ||
2803 | /// | ||
2804 | /// </summary> | ||
2805 | /// <param name="attemptedPosition">the attempted out of region position of the scene object</param> | ||
2806 | /// <param name="grp">the scene object that we're crossing</param> | ||
2807 | public void CrossPrimGroupIntoNewRegion(Vector3 attemptedPosition, SceneObjectGroup grp, bool silent) | ||
2808 | { | ||
2809 | if (grp == null) | ||
2810 | return; | ||
2811 | if (grp.IsDeleted) | ||
2812 | return; | ||
2813 | 2799 | ||
2814 | if (grp.RootPart.DIE_AT_EDGE) | 2800 | /* not in use, outdate by async method |
2815 | { | 2801 | /// <summary> |
2816 | // We remove the object here | 2802 | /// Move the given scene object into a new region depending on which region its absolute position has moved |
2817 | try | 2803 | /// into. |
2818 | { | 2804 | /// |
2819 | DeleteSceneObject(grp, false); | 2805 | /// </summary> |
2820 | } | 2806 | /// <param name="attemptedPosition">the attempted out of region position of the scene object</param> |
2821 | catch (Exception) | 2807 | /// <param name="grp">the scene object that we're crossing</param> |
2808 | public void CrossPrimGroupIntoNewRegion(Vector3 attemptedPosition, SceneObjectGroup grp, bool silent) | ||
2822 | { | 2809 | { |
2823 | m_log.Warn("[SCENE]: exception when trying to remove the prim that crossed the border."); | 2810 | if (grp == null) |
2824 | } | 2811 | return; |
2825 | return; | 2812 | if (grp.IsDeleted) |
2826 | } | 2813 | return; |
2827 | 2814 | ||
2828 | if (grp.RootPart.RETURN_AT_EDGE) | 2815 | if (grp.RootPart.DIE_AT_EDGE) |
2829 | { | 2816 | { |
2830 | // We remove the object here | 2817 | // We remove the object here |
2831 | try | 2818 | try |
2832 | { | 2819 | { |
2833 | List<SceneObjectGroup> objects = new List<SceneObjectGroup>(); | 2820 | DeleteSceneObject(grp, false); |
2834 | objects.Add(grp); | 2821 | } |
2835 | SceneObjectGroup[] objectsArray = objects.ToArray(); | 2822 | catch (Exception) |
2836 | returnObjects(objectsArray, UUID.Zero); | 2823 | { |
2837 | } | 2824 | m_log.Warn("[SCENE]: exception when trying to remove the prim that crossed the border."); |
2838 | catch (Exception) | 2825 | } |
2839 | { | 2826 | return; |
2840 | m_log.Warn("[SCENE]: exception when trying to return the prim that crossed the border."); | 2827 | } |
2841 | } | ||
2842 | return; | ||
2843 | } | ||
2844 | 2828 | ||
2845 | if (EntityTransferModule != null) | 2829 | if (grp.RootPart.RETURN_AT_EDGE) |
2846 | EntityTransferModule.Cross(grp, attemptedPosition, silent); | 2830 | { |
2847 | } | 2831 | // We remove the object here |
2848 | */ | 2832 | try |
2833 | { | ||
2834 | List<SceneObjectGroup> objects = new List<SceneObjectGroup>(); | ||
2835 | objects.Add(grp); | ||
2836 | SceneObjectGroup[] objectsArray = objects.ToArray(); | ||
2837 | returnObjects(objectsArray, UUID.Zero); | ||
2838 | } | ||
2839 | catch (Exception) | ||
2840 | { | ||
2841 | m_log.Warn("[SCENE]: exception when trying to return the prim that crossed the border."); | ||
2842 | } | ||
2843 | return; | ||
2844 | } | ||
2845 | |||
2846 | if (EntityTransferModule != null) | ||
2847 | EntityTransferModule.Cross(grp, attemptedPosition, silent); | ||
2848 | } | ||
2849 | */ | ||
2849 | 2850 | ||
2850 | // Simple test to see if a position is in the current region. | 2851 | // Simple test to see if a position is in the current region. |
2851 | // This test is mostly used to see if a region crossing is necessary. | 2852 | // This test is mostly used to see if a region crossing is necessary. |