diff options
Diffstat (limited to 'OpenSim/Services/Interfaces')
-rw-r--r-- | OpenSim/Services/Interfaces/IAgentPreferencesService.cs | 6 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/IAuthorizationService.cs | 2 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/IAvatarService.cs | 81 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/ILibraryService.cs | 3 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/ILoginService.cs | 2 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/IPresenceService.cs | 2 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/IUserManagement.cs | 4 |
7 files changed, 48 insertions, 52 deletions
diff --git a/OpenSim/Services/Interfaces/IAgentPreferencesService.cs b/OpenSim/Services/Interfaces/IAgentPreferencesService.cs index af92326..6d2ce8f 100644 --- a/OpenSim/Services/Interfaces/IAgentPreferencesService.cs +++ b/OpenSim/Services/Interfaces/IAgentPreferencesService.cs | |||
@@ -45,7 +45,7 @@ namespace OpenSim.Services.Interfaces | |||
45 | if (kvp.ContainsKey("AccessPrefs")) | 45 | if (kvp.ContainsKey("AccessPrefs")) |
46 | AccessPrefs = kvp["AccessPrefs"]; | 46 | AccessPrefs = kvp["AccessPrefs"]; |
47 | if (kvp.ContainsKey("HoverHeight")) | 47 | if (kvp.ContainsKey("HoverHeight")) |
48 | HoverHeight = double.Parse(kvp["HoverHeight"]); | 48 | HoverHeight = float.Parse(kvp["HoverHeight"]); |
49 | if (kvp.ContainsKey("Language")) | 49 | if (kvp.ContainsKey("Language")) |
50 | Language = kvp["Language"]; | 50 | Language = kvp["Language"]; |
51 | if (kvp.ContainsKey("LanguageIsPublic")) | 51 | if (kvp.ContainsKey("LanguageIsPublic")) |
@@ -65,7 +65,7 @@ namespace OpenSim.Services.Interfaces | |||
65 | if (kvp.ContainsKey("AccessPrefs")) | 65 | if (kvp.ContainsKey("AccessPrefs")) |
66 | AccessPrefs = kvp["AccessPrefs"].ToString(); | 66 | AccessPrefs = kvp["AccessPrefs"].ToString(); |
67 | if (kvp.ContainsKey("HoverHeight")) | 67 | if (kvp.ContainsKey("HoverHeight")) |
68 | HoverHeight = double.Parse(kvp["HoverHeight"].ToString()); | 68 | HoverHeight = float.Parse(kvp["HoverHeight"].ToString()); |
69 | if (kvp.ContainsKey("Language")) | 69 | if (kvp.ContainsKey("Language")) |
70 | Language = kvp["Language"].ToString(); | 70 | Language = kvp["Language"].ToString(); |
71 | if (kvp.ContainsKey("LanguageIsPublic")) | 71 | if (kvp.ContainsKey("LanguageIsPublic")) |
@@ -95,7 +95,7 @@ namespace OpenSim.Services.Interfaces | |||
95 | public UUID PrincipalID = UUID.Zero; | 95 | public UUID PrincipalID = UUID.Zero; |
96 | public string AccessPrefs = "M"; | 96 | public string AccessPrefs = "M"; |
97 | //public int GodLevel; // *TODO: Implement GodLevel (Unused by the viewer, afaict - 6/11/2015) | 97 | //public int GodLevel; // *TODO: Implement GodLevel (Unused by the viewer, afaict - 6/11/2015) |
98 | public double HoverHeight = 0.0; | 98 | public float HoverHeight = 0.0f; |
99 | public string Language = "en-us"; | 99 | public string Language = "en-us"; |
100 | public bool LanguageIsPublic = true; | 100 | public bool LanguageIsPublic = true; |
101 | // DefaultObjectPermMasks | 101 | // DefaultObjectPermMasks |
diff --git a/OpenSim/Services/Interfaces/IAuthorizationService.cs b/OpenSim/Services/Interfaces/IAuthorizationService.cs index 1974234..1f80a74 100644 --- a/OpenSim/Services/Interfaces/IAuthorizationService.cs +++ b/OpenSim/Services/Interfaces/IAuthorizationService.cs | |||
@@ -145,4 +145,4 @@ namespace OpenSim.Services.Interfaces | |||
145 | set { m_message = value; } | 145 | set { m_message = value; } |
146 | } | 146 | } |
147 | } | 147 | } |
148 | } \ No newline at end of file | 148 | } |
diff --git a/OpenSim/Services/Interfaces/IAvatarService.cs b/OpenSim/Services/Interfaces/IAvatarService.cs index b4dc511..ef8d158 100644 --- a/OpenSim/Services/Interfaces/IAvatarService.cs +++ b/OpenSim/Services/Interfaces/IAvatarService.cs | |||
@@ -28,6 +28,7 @@ | |||
28 | using System; | 28 | using System; |
29 | using System.Collections; | 29 | using System.Collections; |
30 | using System.Collections.Generic; | 30 | using System.Collections.Generic; |
31 | using System.Text; | ||
31 | 32 | ||
32 | using OpenSim.Framework; | 33 | using OpenSim.Framework; |
33 | 34 | ||
@@ -150,7 +151,6 @@ namespace OpenSim.Services.Interfaces | |||
150 | // Wearables | 151 | // Wearables |
151 | Data["AvatarHeight"] = appearance.AvatarHeight.ToString(); | 152 | Data["AvatarHeight"] = appearance.AvatarHeight.ToString(); |
152 | 153 | ||
153 | // TODO: With COF, is this even needed? | ||
154 | for (int i = 0 ; i < AvatarWearable.LEGACY_VERSION_MAX_WEARABLES ; i++) | 154 | for (int i = 0 ; i < AvatarWearable.LEGACY_VERSION_MAX_WEARABLES ; i++) |
155 | { | 155 | { |
156 | for (int j = 0 ; j < appearance.Wearables[i].Count ; j++) | 156 | for (int j = 0 ; j < appearance.Wearables[i].Count ; j++) |
@@ -162,21 +162,18 @@ namespace OpenSim.Services.Interfaces | |||
162 | } | 162 | } |
163 | } | 163 | } |
164 | 164 | ||
165 | // Visual Params | ||
166 | //string[] vps = new string[AvatarAppearance.VISUALPARAM_COUNT]; | ||
167 | //byte[] binary = appearance.VisualParams; | ||
168 | |||
169 | // for (int i = 0 ; i < AvatarAppearance.VISUALPARAM_COUNT ; i++) | ||
170 | |||
171 | byte[] binary = appearance.VisualParams; | 165 | byte[] binary = appearance.VisualParams; |
172 | string[] vps = new string[binary.Length]; | 166 | int len = binary.Length; |
167 | int last = len - 1; | ||
173 | 168 | ||
174 | for (int i = 0; i < binary.Length; i++) | 169 | StringBuilder sb = new StringBuilder(5 * len); |
170 | for (int i = 0; i < len; i++) | ||
175 | { | 171 | { |
176 | vps[i] = binary[i].ToString(); | 172 | sb.Append(binary[i].ToString()); |
173 | if (i < last) | ||
174 | sb.Append(","); | ||
177 | } | 175 | } |
178 | 176 | Data["VisualParams"] = sb.ToString(); | |
179 | Data["VisualParams"] = String.Join(",", vps); | ||
180 | 177 | ||
181 | // Attachments | 178 | // Attachments |
182 | List<AvatarAttachment> attachments = appearance.GetAttachments(); | 179 | List<AvatarAttachment> attachments = appearance.GetAttachments(); |
@@ -213,7 +210,6 @@ namespace OpenSim.Services.Interfaces | |||
213 | if( h == 0f) | 210 | if( h == 0f) |
214 | h = 1.9f; | 211 | h = 1.9f; |
215 | appearance.SetSize(new Vector3(0.45f, 0.6f, h )); | 212 | appearance.SetSize(new Vector3(0.45f, 0.6f, h )); |
216 | // appearance.AvatarHeight = float.Parse(Data["AvatarHeight"]); | ||
217 | } | 213 | } |
218 | 214 | ||
219 | // Legacy Wearables | 215 | // Legacy Wearables |
@@ -285,9 +281,6 @@ namespace OpenSim.Services.Interfaces | |||
285 | if (Data.ContainsKey("VisualParams")) | 281 | if (Data.ContainsKey("VisualParams")) |
286 | { | 282 | { |
287 | string[] vps = Data["VisualParams"].Split(new char[] {','}); | 283 | string[] vps = Data["VisualParams"].Split(new char[] {','}); |
288 | //byte[] binary = new byte[AvatarAppearance.VISUALPARAM_COUNT]; | ||
289 | |||
290 | //for (int i = 0 ; i < vps.Length && i < binary.Length ; i++) | ||
291 | byte[] binary = new byte[vps.Length]; | 284 | byte[] binary = new byte[vps.Length]; |
292 | 285 | ||
293 | for (int i = 0; i < vps.Length; i++) | 286 | for (int i = 0; i < vps.Length; i++) |
@@ -296,10 +289,12 @@ namespace OpenSim.Services.Interfaces | |||
296 | appearance.VisualParams = binary; | 289 | appearance.VisualParams = binary; |
297 | } | 290 | } |
298 | 291 | ||
299 | // New style wearables | 292 | AvatarWearable[] wearables = appearance.Wearables; |
293 | int currentLength = wearables.Length; | ||
300 | foreach (KeyValuePair<string, string> _kvp in Data) | 294 | foreach (KeyValuePair<string, string> _kvp in Data) |
301 | { | 295 | { |
302 | if (_kvp.Key.StartsWith("Wearable ")) | 296 | // New style wearables |
297 | if (_kvp.Key.StartsWith("Wearable ") && _kvp.Key.Length > 9) | ||
303 | { | 298 | { |
304 | string wearIndex = _kvp.Key.Substring(9); | 299 | string wearIndex = _kvp.Key.Substring(9); |
305 | string[] wearIndices = wearIndex.Split(new char[] {':'}); | 300 | string[] wearIndices = wearIndex.Split(new char[] {':'}); |
@@ -308,33 +303,33 @@ namespace OpenSim.Services.Interfaces | |||
308 | string[] ids = _kvp.Value.Split(new char[] {':'}); | 303 | string[] ids = _kvp.Value.Split(new char[] {':'}); |
309 | UUID itemID = new UUID(ids[0]); | 304 | UUID itemID = new UUID(ids[0]); |
310 | UUID assetID = new UUID(ids[1]); | 305 | UUID assetID = new UUID(ids[1]); |
311 | 306 | if (index >= currentLength) | |
312 | appearance.Wearables[index].Add(itemID, assetID); | 307 | { |
313 | } | 308 | Array.Resize(ref wearables, index + 1); |
314 | } | 309 | for (int i = currentLength ; i < wearables.Length ; i++) |
315 | 310 | wearables[i] = new AvatarWearable(); | |
316 | // Attachments | 311 | currentLength = wearables.Length; |
317 | Dictionary<string, string> attchs = new Dictionary<string, string>(); | 312 | } |
318 | foreach (KeyValuePair<string, string> _kvp in Data) | 313 | wearables[index].Add(itemID, assetID); |
319 | if (_kvp.Key.StartsWith("_ap_")) | ||
320 | attchs[_kvp.Key] = _kvp.Value; | ||
321 | |||
322 | foreach (KeyValuePair<string, string> _kvp in attchs) | ||
323 | { | ||
324 | string pointStr = _kvp.Key.Substring(4); | ||
325 | int point = 0; | ||
326 | if (!Int32.TryParse(pointStr, out point)) | ||
327 | continue; | 314 | continue; |
328 | 315 | } | |
329 | List<string> idList = new List<string>(_kvp.Value.Split(new char[] {','})); | 316 | // Attachments |
330 | 317 | if (_kvp.Key.StartsWith("_ap_") && _kvp.Key.Length > 4) | |
331 | appearance.SetAttachment(point, UUID.Zero, UUID.Zero); | ||
332 | foreach (string id in idList) | ||
333 | { | 318 | { |
334 | UUID uuid = UUID.Zero; | 319 | string pointStr = _kvp.Key.Substring(4); |
335 | UUID.TryParse(id, out uuid); | 320 | int point = 0; |
336 | 321 | if (Int32.TryParse(pointStr, out point)) | |
337 | appearance.SetAttachment(point | 0x80, uuid, UUID.Zero); | 322 | { |
323 | List<string> idList = new List<string>(_kvp.Value.Split(new char[] {','})); | ||
324 | |||
325 | appearance.SetAttachment(point, UUID.Zero, UUID.Zero); | ||
326 | foreach (string id in idList) | ||
327 | { | ||
328 | UUID uuid = UUID.Zero; | ||
329 | if(UUID.TryParse(id, out uuid)) | ||
330 | appearance.SetAttachment(point | 0x80, uuid, UUID.Zero); | ||
331 | } | ||
332 | } | ||
338 | } | 333 | } |
339 | } | 334 | } |
340 | 335 | ||
diff --git a/OpenSim/Services/Interfaces/ILibraryService.cs b/OpenSim/Services/Interfaces/ILibraryService.cs index 861cf0e..ea914da 100644 --- a/OpenSim/Services/Interfaces/ILibraryService.cs +++ b/OpenSim/Services/Interfaces/ILibraryService.cs | |||
@@ -38,6 +38,7 @@ namespace OpenSim.Services.Interfaces | |||
38 | InventoryFolderImpl LibraryRootFolder { get; } | 38 | InventoryFolderImpl LibraryRootFolder { get; } |
39 | 39 | ||
40 | Dictionary<UUID, InventoryFolderImpl> GetAllFolders(); | 40 | Dictionary<UUID, InventoryFolderImpl> GetAllFolders(); |
41 | InventoryItemBase GetItem(UUID itemID); | ||
42 | InventoryItemBase[] GetMultipleItems(UUID[] itemIDs); | ||
41 | } | 43 | } |
42 | |||
43 | } | 44 | } |
diff --git a/OpenSim/Services/Interfaces/ILoginService.cs b/OpenSim/Services/Interfaces/ILoginService.cs index 7c44cd8..c37e666 100644 --- a/OpenSim/Services/Interfaces/ILoginService.cs +++ b/OpenSim/Services/Interfaces/ILoginService.cs | |||
@@ -48,7 +48,7 @@ namespace OpenSim.Services.Interfaces | |||
48 | public interface ILoginService | 48 | public interface ILoginService |
49 | { | 49 | { |
50 | LoginResponse Login(string firstName, string lastName, string passwd, string startLocation, UUID scopeID, | 50 | LoginResponse Login(string firstName, string lastName, string passwd, string startLocation, UUID scopeID, |
51 | string clientVersion, string channel, string mac, string id0, IPEndPoint clientIP, bool LibOMVclient); | 51 | string clientVersion, string channel, string mac, string id0, IPEndPoint clientIP); |
52 | Hashtable SetLevel(string firstName, string lastName, string passwd, int level, IPEndPoint clientIP); | 52 | Hashtable SetLevel(string firstName, string lastName, string passwd, int level, IPEndPoint clientIP); |
53 | } | 53 | } |
54 | 54 | ||
diff --git a/OpenSim/Services/Interfaces/IPresenceService.cs b/OpenSim/Services/Interfaces/IPresenceService.cs index 4843759..b235f1e 100644 --- a/OpenSim/Services/Interfaces/IPresenceService.cs +++ b/OpenSim/Services/Interfaces/IPresenceService.cs | |||
@@ -117,4 +117,4 @@ namespace OpenSim.Services.Interfaces | |||
117 | /// <param name='userIDs'></param> | 117 | /// <param name='userIDs'></param> |
118 | PresenceInfo[] GetAgents(string[] userIDs); | 118 | PresenceInfo[] GetAgents(string[] userIDs); |
119 | } | 119 | } |
120 | } \ No newline at end of file | 120 | } |
diff --git a/OpenSim/Services/Interfaces/IUserManagement.cs b/OpenSim/Services/Interfaces/IUserManagement.cs index 91b344e..39268c0 100644 --- a/OpenSim/Services/Interfaces/IUserManagement.cs +++ b/OpenSim/Services/Interfaces/IUserManagement.cs | |||
@@ -42,7 +42,7 @@ namespace OpenSim.Services.Interfaces | |||
42 | string GetUserUUI(UUID uuid); | 42 | string GetUserUUI(UUID uuid); |
43 | bool GetUserUUI(UUID userID, out string uui); | 43 | bool GetUserUUI(UUID userID, out string uui); |
44 | string GetUserServerURL(UUID uuid, string serverType); | 44 | string GetUserServerURL(UUID uuid, string serverType); |
45 | Dictionary<UUID,string> GetUsersNames(string[] ids); | 45 | Dictionary<UUID,string> GetUsersNames(string[] ids, UUID scopeID); |
46 | 46 | ||
47 | /// <summary> | 47 | /// <summary> |
48 | /// Get user ID by the given name. | 48 | /// Get user ID by the given name. |
@@ -92,7 +92,7 @@ namespace OpenSim.Services.Interfaces | |||
92 | /// <param name="firstName"></param> | 92 | /// <param name="firstName"></param> |
93 | /// <param name="profileURL"></param> | 93 | /// <param name="profileURL"></param> |
94 | void AddUser(UUID uuid, string firstName, string lastName, string homeURL); | 94 | void AddUser(UUID uuid, string firstName, string lastName, string homeURL); |
95 | 95 | bool RemoveUser(UUID uuid); | |
96 | bool IsLocalGridUser(UUID uuid); | 96 | bool IsLocalGridUser(UUID uuid); |
97 | } | 97 | } |
98 | } | 98 | } |