diff options
Diffstat (limited to 'OpenSim/Region')
-rw-r--r-- | OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs | 26 |
1 files changed, 9 insertions, 17 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs b/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs index 48bb2df..5a648a3 100644 --- a/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/UserProfiles/UserProfileModule.cs | |||
@@ -671,7 +671,7 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
671 | 671 | ||
672 | // Pull the rabbit out of the hat | 672 | // Pull the rabbit out of the hat |
673 | remoteClient.SendPickInfoReply(pick.PickId,pick.CreatorId,pick.TopPick,pick.ParcelId,pick.Name, | 673 | remoteClient.SendPickInfoReply(pick.PickId,pick.CreatorId,pick.TopPick,pick.ParcelId,pick.Name, |
674 | pick.Desc,pick.SnapshotId,pick.User,pick.OriginalName,pick.SimName, | 674 | pick.Desc,pick.SnapshotId,pick.ParcelName,pick.OriginalName,pick.SimName, |
675 | globalPos,pick.SortOrder,pick.Enabled); | 675 | globalPos,pick.SortOrder,pick.Enabled); |
676 | } | 676 | } |
677 | 677 | ||
@@ -721,24 +721,16 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
721 | remoteClient.Scene.RegionInfo.WorldLocY + avaPos.Y, | 721 | remoteClient.Scene.RegionInfo.WorldLocY + avaPos.Y, |
722 | avaPos.Z); | 722 | avaPos.Z); |
723 | 723 | ||
724 | string landOwnerName = string.Empty; | 724 | string landParcelName = "My Parcel"; |
725 | UUID landParcelID = p.currentParcelUUID; | ||
726 | |||
725 | ILandObject land = p.Scene.LandChannel.GetLandObject(avaPos.X, avaPos.Y); | 727 | ILandObject land = p.Scene.LandChannel.GetLandObject(avaPos.X, avaPos.Y); |
726 | 728 | ||
727 | if (land != null) | 729 | if (land != null) |
728 | { | 730 | { |
729 | if (land.LandData.IsGroupOwned) | 731 | // If land found, use parcel uuid from here because the value from SP will be blank if the avatar hasnt moved |
730 | { | 732 | landParcelName = land.LandData.Name; |
731 | IGroupsModule groupMod = p.Scene.RequestModuleInterface<IGroupsModule>(); | 733 | landParcelID = land.LandData.GlobalID; |
732 | UUID groupId = land.LandData.GroupID; | ||
733 | GroupRecord groupRecord = groupMod.GetGroupRecord(groupId); | ||
734 | landOwnerName = groupRecord.GroupName; | ||
735 | } | ||
736 | else | ||
737 | { | ||
738 | IUserAccountService accounts = p.Scene.RequestModuleInterface<IUserAccountService>(); | ||
739 | UserAccount user = accounts.GetUserAccount(p.Scene.RegionInfo.ScopeID, land.LandData.OwnerID); | ||
740 | landOwnerName = user.Name; | ||
741 | } | ||
742 | } | 734 | } |
743 | else | 735 | else |
744 | { | 736 | { |
@@ -753,9 +745,9 @@ namespace OpenSim.Region.CoreModules.Avatar.UserProfiles | |||
753 | pick.TopPick = topPick; | 745 | pick.TopPick = topPick; |
754 | pick.Name = name; | 746 | pick.Name = name; |
755 | pick.Desc = desc; | 747 | pick.Desc = desc; |
756 | pick.ParcelId = p.currentParcelUUID; | 748 | pick.ParcelId = landParcelID; |
757 | pick.SnapshotId = snapshotID; | 749 | pick.SnapshotId = snapshotID; |
758 | pick.User = landOwnerName; | 750 | pick.ParcelName = landParcelName; |
759 | pick.SimName = remoteClient.Scene.RegionInfo.RegionName; | 751 | pick.SimName = remoteClient.Scene.RegionInfo.RegionName; |
760 | pick.Gatekeeper = MyGatekeeper; | 752 | pick.Gatekeeper = MyGatekeeper; |
761 | pick.GlobalPos = posGlobal.ToString(); | 753 | pick.GlobalPos = posGlobal.ToString(); |