diff options
author | Teravus Ovares | 2008-01-01 06:12:04 +0000 |
---|---|---|
committer | Teravus Ovares | 2008-01-01 06:12:04 +0000 |
commit | b4c9b6bd19c0725ae5bf60172db75ebc63ba72c6 (patch) | |
tree | d7e9e370371edbcbebb8436791ba8b1cd940ab69 /OpenSim/Region/Communications/Local/LocalLoginService.cs | |
parent | Make it possible for new inventory 'libraries' to be added without changing t... (diff) | |
download | opensim-SC-b4c9b6bd19c0725ae5bf60172db75ebc63ba72c6.zip opensim-SC-b4c9b6bd19c0725ae5bf60172db75ebc63ba72c6.tar.gz opensim-SC-b4c9b6bd19c0725ae5bf60172db75ebc63ba72c6.tar.bz2 opensim-SC-b4c9b6bd19c0725ae5bf60172db75ebc63ba72c6.tar.xz |
* You can add and remove a friend in standalone now within the same simulator. It saves.
* You can add and remove a friend in grid mode now within the same simulator. It doesn't save yet.
* I got rid of Mr. OpenSim as a friend.. he bothers me /:b...
Diffstat (limited to 'OpenSim/Region/Communications/Local/LocalLoginService.cs')
-rw-r--r-- | OpenSim/Region/Communications/Local/LocalLoginService.cs | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/OpenSim/Region/Communications/Local/LocalLoginService.cs b/OpenSim/Region/Communications/Local/LocalLoginService.cs index 0fb86af..2c92491 100644 --- a/OpenSim/Region/Communications/Local/LocalLoginService.cs +++ b/OpenSim/Region/Communications/Local/LocalLoginService.cs | |||
@@ -138,8 +138,8 @@ namespace OpenSim.Region.Communications.Local | |||
138 | theUser.currentAgent.currentHandle = reg.RegionHandle; | 138 | theUser.currentAgent.currentHandle = reg.RegionHandle; |
139 | 139 | ||
140 | LoginResponse.BuddyList buddyList = new LoginResponse.BuddyList(); | 140 | LoginResponse.BuddyList buddyList = new LoginResponse.BuddyList(); |
141 | buddyList.AddNewBuddy(new LoginResponse.BuddyList.BuddyInfo("11111111-1111-0000-0000-000100bba000")); | 141 | |
142 | response.BuddList = buddyList; | 142 | response.BuddList = ConvertFriendListItem(m_userManager.GetUserFriendList(theUser.UUID)); |
143 | 143 | ||
144 | Login _login = new Login(); | 144 | Login _login = new Login(); |
145 | //copy data to login object | 145 | //copy data to login object |
@@ -162,7 +162,20 @@ namespace OpenSim.Region.Communications.Local | |||
162 | MainLog.Instance.Warn("LOGIN", "Not found region " + currentRegion); | 162 | MainLog.Instance.Warn("LOGIN", "Not found region " + currentRegion); |
163 | } | 163 | } |
164 | } | 164 | } |
165 | private LoginResponse.BuddyList ConvertFriendListItem(List<FriendListItem> LFL) | ||
166 | { | ||
167 | LoginResponse.BuddyList buddylistreturn = new LoginResponse.BuddyList(); | ||
168 | foreach (FriendListItem fl in LFL) | ||
169 | { | ||
170 | LoginResponse.BuddyList.BuddyInfo buddyitem = new LoginResponse.BuddyList.BuddyInfo(fl.Friend); | ||
171 | buddyitem.BuddyID = fl.Friend; | ||
172 | buddyitem.BuddyRightsHave = (int)fl.FriendListOwnerPerms; | ||
173 | buddyitem.BuddyRightsGiven = (int)fl.FriendPerms; | ||
174 | buddylistreturn.AddNewBuddy(buddyitem); | ||
165 | 175 | ||
176 | } | ||
177 | return buddylistreturn; | ||
178 | } | ||
166 | protected override InventoryData CreateInventoryData(LLUUID userID) | 179 | protected override InventoryData CreateInventoryData(LLUUID userID) |
167 | { | 180 | { |
168 | List<InventoryFolderBase> folders = m_Parent.InventoryService.RequestFirstLevelFolders(userID); | 181 | List<InventoryFolderBase> folders = m_Parent.InventoryService.RequestFirstLevelFolders(userID); |
@@ -207,6 +220,7 @@ namespace OpenSim.Region.Communications.Local | |||
207 | 220 | ||
208 | return new InventoryData(AgentInventoryArray, userInventory.InventoryRoot.FolderID); | 221 | return new InventoryData(AgentInventoryArray, userInventory.InventoryRoot.FolderID); |
209 | } | 222 | } |
223 | |||
210 | } | 224 | } |
211 | } | 225 | } |
212 | } \ No newline at end of file | 226 | } \ No newline at end of file |