From 2b42ea0a429c722bd7c5c67d3815c2ddc8399e78 Mon Sep 17 00:00:00 2001 From: MW Date: Wed, 25 Jul 2007 18:19:38 +0000 Subject: Start of the OpenSim library , for now only contains a few textures. --- .../Communications/CommunicationsManager.cs | 25 ++++++++++++++-------- 1 file changed, 16 insertions(+), 9 deletions(-) (limited to 'OpenSim/Framework/Communications/CommunicationsManager.cs') diff --git a/OpenSim/Framework/Communications/CommunicationsManager.cs b/OpenSim/Framework/Communications/CommunicationsManager.cs index e220e17..ac882ba 100644 --- a/OpenSim/Framework/Communications/CommunicationsManager.cs +++ b/OpenSim/Framework/Communications/CommunicationsManager.cs @@ -44,7 +44,7 @@ namespace OpenSim.Framework.Communications public IGridServices GridServer; public IInventoryServices InventoryServer; public IInterRegionCommunications InterRegion; - public UserProfileCache UserProfilesCache; + public UserProfileCache UserProfiles; public AssetCache AssetCache; public NetworkServersInfo ServersInfo; @@ -52,21 +52,28 @@ namespace OpenSim.Framework.Communications { ServersInfo = serversInfo; this.AssetCache = assetCache; - UserProfilesCache = new UserProfileCache(this); + UserProfiles = new UserProfileCache(this); } #region Packet Handlers public void HandleUUIDNameRequest(LLUUID uuid, IClientAPI remote_client) { - UserProfileData profileData = this.UserServer.GetUserProfile(uuid); - if (profileData != null) + if (uuid == UserProfiles.libraryRoot.agentID) { - LLUUID profileId = profileData.UUID; - string firstname = profileData.username; - string lastname = profileData.surname; + remote_client.SendNameReply(uuid , "Mr" , "OpenSim"); + } + else + { + UserProfileData profileData = this.UserServer.GetUserProfile(uuid); + if (profileData != null) + { + LLUUID profileId = profileData.UUID; + string firstname = profileData.username; + string lastname = profileData.surname; - remote_client.SendNameReply(profileId, firstname, lastname); - } + remote_client.SendNameReply(profileId, firstname, lastname); + } + } } #endregion -- cgit v1.1