diff options
author | UbitUmarov | 2016-12-07 04:56:35 +0000 |
---|---|---|
committer | UbitUmarov | 2016-12-07 04:56:35 +0000 |
commit | 9042aa89683e690c42d27482964368edae9a6b84 (patch) | |
tree | 35eb4b568766377c2b333b0f05d3b5f3ab2baed6 /OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |
parent | set HasGridUserTried on usercache of NPCs (diff) | |
download | opensim-SC_OLD-9042aa89683e690c42d27482964368edae9a6b84.zip opensim-SC_OLD-9042aa89683e690c42d27482964368edae9a6b84.tar.gz opensim-SC_OLD-9042aa89683e690c42d27482964368edae9a6b84.tar.bz2 opensim-SC_OLD-9042aa89683e690c42d27482964368edae9a6b84.tar.xz |
add missing sp Intransit control
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | 28 |
1 files changed, 18 insertions, 10 deletions
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs index a7105e2..ad094b4 100644 --- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs +++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs | |||
@@ -776,6 +776,8 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
776 | else if (sp.Flying) | 776 | else if (sp.Flying) |
777 | teleportFlags |= (uint)TeleportFlags.IsFlying; | 777 | teleportFlags |= (uint)TeleportFlags.IsFlying; |
778 | 778 | ||
779 | sp.IsInTransit = true; | ||
780 | |||
779 | if (DisableInterRegionTeleportCancellation) | 781 | if (DisableInterRegionTeleportCancellation) |
780 | teleportFlags |= (uint)TeleportFlags.DisableCancel; | 782 | teleportFlags |= (uint)TeleportFlags.DisableCancel; |
781 | 783 | ||
@@ -878,7 +880,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
878 | sp.Name, sp.Scene.RegionInfo.RegionName, finalDestination.RegionName, reason); | 880 | sp.Name, sp.Scene.RegionInfo.RegionName, finalDestination.RegionName, reason); |
879 | 881 | ||
880 | sp.ControllingClient.SendTeleportFailed(reason); | 882 | sp.ControllingClient.SendTeleportFailed(reason); |
881 | 883 | sp.IsInTransit = false; | |
882 | return; | 884 | return; |
883 | } | 885 | } |
884 | 886 | ||
@@ -889,7 +891,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
889 | m_log.DebugFormat( | 891 | m_log.DebugFormat( |
890 | "[ENTITY TRANSFER MODULE]: Cancelled teleport of {0} to {1} from {2} after CreateAgent on client request", | 892 | "[ENTITY TRANSFER MODULE]: Cancelled teleport of {0} to {1} from {2} after CreateAgent on client request", |
891 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 893 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
892 | 894 | sp.IsInTransit = false; | |
893 | return; | 895 | return; |
894 | } | 896 | } |
895 | else if (m_entityTransferStateMachine.GetAgentTransferState(sp.UUID) == AgentTransferState.Aborting) | 897 | else if (m_entityTransferStateMachine.GetAgentTransferState(sp.UUID) == AgentTransferState.Aborting) |
@@ -899,7 +901,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
899 | m_log.DebugFormat( | 901 | m_log.DebugFormat( |
900 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after CreateAgent due to previous client close.", | 902 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after CreateAgent due to previous client close.", |
901 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 903 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
902 | 904 | sp.IsInTransit = false; | |
903 | return; | 905 | return; |
904 | } | 906 | } |
905 | 907 | ||
@@ -960,7 +962,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
960 | m_log.DebugFormat( | 962 | m_log.DebugFormat( |
961 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} before UpdateAgent", | 963 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} before UpdateAgent", |
962 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 964 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
963 | 965 | sp.IsInTransit = false; | |
964 | return; | 966 | return; |
965 | } | 967 | } |
966 | 968 | ||
@@ -977,7 +979,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
977 | m_log.DebugFormat( | 979 | m_log.DebugFormat( |
978 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after UpdateAgent due to previous client close.", | 980 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after UpdateAgent due to previous client close.", |
979 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 981 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
980 | 982 | sp.IsInTransit = false; | |
981 | return; | 983 | return; |
982 | } | 984 | } |
983 | 985 | ||
@@ -986,6 +988,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
986 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 988 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
987 | 989 | ||
988 | Fail(sp, finalDestination, logout, currentAgentCircuit.SessionID.ToString(), "Connection between viewer and destination region could not be established."); | 990 | Fail(sp, finalDestination, logout, currentAgentCircuit.SessionID.ToString(), "Connection between viewer and destination region could not be established."); |
991 | sp.IsInTransit = false; | ||
989 | return; | 992 | return; |
990 | } | 993 | } |
991 | 994 | ||
@@ -998,7 +1001,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
998 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 1001 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
999 | 1002 | ||
1000 | CleanupFailedInterRegionTeleport(sp, currentAgentCircuit.SessionID.ToString(), finalDestination); | 1003 | CleanupFailedInterRegionTeleport(sp, currentAgentCircuit.SessionID.ToString(), finalDestination); |
1001 | 1004 | sp.IsInTransit = false; | |
1002 | return; | 1005 | return; |
1003 | } | 1006 | } |
1004 | 1007 | ||
@@ -1035,7 +1038,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1035 | m_log.DebugFormat( | 1038 | m_log.DebugFormat( |
1036 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after WaitForAgentArrivedAtDestination due to previous client close.", | 1039 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after WaitForAgentArrivedAtDestination due to previous client close.", |
1037 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 1040 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
1038 | 1041 | sp.IsInTransit = false; | |
1039 | return; | 1042 | return; |
1040 | } | 1043 | } |
1041 | 1044 | ||
@@ -1044,7 +1047,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1044 | sp.Name, finalDestination.RegionName, sp.Scene.RegionInfo.RegionName); | 1047 | sp.Name, finalDestination.RegionName, sp.Scene.RegionInfo.RegionName); |
1045 | 1048 | ||
1046 | Fail(sp, finalDestination, logout, currentAgentCircuit.SessionID.ToString(), "Destination region did not signal teleport completion."); | 1049 | Fail(sp, finalDestination, logout, currentAgentCircuit.SessionID.ToString(), "Destination region did not signal teleport completion."); |
1047 | 1050 | sp.IsInTransit = false; | |
1048 | return; | 1051 | return; |
1049 | } | 1052 | } |
1050 | 1053 | ||
@@ -1093,6 +1096,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1093 | Thread.Sleep(500); | 1096 | Thread.Sleep(500); |
1094 | sp.Scene.CloseAgent(sp.UUID, false); | 1097 | sp.Scene.CloseAgent(sp.UUID, false); |
1095 | } | 1098 | } |
1099 | sp.IsInTransit = false; | ||
1096 | } | 1100 | } |
1097 | 1101 | ||
1098 | private void TransferAgent_V2(ScenePresence sp, AgentCircuitData agentCircuit, GridRegion reg, GridRegion finalDestination, | 1102 | private void TransferAgent_V2(ScenePresence sp, AgentCircuitData agentCircuit, GridRegion reg, GridRegion finalDestination, |
@@ -1115,7 +1119,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1115 | sp.Name, sp.Scene.RegionInfo.RegionName, finalDestination.RegionName, reason); | 1119 | sp.Name, sp.Scene.RegionInfo.RegionName, finalDestination.RegionName, reason); |
1116 | 1120 | ||
1117 | sp.ControllingClient.SendTeleportFailed(reason); | 1121 | sp.ControllingClient.SendTeleportFailed(reason); |
1118 | 1122 | sp.IsInTransit = false; | |
1119 | return; | 1123 | return; |
1120 | } | 1124 | } |
1121 | 1125 | ||
@@ -1127,6 +1131,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1127 | "[ENTITY TRANSFER MODULE]: Cancelled teleport of {0} to {1} from {2} after CreateAgent on client request", | 1131 | "[ENTITY TRANSFER MODULE]: Cancelled teleport of {0} to {1} from {2} after CreateAgent on client request", |
1128 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 1132 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
1129 | 1133 | ||
1134 | sp.IsInTransit = false; | ||
1130 | return; | 1135 | return; |
1131 | } | 1136 | } |
1132 | else if (m_entityTransferStateMachine.GetAgentTransferState(sp.UUID) == AgentTransferState.Aborting) | 1137 | else if (m_entityTransferStateMachine.GetAgentTransferState(sp.UUID) == AgentTransferState.Aborting) |
@@ -1137,6 +1142,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1137 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after CreateAgent due to previous client close.", | 1142 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after CreateAgent due to previous client close.", |
1138 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 1143 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
1139 | 1144 | ||
1145 | sp.IsInTransit = false; | ||
1140 | return; | 1146 | return; |
1141 | } | 1147 | } |
1142 | 1148 | ||
@@ -1189,7 +1195,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1189 | m_log.DebugFormat( | 1195 | m_log.DebugFormat( |
1190 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after UpdateAgent due to previous client close.", | 1196 | "[ENTITY TRANSFER MODULE]: Aborted teleport of {0} to {1} from {2} after UpdateAgent due to previous client close.", |
1191 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 1197 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
1192 | 1198 | sp.IsInTransit = false; | |
1193 | return; | 1199 | return; |
1194 | } | 1200 | } |
1195 | 1201 | ||
@@ -1198,6 +1204,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1198 | sp.Name, finalDestination.RegionName, sp.Scene.Name); | 1204 | sp.Name, finalDestination.RegionName, sp.Scene.Name); |
1199 | 1205 | ||
1200 | Fail(sp, finalDestination, logout, currentAgentCircuit.SessionID.ToString(), "Connection between viewer and destination region could not be established."); | 1206 | Fail(sp, finalDestination, logout, currentAgentCircuit.SessionID.ToString(), "Connection between viewer and destination region could not be established."); |
1207 | sp.IsInTransit = false; | ||
1201 | return; | 1208 | return; |
1202 | } | 1209 | } |
1203 | 1210 | ||
@@ -1255,6 +1262,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer | |||
1255 | sp.Reset(); | 1262 | sp.Reset(); |
1256 | } | 1263 | } |
1257 | */ | 1264 | */ |
1265 | sp.IsInTransit = false; | ||
1258 | } | 1266 | } |
1259 | 1267 | ||
1260 | /// <summary> | 1268 | /// <summary> |