diff options
author | Diva Canto | 2013-07-21 17:38:01 -0700 |
---|---|---|
committer | Diva Canto | 2013-07-24 14:27:22 -0700 |
commit | 9ab78d412cdb61b3d5c4727002c3a8eb7f6abb7f (patch) | |
tree | f66e05ead1bd7c2667f1a48944322dc15f4ebdca /OpenSim/Region/CoreModules | |
parent | Amend previous commit. (diff) | |
download | opensim-SC_OLD-9ab78d412cdb61b3d5c4727002c3a8eb7f6abb7f.zip opensim-SC_OLD-9ab78d412cdb61b3d5c4727002c3a8eb7f6abb7f.tar.gz opensim-SC_OLD-9ab78d412cdb61b3d5c4727002c3a8eb7f6abb7f.tar.bz2 opensim-SC_OLD-9ab78d412cdb61b3d5c4727002c3a8eb7f6abb7f.tar.xz |
EXPERIMENTAL: yet another variation of ES/EAC/TPFinish
Diffstat (limited to 'OpenSim/Region/CoreModules')
-rw-r--r-- | OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | 78 |
1 files changed, 39 insertions, 39 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index 344c8d7..3e7575b 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |||
@@ -744,30 +744,30 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
744 | #endregion | 744 | #endregion |
745 | capsPath = finalDestination.ServerURI + CapsUtil.GetCapsSeedPath(agentCircuit.CapsPath); | 745 | capsPath = finalDestination.ServerURI + CapsUtil.GetCapsSeedPath(agentCircuit.CapsPath); |
746 | 746 | ||
747 | if (m_eqModule != null) | 747 | //if (m_eqModule != null) |
748 | { | 748 | //{ |
749 | // The EnableSimulator message makes the client establish a connection with the destination | 749 | // // The EnableSimulator message makes the client establish a connection with the destination |
750 | // simulator by sending the initial UseCircuitCode UDP packet to the destination containing the | 750 | // // simulator by sending the initial UseCircuitCode UDP packet to the destination containing the |
751 | // correct circuit code. | 751 | // // correct circuit code. |
752 | m_eqModule.EnableSimulator(destinationHandle, endPoint, sp.UUID); | 752 | // m_eqModule.EnableSimulator(destinationHandle, endPoint, sp.UUID); |
753 | 753 | ||
754 | // XXX: Is this wait necessary? We will always end up waiting on UpdateAgent for the destination | 754 | // // XXX: Is this wait necessary? We will always end up waiting on UpdateAgent for the destination |
755 | // simulator to confirm that it has established communication with the viewer. | 755 | // // simulator to confirm that it has established communication with the viewer. |
756 | Thread.Sleep(200); | 756 | // Thread.Sleep(200); |
757 | 757 | ||
758 | // At least on LL 3.3.4 for teleports between different regions on the same simulator this appears | 758 | // // At least on LL 3.3.4 for teleports between different regions on the same simulator this appears |
759 | // unnecessary - teleport will succeed and SEED caps will be requested without it (though possibly | 759 | // // unnecessary - teleport will succeed and SEED caps will be requested without it (though possibly |
760 | // only on TeleportFinish). This is untested for region teleport between different simulators | 760 | // // only on TeleportFinish). This is untested for region teleport between different simulators |
761 | // though this probably also works. | 761 | // // though this probably also works. |
762 | m_eqModule.EstablishAgentCommunication(sp.UUID, endPoint, capsPath); | 762 | // m_eqModule.EstablishAgentCommunication(sp.UUID, endPoint, capsPath); |
763 | } | 763 | //} |
764 | else | 764 | //else |
765 | { | 765 | //{ |
766 | // XXX: This is a little misleading since we're information the client of its avatar destination, | 766 | // // XXX: This is a little misleading since we're information the client of its avatar destination, |
767 | // which may or may not be a neighbour region of the source region. This path is probably little | 767 | // // which may or may not be a neighbour region of the source region. This path is probably little |
768 | // used anyway (with EQ being the one used). But it is currently being used for test code. | 768 | // // used anyway (with EQ being the one used). But it is currently being used for test code. |
769 | sp.ControllingClient.InformClientOfNeighbour(destinationHandle, endPoint); | 769 | // sp.ControllingClient.InformClientOfNeighbour(destinationHandle, endPoint); |
770 | } | 770 | //} |
771 | } | 771 | } |
772 | else | 772 | else |
773 | { | 773 | { |
@@ -796,6 +796,21 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
796 | return; | 796 | return; |
797 | } | 797 | } |
798 | 798 | ||
799 | // We need to set this here to avoid an unlikely race condition when teleporting to a neighbour simulator, | ||
800 | // where that neighbour simulator could otherwise request a child agent create on the source which then | ||
801 | // closes our existing agent which is still signalled as root. | ||
802 | sp.IsChildAgent = true; | ||
803 | |||
804 | if (m_eqModule != null) | ||
805 | { | ||
806 | m_eqModule.TeleportFinishEvent(destinationHandle, 13, endPoint, 0, teleportFlags, capsPath, sp.UUID); | ||
807 | } | ||
808 | else | ||
809 | { | ||
810 | sp.ControllingClient.SendRegionTeleport(destinationHandle, 13, endPoint, 4, | ||
811 | teleportFlags, capsPath); | ||
812 | } | ||
813 | |||
799 | // A common teleport failure occurs when we can send CreateAgent to the | 814 | // A common teleport failure occurs when we can send CreateAgent to the |
800 | // destination region but the viewer cannot establish the connection (e.g. due to network issues between | 815 | // destination region but the viewer cannot establish the connection (e.g. due to network issues between |
801 | // the viewer and the destination). In this case, UpdateAgent timesout after 10 seconds, although then | 816 | // the viewer and the destination). In this case, UpdateAgent timesout after 10 seconds, although then |
@@ -838,21 +853,6 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
838 | "[ENTITY TRANSFER MODULE]: Sending new CAPS seed url {0} from {1} to {2}", | 853 | "[ENTITY TRANSFER MODULE]: Sending new CAPS seed url {0} from {1} to {2}", |
839 | capsPath, sp.Scene.RegionInfo.RegionName, sp.Name); | 854 | capsPath, sp.Scene.RegionInfo.RegionName, sp.Name); |
840 | 855 | ||
841 | // We need to set this here to avoid an unlikely race condition when teleporting to a neighbour simulator, | ||
842 | // where that neighbour simulator could otherwise request a child agent create on the source which then | ||
843 | // closes our existing agent which is still signalled as root. | ||
844 | sp.IsChildAgent = true; | ||
845 | |||
846 | if (m_eqModule != null) | ||
847 | { | ||
848 | m_eqModule.TeleportFinishEvent(destinationHandle, 13, endPoint, 0, teleportFlags, capsPath, sp.UUID); | ||
849 | } | ||
850 | else | ||
851 | { | ||
852 | sp.ControllingClient.SendRegionTeleport(destinationHandle, 13, endPoint, 4, | ||
853 | teleportFlags, capsPath); | ||
854 | } | ||
855 | |||
856 | // TeleportFinish makes the client send CompleteMovementIntoRegion (at the destination), which | 856 | // TeleportFinish makes the client send CompleteMovementIntoRegion (at the destination), which |
857 | // trigers a whole shebang of things there, including MakeRoot. So let's wait for confirmation | 857 | // trigers a whole shebang of things there, including MakeRoot. So let's wait for confirmation |
858 | // that the client contacted the destination before we close things here. | 858 | // that the client contacted the destination before we close things here. |