diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 54 |
1 files changed, 2 insertions, 52 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 7e6f942..171f066 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -2623,48 +2623,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
2623 | return false; | 2623 | return false; |
2624 | } | 2624 | } |
2625 | 2625 | ||
2626 | // If the user is banned, we won't let any of their objects | 2626 | if (!EntityTransferModule.HandleIncomingSceneObject(newObject, newPosition)) |
2627 | // enter. Period. | 2627 | return false; |
2628 | // | ||
2629 | if (RegionInfo.EstateSettings.IsBanned(newObject.OwnerID)) | ||
2630 | { | ||
2631 | m_log.InfoFormat("[INTERREGION]: Denied prim crossing for banned avatar {0}", newObject.OwnerID); | ||
2632 | return false; | ||
2633 | } | ||
2634 | |||
2635 | if (newPosition != Vector3.Zero) | ||
2636 | newObject.RootPart.GroupPosition = newPosition; | ||
2637 | |||
2638 | if (!AddSceneObject(newObject)) | ||
2639 | { | ||
2640 | m_log.DebugFormat( | ||
2641 | "[INTERREGION]: Problem adding scene object {0} in {1} ", newObject.UUID, RegionInfo.RegionName); | ||
2642 | return false; | ||
2643 | } | ||
2644 | |||
2645 | if (!newObject.IsAttachment) | ||
2646 | { | ||
2647 | // FIXME: It would be better to never add the scene object at all rather than add it and then delete | ||
2648 | // it | ||
2649 | if (!Permissions.CanObjectEntry(newObject.UUID, true, newObject.AbsolutePosition)) | ||
2650 | { | ||
2651 | // Deny non attachments based on parcel settings | ||
2652 | // | ||
2653 | m_log.Info("[INTERREGION]: Denied prim crossing because of parcel settings"); | ||
2654 | |||
2655 | DeleteSceneObject(newObject, false); | ||
2656 | |||
2657 | return false; | ||
2658 | } | ||
2659 | |||
2660 | // For attachments, we need to wait until the agent is root | ||
2661 | // before we restart the scripts, or else some functions won't work. | ||
2662 | newObject.RootPart.ParentGroup.CreateScriptInstances(0, false, DefaultScriptEngine, GetStateSource(newObject)); | ||
2663 | newObject.ResumeScripts(); | ||
2664 | |||
2665 | if (newObject.RootPart.KeyframeMotion != null) | ||
2666 | newObject.RootPart.KeyframeMotion.UpdateSceneObject(newObject); | ||
2667 | } | ||
2668 | 2628 | ||
2669 | // Do this as late as possible so that listeners have full access to the incoming object | 2629 | // Do this as late as possible so that listeners have full access to the incoming object |
2670 | EventManager.TriggerOnIncomingSceneObject(newObject); | 2630 | EventManager.TriggerOnIncomingSceneObject(newObject); |
@@ -2733,16 +2693,6 @@ namespace OpenSim.Region.Framework.Scenes | |||
2733 | return true; | 2693 | return true; |
2734 | } | 2694 | } |
2735 | 2695 | ||
2736 | private int GetStateSource(SceneObjectGroup sog) | ||
2737 | { | ||
2738 | ScenePresence sp = GetScenePresence(sog.OwnerID); | ||
2739 | |||
2740 | if (sp != null) | ||
2741 | return sp.GetStateSource(); | ||
2742 | |||
2743 | return 2; // StateSource.PrimCrossing | ||
2744 | } | ||
2745 | |||
2746 | #endregion | 2696 | #endregion |
2747 | 2697 | ||
2748 | #region Add/Remove Avatar Methods | 2698 | #region Add/Remove Avatar Methods |