From ac79ff8dc605c6b1cee4316e5648902d123206e7 Mon Sep 17 00:00:00 2001 From: Adam Frisby Date: Sun, 24 May 2009 01:36:13 +0000 Subject: * Adds NAT routing support for MXP Asset Delivery. (This means MXP should be fully NAT compatible.) --- OpenSim/Client/MXP/PacketHandler/MXPPacketServer.cs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'OpenSim/Client/MXP') diff --git a/OpenSim/Client/MXP/PacketHandler/MXPPacketServer.cs b/OpenSim/Client/MXP/PacketHandler/MXPPacketServer.cs index 2f60810..7eab7c5 100644 --- a/OpenSim/Client/MXP/PacketHandler/MXPPacketServer.cs +++ b/OpenSim/Client/MXP/PacketHandler/MXPPacketServer.cs @@ -450,11 +450,18 @@ namespace OpenSim.Client.MXP.PacketHandler joinResponseMessage.RequestMessageId = joinRequestMessage.MessageId; joinResponseMessage.FailureCode = MxpResponseCodes.SUCCESS; - + joinResponseMessage.BubbleId = joinRequestMessage.BubbleId; joinResponseMessage.ParticipantId = userId.Guid; joinResponseMessage.AvatarId = userId.Guid; - joinResponseMessage.BubbleAssetCacheUrl = "http://"+m_scenes[new UUID(joinRequestMessage.BubbleId)].RegionInfo.ExternalHostName+":"+m_scenes[new UUID(joinRequestMessage.BubbleId)].RegionInfo.HttpPort+"/assets/"; + joinResponseMessage.BubbleAssetCacheUrl = "http://" + + NetworkUtil.GetHostFor(session.RemoteEndPoint.Address, + m_scenes[ + new UUID(joinRequestMessage.BubbleId)]. + RegionInfo. + ExternalHostName) + ":" + + m_scenes[new UUID(joinRequestMessage.BubbleId)].RegionInfo. + HttpPort + "/assets/"; joinResponseMessage.BubbleName = m_scenes[new UUID(joinRequestMessage.BubbleId)].RegionInfo.RegionName; -- cgit v1.1