aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
authorDiva Canto2010-08-16 11:33:59 -0700
committerDiva Canto2010-08-16 11:33:59 -0700
commit77de28965ae5fc6de3c60a28ce7d4e59643a2a70 (patch)
tree61259b696fb8d8a47f10cb83a72d1df145953b8f /OpenSim/Region
parentIncreased the timeout on AgentUpdate to 30 sec and improved error message to ... (diff)
downloadopensim-SC_OLD-77de28965ae5fc6de3c60a28ce7d4e59643a2a70.zip
opensim-SC_OLD-77de28965ae5fc6de3c60a28ce7d4e59643a2a70.tar.gz
opensim-SC_OLD-77de28965ae5fc6de3c60a28ce7d4e59643a2a70.tar.bz2
opensim-SC_OLD-77de28965ae5fc6de3c60a28ce7d4e59643a2a70.tar.xz
Work on TeleportStart: renamed method from TeleportLocationStart to TeleportStart, and now sending this upon all teleports, not just some, and in the right place (EntityTransferModule).
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs19
-rw-r--r--OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs10
-rw-r--r--OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs3
-rw-r--r--OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs2
-rw-r--r--OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs2
-rw-r--r--OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs2
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs1
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs2
8 files changed, 22 insertions, 19 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
index c11b9a2..bb9e6d4 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
@@ -1432,16 +1432,27 @@ namespace OpenSim.Region.ClientStack.LindenUDP
1432 /// <summary> 1432 /// <summary>
1433 /// 1433 ///
1434 /// </summary> 1434 /// </summary>
1435 public void SendTeleportLocationStart() 1435 public void SendTeleportStart(uint flags)
1436 { 1436 {
1437 //TeleportStartPacket tpStart = (TeleportStartPacket)PacketPool.Instance.GetPacket(PacketType.TeleportStart); 1437 TeleportStartPacket tpStart = (TeleportStartPacket)PacketPool.Instance.GetPacket(PacketType.TeleportStart);
1438 TeleportStartPacket tpStart = new TeleportStartPacket(); 1438 //TeleportStartPacket tpStart = new TeleportStartPacket();
1439 tpStart.Info.TeleportFlags = 16; // Teleport via location 1439 tpStart.Info.TeleportFlags = flags; //16; // Teleport via location
1440 1440
1441 // Hack to get this out immediately and skip throttles 1441 // Hack to get this out immediately and skip throttles
1442 OutPacket(tpStart, ThrottleOutPacketType.Unknown); 1442 OutPacket(tpStart, ThrottleOutPacketType.Unknown);
1443 } 1443 }
1444 1444
1445 public void SendTeleportProgress(uint flags, string message)
1446 {
1447 TeleportProgressPacket tpProgress = (TeleportProgressPacket)PacketPool.Instance.GetPacket(PacketType.TeleportProgress);
1448 tpProgress.AgentData.AgentID = this.AgentId;
1449 tpProgress.Info.TeleportFlags = flags;
1450 tpProgress.Info.Message = Util.StringToBytes256(message);
1451
1452 // Hack to get this out immediately and skip throttles
1453 OutPacket(tpProgress, ThrottleOutPacketType.Unknown);
1454 }
1455
1445 public void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance) 1456 public void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance)
1446 { 1457 {
1447 MoneyBalanceReplyPacket money = (MoneyBalanceReplyPacket)PacketPool.Instance.GetPacket(PacketType.MoneyBalanceReply); 1458 MoneyBalanceReplyPacket money = (MoneyBalanceReplyPacket)PacketPool.Instance.GetPacket(PacketType.MoneyBalanceReply);
diff --git a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
index 607219e..751d49a 100644
--- a/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
+++ b/OpenSim/Region/CoreModules/Framework/EntityTransfer/EntityTransferModule.cs
@@ -174,9 +174,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
174 position.Z = newPosZ; 174 position.Z = newPosZ;
175 } 175 }
176 176
177 // Only send this if the event queue is null 177 sp.ControllingClient.SendTeleportStart(teleportFlags);
178 if (eq == null)
179 sp.ControllingClient.SendTeleportLocationStart();
180 178
181 sp.ControllingClient.SendLocalTeleport(position, lookAt, teleportFlags); 179 sp.ControllingClient.SendLocalTeleport(position, lookAt, teleportFlags);
182 sp.Teleport(position); 180 sp.Teleport(position);
@@ -257,9 +255,6 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
257 255
258 ulong destinationHandle = finalDestination.RegionHandle; 256 ulong destinationHandle = finalDestination.RegionHandle;
259 257
260 if (eq == null)
261 sp.ControllingClient.SendTeleportLocationStart();
262
263 // Let's do DNS resolution only once in this process, please! 258 // Let's do DNS resolution only once in this process, please!
264 // This may be a costly operation. The reg.ExternalEndPoint field is not a passive field, 259 // This may be a costly operation. The reg.ExternalEndPoint field is not a passive field,
265 // it's actually doing a lot of work. 260 // it's actually doing a lot of work.
@@ -277,6 +272,8 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
277 return; 272 return;
278 } 273 }
279 274
275 sp.ControllingClient.SendTeleportStart(teleportFlags);
276
280 // the avatar.Close below will clear the child region list. We need this below for (possibly) 277 // the avatar.Close below will clear the child region list. We need this below for (possibly)
281 // closing the child agents, so save it here (we need a copy as it is Clear()-ed). 278 // closing the child agents, so save it here (we need a copy as it is Clear()-ed).
282 //List<ulong> childRegions = new List<ulong>(avatar.GetKnownRegionList()); 279 //List<ulong> childRegions = new List<ulong>(avatar.GetKnownRegionList());
@@ -320,6 +317,7 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
320 317
321 if (NeedsNewAgent(oldRegionX, newRegionX, oldRegionY, newRegionY)) 318 if (NeedsNewAgent(oldRegionX, newRegionX, oldRegionY, newRegionY))
322 { 319 {
320
323 #region IP Translation for NAT 321 #region IP Translation for NAT
324 IClientIPEndpoint ipepClient; 322 IClientIPEndpoint ipepClient;
325 if (sp.ClientView.TryGet(out ipepClient)) 323 if (sp.ClientView.TryGet(out ipepClient))
diff --git a/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs b/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs
index 940b535..51f2c41 100644
--- a/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs
+++ b/OpenSim/Region/CoreModules/World/Estate/EstateManagementModule.cs
@@ -343,7 +343,6 @@ namespace OpenSim.Region.CoreModules.World.Estate
343 { 343 {
344 if (!s.IsChildAgent) 344 if (!s.IsChildAgent)
345 { 345 {
346 s.ControllingClient.SendTeleportLocationStart();
347 m_scene.TeleportClientHome(user, s.ControllingClient); 346 m_scene.TeleportClientHome(user, s.ControllingClient);
348 } 347 }
349 } 348 }
@@ -478,7 +477,6 @@ namespace OpenSim.Region.CoreModules.World.Estate
478 ScenePresence s = m_scene.GetScenePresence(prey); 477 ScenePresence s = m_scene.GetScenePresence(prey);
479 if (s != null) 478 if (s != null)
480 { 479 {
481 s.ControllingClient.SendTeleportLocationStart();
482 m_scene.TeleportClientHome(prey, s.ControllingClient); 480 m_scene.TeleportClientHome(prey, s.ControllingClient);
483 } 481 }
484 } 482 }
@@ -498,7 +496,6 @@ namespace OpenSim.Region.CoreModules.World.Estate
498 // Also make sure they are actually in the region 496 // Also make sure they are actually in the region
499 if (p != null && !p.IsChildAgent) 497 if (p != null && !p.IsChildAgent)
500 { 498 {
501 p.ControllingClient.SendTeleportLocationStart();
502 m_scene.TeleportClientHome(p.UUID, p.ControllingClient); 499 m_scene.TeleportClientHome(p.UUID, p.ControllingClient);
503 } 500 }
504 } 501 }
diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs
index f6e6163..3f5aa46 100644
--- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs
+++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs
@@ -520,7 +520,7 @@ namespace OpenSim.Region.Examples.SimpleModule
520 { 520 {
521 } 521 }
522 522
523 public virtual void SendTeleportLocationStart() 523 public virtual void SendTeleportStart(uint flags)
524 { 524 {
525 } 525 }
526 526
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
index ee7aa2da..19bb002 100644
--- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
+++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs
@@ -1035,7 +1035,7 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server
1035 1035
1036 } 1036 }
1037 1037
1038 public void SendTeleportLocationStart() 1038 public void SendTeleportStart(uint flags)
1039 { 1039 {
1040 1040
1041 } 1041 }
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
index 2e0450c..944bac6 100644
--- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
+++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs
@@ -611,7 +611,7 @@ namespace OpenSim.Region.OptionalModules.World.NPC
611 { 611 {
612 } 612 }
613 613
614 public virtual void SendTeleportLocationStart() 614 public virtual void SendTeleportStart(uint flags)
615 { 615 {
616 } 616 }
617 617
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
index 32e46ec..b21e532 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs
@@ -4070,7 +4070,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
4070 if (m_host.OwnerID == World.LandChannel.GetLandObject( 4070 if (m_host.OwnerID == World.LandChannel.GetLandObject(
4071 presence.AbsolutePosition.X, presence.AbsolutePosition.Y).LandData.OwnerID) 4071 presence.AbsolutePosition.X, presence.AbsolutePosition.Y).LandData.OwnerID)
4072 { 4072 {
4073 presence.ControllingClient.SendTeleportLocationStart();
4074 World.TeleportClientHome(agentId, presence.ControllingClient); 4073 World.TeleportClientHome(agentId, presence.ControllingClient);
4075 } 4074 }
4076 } 4075 }
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
index 01b64eb..a529a94 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
@@ -664,7 +664,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
664 regionName = regInfo.RegionName; 664 regionName = regInfo.RegionName;
665 } 665 }
666 } 666 }
667 presence.ControllingClient.SendTeleportLocationStart();
668 World.RequestTeleportLocation(presence.ControllingClient, regionName, 667 World.RequestTeleportLocation(presence.ControllingClient, regionName,
669 new Vector3((float)position.x, (float)position.y, (float)position.z), 668 new Vector3((float)position.x, (float)position.y, (float)position.z),
670 new Vector3((float)lookat.x, (float)lookat.y, (float)lookat.z), (uint)TPFlags.ViaLocation); 669 new Vector3((float)lookat.x, (float)lookat.y, (float)lookat.z), (uint)TPFlags.ViaLocation);
@@ -696,7 +695,6 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
696 == World.LandChannel.GetLandObject( 695 == World.LandChannel.GetLandObject(
697 presence.AbsolutePosition.X, presence.AbsolutePosition.Y).LandData.OwnerID) 696 presence.AbsolutePosition.X, presence.AbsolutePosition.Y).LandData.OwnerID)
698 { 697 {
699 presence.ControllingClient.SendTeleportLocationStart();
700 World.RequestTeleportLocation(presence.ControllingClient, regionHandle, 698 World.RequestTeleportLocation(presence.ControllingClient, regionHandle,
701 new Vector3((float)position.x, (float)position.y, (float)position.z), 699 new Vector3((float)position.x, (float)position.y, (float)position.z),
702 new Vector3((float)lookat.x, (float)lookat.y, (float)lookat.z), (uint)TPFlags.ViaLocation); 700 new Vector3((float)lookat.x, (float)lookat.y, (float)lookat.z), (uint)TPFlags.ViaLocation);