From 72b8c1af1c8632b6888ebc13000cede0fced0994 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Fri, 15 Aug 2008 19:19:24 +0000 Subject: Plumb the user flags all the way through to the profile. userFlags in the database is now intepreted as follows: low byte = user flags. Next byte, low nibble: Deternines the text (Resident, Lifetime, etc) shown. No customn text support yet. --- OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | 6 +++--- .../Environment/Modules/Avatar/Profiles/AvatarProfilesModule.cs | 7 +++++-- OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs | 2 +- OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs | 2 +- 4 files changed, 10 insertions(+), 7 deletions(-) (limited to 'OpenSim/Region') diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index 212567f..8e35881 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs @@ -2041,7 +2041,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP */ } - public void SendAvatarProperties(LLUUID avatarID, string aboutText, string bornOn, string charterMember, + public void SendAvatarProperties(LLUUID avatarID, string aboutText, string bornOn, Byte[] charterMember, string flAbout, uint flags, LLUUID flImageID, LLUUID imageID, string profileURL, LLUUID partnerID) { @@ -2053,12 +2053,12 @@ namespace OpenSim.Region.ClientStack.LindenUDP else avatarReply.PropertiesData.AboutText = Helpers.StringToField(""); avatarReply.PropertiesData.BornOn = Helpers.StringToField(bornOn); - avatarReply.PropertiesData.CharterMember = Helpers.StringToField(charterMember); + avatarReply.PropertiesData.CharterMember = charterMember; if (flAbout != null) avatarReply.PropertiesData.FLAboutText = Helpers.StringToField(flAbout); else avatarReply.PropertiesData.FLAboutText = Helpers.StringToField(""); - avatarReply.PropertiesData.Flags = 0; + avatarReply.PropertiesData.Flags = flags; avatarReply.PropertiesData.FLImageID = flImageID; avatarReply.PropertiesData.ImageID = imageID; avatarReply.PropertiesData.ProfileURL = Helpers.StringToField(profileURL); diff --git a/OpenSim/Region/Environment/Modules/Avatar/Profiles/AvatarProfilesModule.cs b/OpenSim/Region/Environment/Modules/Avatar/Profiles/AvatarProfilesModule.cs index 2e2be7a..881889f 100644 --- a/OpenSim/Region/Environment/Modules/Avatar/Profiles/AvatarProfilesModule.cs +++ b/OpenSim/Region/Environment/Modules/Avatar/Profiles/AvatarProfilesModule.cs @@ -97,9 +97,12 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Profiles UserProfileData profile = m_scene.CommsManager.UserService.GetUserProfile(avatarID); if (null != profile) { + Byte[] charterMember = new Byte[1]; + charterMember[0] = (Byte)((profile.UserFlags & 0xf00) >> 8); + remoteClient.SendAvatarProperties(profile.ID, profile.AboutText, Util.ToDateTime(profile.Created).ToString(), - String.Empty, profile.FirstLifeAboutText, profile.CanDoMask, + charterMember, profile.FirstLifeAboutText, (uint)(profile.UserFlags & 0xff), profile.FirstLifeImage, profile.Image, String.Empty, partner); } else @@ -130,4 +133,4 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Profiles } } } -} \ No newline at end of file +} diff --git a/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs b/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs index fff2383..5853b87 100644 --- a/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs @@ -698,7 +698,7 @@ namespace OpenSim.Region.Environment.Modules.World.NPC { } - public void SendAvatarProperties(LLUUID avatarID, string aboutText, string bornOn, string charterMember, + public void SendAvatarProperties(LLUUID avatarID, string aboutText, string bornOn, Byte[] charterMember, string flAbout, uint flags, LLUUID flImageID, LLUUID imageID, string profileURL, LLUUID partnerID) { diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs index e6aff15..a7d2ef3 100644 --- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs +++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs @@ -698,7 +698,7 @@ namespace OpenSim.Region.Examples.SimpleModule { } - public void SendAvatarProperties(LLUUID avatarID, string aboutText, string bornOn, string charterMember, + public void SendAvatarProperties(LLUUID avatarID, string aboutText, string bornOn, Byte[] charterMember, string flAbout, uint flags, LLUUID flImageID, LLUUID imageID, string profileURL, LLUUID partnerID) { -- cgit v1.1