diff options
author | Melanie | 2010-03-09 22:46:17 +0000 |
---|---|---|
committer | Melanie | 2010-03-09 22:46:17 +0000 |
commit | 40873504dcde19a3738cf4d3a4928a59b811e8f0 (patch) | |
tree | 605d2c2575e21496b05eeabd0a5755b8fa788efd /OpenSim | |
parent | - parcel blocking, region crossing blocking, teleport blocking (diff) | |
parent | Merge branch 'master' of melanie@opensimulator.org:/var/git/opensim (diff) | |
download | opensim-SC-40873504dcde19a3738cf4d3a4928a59b811e8f0.zip opensim-SC-40873504dcde19a3738cf4d3a4928a59b811e8f0.tar.gz opensim-SC-40873504dcde19a3738cf4d3a4928a59b811e8f0.tar.bz2 opensim-SC-40873504dcde19a3738cf4d3a4928a59b811e8f0.tar.xz |
Merge branch 'master' into careminster-presence-refactor
Diffstat (limited to 'OpenSim')
38 files changed, 347 insertions, 53 deletions
diff --git a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs index f8cfe44..17bd795 100644 --- a/OpenSim/Client/MXP/ClientStack/MXPClientView.cs +++ b/OpenSim/Client/MXP/ClientStack/MXPClientView.cs | |||
@@ -1711,5 +1711,9 @@ namespace OpenSim.Client.MXP.ClientStack | |||
1711 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) | 1711 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) |
1712 | { | 1712 | { |
1713 | } | 1713 | } |
1714 | |||
1715 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
1716 | { | ||
1717 | } | ||
1714 | } | 1718 | } |
1715 | } | 1719 | } |
diff --git a/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs b/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs index 3bf73d6..b199b93 100644 --- a/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs +++ b/OpenSim/Client/Sirikata/ClientStack/SirikataClientView.cs | |||
@@ -1200,6 +1200,10 @@ namespace OpenSim.Client.Sirikata.ClientStack | |||
1200 | { | 1200 | { |
1201 | } | 1201 | } |
1202 | 1202 | ||
1203 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
1204 | { | ||
1205 | } | ||
1206 | |||
1203 | #endregion | 1207 | #endregion |
1204 | } | 1208 | } |
1205 | } | 1209 | } |
diff --git a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs index 894fdac..1da746a 100644 --- a/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs +++ b/OpenSim/Client/VWoHTTP/ClientStack/VWHClientView.cs | |||
@@ -1215,5 +1215,9 @@ namespace OpenSim.Client.VWoHTTP.ClientStack | |||
1215 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) | 1215 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) |
1216 | { | 1216 | { |
1217 | } | 1217 | } |
1218 | |||
1219 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
1220 | { | ||
1221 | } | ||
1218 | } | 1222 | } |
1219 | } | 1223 | } |
diff --git a/OpenSim/Data/MSSQL/MSSQLFriendsData.cs b/OpenSim/Data/MSSQL/MSSQLFriendsData.cs index 34da943..af4fd9b 100644 --- a/OpenSim/Data/MSSQL/MSSQLFriendsData.cs +++ b/OpenSim/Data/MSSQL/MSSQLFriendsData.cs | |||
@@ -72,7 +72,7 @@ namespace OpenSim.Data.MSSQL | |||
72 | using (SqlCommand cmd = new SqlCommand()) | 72 | using (SqlCommand cmd = new SqlCommand()) |
73 | { | 73 | { |
74 | 74 | ||
75 | cmd.CommandText = String.Format("select a.*,b.Flags as TheirFlags from {0} as a left join {0} as b on a.PrincipalID = b.Friend and a.Friend = b.PrincipalID where a.PrincipalID = ?PrincipalID and b.Flags is not null", m_Realm); | 75 | cmd.CommandText = String.Format("select a.*,case when b.Flags is null then -1 else b.Flags end as TheirFlags from {0} as a left join {0} as b on a.PrincipalID = b.Friend and a.Friend = b.PrincipalID where a.PrincipalID = @PrincipalID", m_Realm); |
76 | cmd.Parameters.Add(m_database.CreateParameter("@PrincipalID", principalID.ToString())); | 76 | cmd.Parameters.Add(m_database.CreateParameter("@PrincipalID", principalID.ToString())); |
77 | cmd.Connection = conn; | 77 | cmd.Connection = conn; |
78 | conn.Open(); | 78 | conn.Open(); |
diff --git a/OpenSim/Data/MSSQL/MSSQLGridUserData.cs b/OpenSim/Data/MSSQL/MSSQLGridUserData.cs new file mode 100644 index 0000000..b4a945c --- /dev/null +++ b/OpenSim/Data/MSSQL/MSSQLGridUserData.cs | |||
@@ -0,0 +1,68 @@ | |||
1 | /* | ||
2 | * Copyright (c) Contributors, http://opensimulator.org/ | ||
3 | * See CONTRIBUTORS.TXT for a full list of copyright holders. | ||
4 | * | ||
5 | * Redistribution and use in source and binary forms, with or without | ||
6 | * modification, are permitted provided that the following conditions are met: | ||
7 | * * Redistributions of source code must retain the above copyright | ||
8 | * notice, this list of conditions and the following disclaimer. | ||
9 | * * Redistributions in binary form must reproduce the above copyright | ||
10 | * notice, this list of conditions and the following disclaimer in the | ||
11 | * documentation and/or other materials provided with the distribution. | ||
12 | * * Neither the name of the OpenSimulator Project nor the | ||
13 | * names of its contributors may be used to endorse or promote products | ||
14 | * derived from this software without specific prior written permission. | ||
15 | * | ||
16 | * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY | ||
17 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | ||
18 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
19 | * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY | ||
20 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES | ||
21 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | ||
22 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND | ||
23 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | ||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
26 | */ | ||
27 | |||
28 | using System; | ||
29 | using System.Collections.Generic; | ||
30 | using System.Data; | ||
31 | using System.Reflection; | ||
32 | using System.Threading; | ||
33 | using log4net; | ||
34 | using OpenMetaverse; | ||
35 | using OpenSim.Framework; | ||
36 | using System.Data.SqlClient; | ||
37 | |||
38 | namespace OpenSim.Data.MSSQL | ||
39 | { | ||
40 | /// <summary> | ||
41 | /// A MSSQL Interface for Avatar Storage | ||
42 | /// </summary> | ||
43 | public class MSSQLGridUserData : MSSQLGenericTableHandler<GridUserData>, | ||
44 | IGridUserData | ||
45 | { | ||
46 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | ||
47 | |||
48 | public MSSQLGridUserData(string connectionString, string realm) : | ||
49 | base(connectionString, realm, "UserGrid") | ||
50 | { | ||
51 | } | ||
52 | |||
53 | public GridUserData GetGridUserData(string userID) | ||
54 | { | ||
55 | GridUserData[] ret = Get("UserID", userID); | ||
56 | |||
57 | if (ret.Length == 0) | ||
58 | return null; | ||
59 | |||
60 | return ret[0]; | ||
61 | } | ||
62 | |||
63 | public bool StoreGridUserData(GridUserData data) | ||
64 | { | ||
65 | return Store(data); | ||
66 | } | ||
67 | } | ||
68 | } | ||
diff --git a/OpenSim/Data/MSSQL/Resources/001_FriendsStore.sql b/OpenSim/Data/MSSQL/Resources/001_FriendsStore.sql index f6480f7..94d240b 100644 --- a/OpenSim/Data/MSSQL/Resources/001_FriendsStore.sql +++ b/OpenSim/Data/MSSQL/Resources/001_FriendsStore.sql | |||
@@ -2,7 +2,7 @@ BEGIN TRANSACTION | |||
2 | 2 | ||
3 | CREATE TABLE [Friends] ( | 3 | CREATE TABLE [Friends] ( |
4 | [PrincipalID] uniqueidentifier NOT NULL, | 4 | [PrincipalID] uniqueidentifier NOT NULL, |
5 | [FriendID] varchar(255) NOT NULL, | 5 | [Friend] varchar(255) NOT NULL, |
6 | [Flags] char(16) NOT NULL DEFAULT '0', | 6 | [Flags] char(16) NOT NULL DEFAULT '0', |
7 | [Offered] varchar(32) NOT NULL DEFAULT 0) | 7 | [Offered] varchar(32) NOT NULL DEFAULT 0) |
8 | ON [PRIMARY] | 8 | ON [PRIMARY] |
diff --git a/OpenSim/Data/MSSQL/Resources/001_UserAccount.sql b/OpenSim/Data/MSSQL/Resources/001_UserAccount.sql new file mode 100644 index 0000000..3dbf8a4 --- /dev/null +++ b/OpenSim/Data/MSSQL/Resources/001_UserAccount.sql | |||
@@ -0,0 +1,14 @@ | |||
1 | CREATE TABLE [UserAccounts] ( | ||
2 | [PrincipalID] uniqueidentifier NOT NULL, | ||
3 | [ScopeID] uniqueidentifier NOT NULL, | ||
4 | [FirstName] [varchar](64) NOT NULL, | ||
5 | [LastName] [varchar](64) NOT NULL, | ||
6 | [Email] [varchar](64) NULL, | ||
7 | [ServiceURLs] [text] NULL, | ||
8 | [Created] [int] default NULL, | ||
9 | |||
10 | PRIMARY KEY CLUSTERED | ||
11 | ( | ||
12 | [PrincipalID] ASC | ||
13 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] | ||
14 | ) ON [PRIMARY] | ||
diff --git a/OpenSim/Data/MSSQL/Resources/002_FriendsStore.sql b/OpenSim/Data/MSSQL/Resources/002_FriendsStore.sql index 7762a26..e67d20e 100644 --- a/OpenSim/Data/MSSQL/Resources/002_FriendsStore.sql +++ b/OpenSim/Data/MSSQL/Resources/002_FriendsStore.sql | |||
@@ -1,6 +1,6 @@ | |||
1 | BEGIN TRANSACTION | 1 | BEGIN TRANSACTION |
2 | 2 | ||
3 | INSERT INTO Friends (PrincipalID, FriendID, Flags, Offered) SELECT [ownerID], [friendID], [friendPerms], 0 FROM userfriends; | 3 | INSERT INTO Friends (PrincipalID, Friend, Flags, Offered) SELECT [ownerID], [friendID], [friendPerms], 0 FROM userfriends; |
4 | 4 | ||
5 | 5 | ||
6 | COMMIT \ No newline at end of file | 6 | COMMIT \ No newline at end of file |
diff --git a/OpenSim/Data/MSSQL/Resources/003_UserAccount.sql b/OpenSim/Data/MSSQL/Resources/003_UserAccount.sql new file mode 100644 index 0000000..da0395b --- /dev/null +++ b/OpenSim/Data/MSSQL/Resources/003_UserAccount.sql | |||
@@ -0,0 +1,9 @@ | |||
1 | BEGIN TRANSACTION | ||
2 | |||
3 | CREATE UNIQUE INDEX PrincipalID ON UserAccounts(PrincipalID); | ||
4 | CREATE INDEX Email ON UserAccounts(Email); | ||
5 | CREATE INDEX FirstName ON UserAccounts(FirstName); | ||
6 | CREATE INDEX LastName ON UserAccounts(LastName); | ||
7 | CREATE INDEX Name ON UserAccounts(FirstName,LastName); | ||
8 | |||
9 | COMMIT \ No newline at end of file | ||
diff --git a/OpenSim/Data/MSSQL/Resources/004_UserAccount.sql b/OpenSim/Data/MSSQL/Resources/004_UserAccount.sql new file mode 100644 index 0000000..a9a9021 --- /dev/null +++ b/OpenSim/Data/MSSQL/Resources/004_UserAccount.sql | |||
@@ -0,0 +1,7 @@ | |||
1 | BEGIN TRANSACTION | ||
2 | |||
3 | ALTER TABLE UserAccounts ADD UserLevel integer NOT NULL DEFAULT 0; | ||
4 | ALTER TABLE UserAccounts ADD UserFlags integer NOT NULL DEFAULT 0; | ||
5 | ALTER TABLE UserAccounts ADD UserTitle varchar(64) NOT NULL DEFAULT ''; | ||
6 | |||
7 | COMMIT \ No newline at end of file | ||
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index 3126e57..4577758 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs | |||
@@ -1480,5 +1480,6 @@ namespace OpenSim.Framework | |||
1480 | void SendGroupTransactionsSummaryDetails(IClientAPI sender,UUID groupID, UUID transactionID, UUID sessionID,int amt); | 1480 | void SendGroupTransactionsSummaryDetails(IClientAPI sender,UUID groupID, UUID transactionID, UUID sessionID,int amt); |
1481 | 1481 | ||
1482 | void SendChangeUserRights(UUID agentID, UUID friendID, int rights); | 1482 | void SendChangeUserRights(UUID agentID, UUID friendID, int rights); |
1483 | void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId); | ||
1483 | } | 1484 | } |
1484 | } | 1485 | } |
diff --git a/OpenSim/Framework/IScene.cs b/OpenSim/Framework/IScene.cs index 27b3d47..86d63f8 100644 --- a/OpenSim/Framework/IScene.cs +++ b/OpenSim/Framework/IScene.cs | |||
@@ -91,6 +91,8 @@ namespace OpenSim.Framework | |||
91 | /// </exception> | 91 | /// </exception> |
92 | bool PresenceChildStatus(UUID agentId); | 92 | bool PresenceChildStatus(UUID agentId); |
93 | 93 | ||
94 | bool TryGetAvatar(UUID agentID, out object scenePresence); | ||
95 | |||
94 | T RequestModuleInterface<T>(); | 96 | T RequestModuleInterface<T>(); |
95 | T[] RequestModuleInterfaces<T>(); | 97 | T[] RequestModuleInterfaces<T>(); |
96 | 98 | ||
diff --git a/OpenSim/Framework/SLUtil.cs b/OpenSim/Framework/SLUtil.cs index 81d82be..2fc5bdf 100644 --- a/OpenSim/Framework/SLUtil.cs +++ b/OpenSim/Framework/SLUtil.cs | |||
@@ -59,6 +59,20 @@ namespace OpenSim.Framework | |||
59 | return "application/vnd.ll.gesture"; | 59 | return "application/vnd.ll.gesture"; |
60 | case AssetType.Simstate: | 60 | case AssetType.Simstate: |
61 | return "application/x-metaverse-simstate"; | 61 | return "application/x-metaverse-simstate"; |
62 | case AssetType.FavoriteFolder: | ||
63 | return "application/vnd.ll.favoritefolder"; | ||
64 | case AssetType.Link: | ||
65 | return "application/vnd.ll.link"; | ||
66 | case AssetType.LinkFolder: | ||
67 | return "application/vnd.ll.linkfolder"; | ||
68 | case AssetType.CurrentOutfitFolder: | ||
69 | return "application/vnd.ll.currentoutfitfolder"; | ||
70 | case AssetType.OutfitFolder: | ||
71 | return "application/vnd.ll.outfitfolder"; | ||
72 | case AssetType.MyOutfitsFolder: | ||
73 | return "application/vnd.ll.myoutfitsfolder"; | ||
74 | case AssetType.InboxFolder: | ||
75 | return "application/vnd.ll.inboxfolder"; | ||
62 | case AssetType.Unknown: | 76 | case AssetType.Unknown: |
63 | default: | 77 | default: |
64 | return "application/octet-stream"; | 78 | return "application/octet-stream"; |
@@ -123,6 +137,20 @@ namespace OpenSim.Framework | |||
123 | return (sbyte)AssetType.Gesture; | 137 | return (sbyte)AssetType.Gesture; |
124 | case "application/x-metaverse-simstate": | 138 | case "application/x-metaverse-simstate": |
125 | return (sbyte)AssetType.Simstate; | 139 | return (sbyte)AssetType.Simstate; |
140 | case "application/vnd.ll.favoritefolder": | ||
141 | return (sbyte)AssetType.FavoriteFolder; | ||
142 | case "application/vnd.ll.link": | ||
143 | return (sbyte)AssetType.Link; | ||
144 | case "application/vnd.ll.linkfolder": | ||
145 | return (sbyte)AssetType.LinkFolder; | ||
146 | case "application/vnd.ll.currentoutfitfolder": | ||
147 | return (sbyte)AssetType.CurrentOutfitFolder; | ||
148 | case "application/vnd.ll.outfitfolder": | ||
149 | return (sbyte)AssetType.OutfitFolder; | ||
150 | case "application/vnd.ll.myoutfitsfolder": | ||
151 | return (sbyte)AssetType.MyOutfitsFolder; | ||
152 | case "application/vnd.ll.inboxfolder": | ||
153 | return (sbyte)AssetType.InboxFolder; | ||
126 | case "application/octet-stream": | 154 | case "application/octet-stream": |
127 | default: | 155 | default: |
128 | return (sbyte)AssetType.Unknown; | 156 | return (sbyte)AssetType.Unknown; |
diff --git a/OpenSim/Framework/Util.cs b/OpenSim/Framework/Util.cs index 0ccc193..8cb9127 100644 --- a/OpenSim/Framework/Util.cs +++ b/OpenSim/Framework/Util.cs | |||
@@ -29,6 +29,7 @@ using System; | |||
29 | using System.Collections; | 29 | using System.Collections; |
30 | using System.Collections.Generic; | 30 | using System.Collections.Generic; |
31 | using System.Data; | 31 | using System.Data; |
32 | using System.Diagnostics; | ||
32 | using System.Globalization; | 33 | using System.Globalization; |
33 | using System.IO; | 34 | using System.IO; |
34 | using System.IO.Compression; | 35 | using System.IO.Compression; |
@@ -1443,6 +1444,7 @@ namespace OpenSim.Framework | |||
1443 | } | 1444 | } |
1444 | 1445 | ||
1445 | #endregion FireAndForget Threading Pattern | 1446 | #endregion FireAndForget Threading Pattern |
1447 | |||
1446 | /// <summary> | 1448 | /// <summary> |
1447 | /// Environment.TickCount is an int but it counts all 32 bits so it goes positive | 1449 | /// Environment.TickCount is an int but it counts all 32 bits so it goes positive |
1448 | /// and negative every 24.9 days. This trims down TickCount so it doesn't wrap | 1450 | /// and negative every 24.9 days. This trims down TickCount so it doesn't wrap |
@@ -1467,5 +1469,21 @@ namespace OpenSim.Framework | |||
1467 | Int32 diff = EnvironmentTickCount() - prevValue; | 1469 | Int32 diff = EnvironmentTickCount() - prevValue; |
1468 | return (diff >= 0) ? diff : (diff + EnvironmentTickCountMask + 1); | 1470 | return (diff >= 0) ? diff : (diff + EnvironmentTickCountMask + 1); |
1469 | } | 1471 | } |
1472 | |||
1473 | /// <summary> | ||
1474 | /// Prints the call stack at any given point. Useful for debugging. | ||
1475 | /// </summary> | ||
1476 | public static void PrintCallStack() | ||
1477 | { | ||
1478 | StackTrace stackTrace = new StackTrace(); // get call stack | ||
1479 | StackFrame[] stackFrames = stackTrace.GetFrames(); // get method calls (frames) | ||
1480 | |||
1481 | // write call stack method names | ||
1482 | foreach (StackFrame stackFrame in stackFrames) | ||
1483 | { | ||
1484 | m_log.Debug(stackFrame.GetMethod().DeclaringType + "." + stackFrame.GetMethod().Name); // write method name | ||
1485 | } | ||
1486 | } | ||
1487 | |||
1470 | } | 1488 | } |
1471 | } | 1489 | } |
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index ea73abb..8cd47fb 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | |||
@@ -11621,5 +11621,25 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
11621 | 11621 | ||
11622 | OutPacket(packet, ThrottleOutPacketType.Task); | 11622 | OutPacket(packet, ThrottleOutPacketType.Task); |
11623 | } | 11623 | } |
11624 | |||
11625 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
11626 | { | ||
11627 | ScriptDialogPacket dialog = (ScriptDialogPacket)PacketPool.Instance.GetPacket(PacketType.ScriptDialog); | ||
11628 | dialog.Data.ObjectID = objectId; | ||
11629 | dialog.Data.ChatChannel = chatChannel; | ||
11630 | dialog.Data.ImageID = UUID.Zero; | ||
11631 | dialog.Data.ObjectName = Util.StringToBytes256(objectname); | ||
11632 | // this is the username of the *owner* | ||
11633 | dialog.Data.FirstName = Util.StringToBytes256(ownerFirstName); | ||
11634 | dialog.Data.LastName = Util.StringToBytes256(ownerLastName); | ||
11635 | dialog.Data.Message = Util.StringToBytes256(message); | ||
11636 | |||
11637 | |||
11638 | ScriptDialogPacket.ButtonsBlock[] buttons = new ScriptDialogPacket.ButtonsBlock[1]; | ||
11639 | buttons[0] = new ScriptDialogPacket.ButtonsBlock(); | ||
11640 | buttons[0].ButtonLabel = Util.StringToBytes256("!!llTextBox!!"); | ||
11641 | dialog.Buttons = buttons; | ||
11642 | OutPacket(dialog, ThrottleOutPacketType.Task); | ||
11643 | } | ||
11624 | } | 11644 | } |
11625 | } | 11645 | } |
diff --git a/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs b/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs index 50c83b5..1386e86 100644 --- a/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs +++ b/OpenSim/Region/CoreModules/Agent/TextureSender/J2KDecoderModule.cs | |||
@@ -60,6 +60,8 @@ namespace OpenSim.Region.CoreModules.Agent.TextureSender | |||
60 | 60 | ||
61 | #region IRegionModule | 61 | #region IRegionModule |
62 | 62 | ||
63 | private bool m_useCSJ2K = true; | ||
64 | |||
63 | public string Name { get { return "J2KDecoderModule"; } } | 65 | public string Name { get { return "J2KDecoderModule"; } } |
64 | public bool IsSharedModule { get { return true; } } | 66 | public bool IsSharedModule { get { return true; } } |
65 | 67 | ||
@@ -73,6 +75,12 @@ namespace OpenSim.Region.CoreModules.Agent.TextureSender | |||
73 | m_scene = scene; | 75 | m_scene = scene; |
74 | 76 | ||
75 | scene.RegisterModuleInterface<IJ2KDecoder>(this); | 77 | scene.RegisterModuleInterface<IJ2KDecoder>(this); |
78 | |||
79 | IConfig startupConfig = source.Configs["Startup"]; | ||
80 | if (startupConfig != null) | ||
81 | { | ||
82 | m_useCSJ2K = startupConfig.GetBoolean("UseCSJ2K", m_useCSJ2K); | ||
83 | } | ||
76 | } | 84 | } |
77 | 85 | ||
78 | public void PostInitialise() | 86 | public void PostInitialise() |
@@ -144,41 +152,52 @@ namespace OpenSim.Region.CoreModules.Agent.TextureSender | |||
144 | /// <param name="j2kData">JPEG2000 data</param> | 152 | /// <param name="j2kData">JPEG2000 data</param> |
145 | private void DoJ2KDecode(UUID assetID, byte[] j2kData) | 153 | private void DoJ2KDecode(UUID assetID, byte[] j2kData) |
146 | { | 154 | { |
147 | // int DecodeTime = 0; | 155 | //int DecodeTime = 0; |
148 | // DecodeTime = Environment.TickCount; | 156 | //DecodeTime = Environment.TickCount; |
149 | OpenJPEG.J2KLayerInfo[] layers; | 157 | OpenJPEG.J2KLayerInfo[] layers; |
150 | 158 | ||
151 | if (!TryLoadCacheForAsset(assetID, out layers)) | 159 | if (!TryLoadCacheForAsset(assetID, out layers)) |
152 | { | 160 | { |
153 | try | 161 | if (m_useCSJ2K) |
154 | { | 162 | { |
155 | List<int> layerStarts = CSJ2K.J2kImage.GetLayerBoundaries(new MemoryStream(j2kData)); | 163 | try |
156 | |||
157 | if (layerStarts != null && layerStarts.Count > 0) | ||
158 | { | 164 | { |
159 | layers = new OpenJPEG.J2KLayerInfo[layerStarts.Count]; | 165 | List<int> layerStarts = CSJ2K.J2kImage.GetLayerBoundaries(new MemoryStream(j2kData)); |
160 | 166 | ||
161 | for (int i = 0; i < layerStarts.Count; i++) | 167 | if (layerStarts != null && layerStarts.Count > 0) |
162 | { | 168 | { |
163 | OpenJPEG.J2KLayerInfo layer = new OpenJPEG.J2KLayerInfo(); | 169 | layers = new OpenJPEG.J2KLayerInfo[layerStarts.Count]; |
170 | |||
171 | for (int i = 0; i < layerStarts.Count; i++) | ||
172 | { | ||
173 | OpenJPEG.J2KLayerInfo layer = new OpenJPEG.J2KLayerInfo(); | ||
164 | 174 | ||
165 | if (i == 0) | 175 | if (i == 0) |
166 | layer.Start = 0; | 176 | layer.Start = 0; |
167 | else | 177 | else |
168 | layer.Start = layerStarts[i]; | 178 | layer.Start = layerStarts[i]; |
169 | 179 | ||
170 | if (i == layerStarts.Count - 1) | 180 | if (i == layerStarts.Count - 1) |
171 | layer.End = j2kData.Length; | 181 | layer.End = j2kData.Length; |
172 | else | 182 | else |
173 | layer.End = layerStarts[i + 1] - 1; | 183 | layer.End = layerStarts[i + 1] - 1; |
174 | 184 | ||
175 | layers[i] = layer; | 185 | layers[i] = layer; |
186 | } | ||
176 | } | 187 | } |
177 | } | 188 | } |
189 | catch (Exception ex) | ||
190 | { | ||
191 | m_log.Warn("[J2KDecoderModule]: CSJ2K threw an exception decoding texture " + assetID + ": " + ex.Message); | ||
192 | } | ||
178 | } | 193 | } |
179 | catch (Exception ex) | 194 | else |
180 | { | 195 | { |
181 | m_log.Warn("[J2KDecoderModule]: CSJ2K threw an exception decoding texture " + assetID + ": " + ex.Message); | 196 | int components; |
197 | if (!OpenJPEG.DecodeLayerBoundaries(j2kData, out layers, out components)) | ||
198 | { | ||
199 | m_log.Warn("[J2KDecoderModule]: OpenJPEG failed to decode texture " + assetID); | ||
200 | } | ||
182 | } | 201 | } |
183 | 202 | ||
184 | if (layers == null || layers.Length == 0) | 203 | if (layers == null || layers.Length == 0) |
diff --git a/OpenSim/Region/CoreModules/Avatar/Dialog/DialogModule.cs b/OpenSim/Region/CoreModules/Avatar/Dialog/DialogModule.cs index fac052a..b8e013c 100644 --- a/OpenSim/Region/CoreModules/Avatar/Dialog/DialogModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/Dialog/DialogModule.cs | |||
@@ -25,6 +25,7 @@ | |||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | */ | 26 | */ |
27 | 27 | ||
28 | using System; | ||
28 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
29 | using System.Reflection; | 30 | using System.Reflection; |
30 | using log4net; | 31 | using log4net; |
@@ -151,7 +152,30 @@ namespace OpenSim.Region.CoreModules.Avatar.Dialog | |||
151 | // region as the sending avatar. | 152 | // region as the sending avatar. |
152 | SendNotificationToUsersInRegion(fromAvatarID, fromAvatarName, message); | 153 | SendNotificationToUsersInRegion(fromAvatarID, fromAvatarName, message); |
153 | } | 154 | } |
154 | 155 | ||
156 | public void SendTextBoxToUser(UUID avatarid, string message, int chatChannel, string name, UUID objectid, UUID ownerid) | ||
157 | { | ||
158 | UserAccount account = m_scene.UserAccountService.GetUserAccount(m_scene.RegionInfo.ScopeID, ownerid); | ||
159 | string ownerFirstName, ownerLastName; | ||
160 | if (account != null) | ||
161 | { | ||
162 | ownerFirstName = account.FirstName; | ||
163 | ownerLastName = account.LastName; | ||
164 | } | ||
165 | else | ||
166 | { | ||
167 | ownerFirstName = "(unknown"; | ||
168 | ownerLastName = "user)"; | ||
169 | } | ||
170 | |||
171 | |||
172 | ScenePresence sp = m_scene.GetScenePresence(avatarid); | ||
173 | |||
174 | if (sp != null) { | ||
175 | sp.ControllingClient.SendTextBoxRequest(message, chatChannel, name, ownerFirstName, ownerLastName, objectid); | ||
176 | } | ||
177 | } | ||
178 | |||
155 | public void SendNotificationToUsersInRegion( | 179 | public void SendNotificationToUsersInRegion( |
156 | UUID fromAvatarID, string fromAvatarName, string message) | 180 | UUID fromAvatarID, string fromAvatarName, string message) |
157 | { | 181 | { |
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/RemoteAssetServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/RemoteAssetServiceConnector.cs index 4eff60e..8a22cfc 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/RemoteAssetServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/RemoteAssetServiceConnector.cs | |||
@@ -69,7 +69,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Asset | |||
69 | IConfig assetConfig = source.Configs["AssetService"]; | 69 | IConfig assetConfig = source.Configs["AssetService"]; |
70 | if (assetConfig == null) | 70 | if (assetConfig == null) |
71 | { | 71 | { |
72 | m_log.Error("[ASSET CONNECTOR]: AssetService missing from OpanSim.ini"); | 72 | m_log.Error("[ASSET CONNECTOR]: AssetService missing from OpenSim.ini"); |
73 | return; | 73 | return; |
74 | } | 74 | } |
75 | 75 | ||
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Avatar/RemoteAvatarServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Avatar/RemoteAvatarServiceConnector.cs index 48759b5..d665a54 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Avatar/RemoteAvatarServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Avatar/RemoteAvatarServiceConnector.cs | |||
@@ -66,7 +66,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Avatar | |||
66 | IConfig userConfig = source.Configs["AvatarService"]; | 66 | IConfig userConfig = source.Configs["AvatarService"]; |
67 | if (userConfig == null) | 67 | if (userConfig == null) |
68 | { | 68 | { |
69 | m_log.Error("[AVATAR CONNECTOR]: AvatarService missing from OpanSim.ini"); | 69 | m_log.Error("[AVATAR CONNECTOR]: AvatarService missing from OpenSim.ini"); |
70 | return; | 70 | return; |
71 | } | 71 | } |
72 | 72 | ||
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs index 891fc14..e98df28 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Presence/PresenceDetector.cs | |||
@@ -77,23 +77,28 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Presence | |||
77 | 77 | ||
78 | public void OnNewClient(IClientAPI client) | 78 | public void OnNewClient(IClientAPI client) |
79 | { | 79 | { |
80 | client.OnLogout += OnLogout; | 80 | client.OnConnectionClosed += OnConnectionClose; |
81 | } | 81 | } |
82 | 82 | ||
83 | public void OnLogout(IClientAPI client) | 83 | public void OnConnectionClose(IClientAPI client) |
84 | { | 84 | { |
85 | client.OnLogout -= OnLogout; | 85 | if (client.IsLoggingOut) |
86 | |||
87 | ScenePresence sp = null; | ||
88 | Vector3 position = new Vector3(128, 128, 0); | ||
89 | Vector3 lookat = new Vector3(0, 1, 0); | ||
90 | |||
91 | if (m_aScene.TryGetAvatar(client.AgentId, out sp)) | ||
92 | { | 86 | { |
93 | position = sp.AbsolutePosition; | 87 | object sp = null; |
94 | lookat = sp.Lookat; | 88 | Vector3 position = new Vector3(128, 128, 0); |
89 | Vector3 lookat = new Vector3(0, 1, 0); | ||
90 | |||
91 | if (client.Scene.TryGetAvatar(client.AgentId, out sp)) | ||
92 | { | ||
93 | if (sp is ScenePresence) | ||
94 | { | ||
95 | position = ((ScenePresence)sp).AbsolutePosition; | ||
96 | lookat = ((ScenePresence)sp).Lookat; | ||
97 | } | ||
98 | } | ||
99 | |||
100 | m_PresenceService.LogoutAgent(client.SessionId, position, lookat); | ||
95 | } | 101 | } |
96 | m_PresenceService.LogoutAgent(client.SessionId, position, lookat); | ||
97 | 102 | ||
98 | } | 103 | } |
99 | } | 104 | } |
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs index e913891..783d606 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/LocalSimulationConnector.cs | |||
@@ -69,7 +69,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation | |||
69 | //IConfig userConfig = config.Configs["SimulationService"]; | 69 | //IConfig userConfig = config.Configs["SimulationService"]; |
70 | //if (userConfig == null) | 70 | //if (userConfig == null) |
71 | //{ | 71 | //{ |
72 | // m_log.Error("[AVATAR CONNECTOR]: SimulationService missing from OpanSim.ini"); | 72 | // m_log.Error("[AVATAR CONNECTOR]: SimulationService missing from OpenSim.ini"); |
73 | // return; | 73 | // return; |
74 | //} | 74 | //} |
75 | 75 | ||
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs index 2b1f815..4d82a05 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Simulation/RemoteSimulationConnector.cs | |||
@@ -74,7 +74,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Simulation | |||
74 | //IConfig userConfig = config.Configs["SimulationService"]; | 74 | //IConfig userConfig = config.Configs["SimulationService"]; |
75 | //if (userConfig == null) | 75 | //if (userConfig == null) |
76 | //{ | 76 | //{ |
77 | // m_log.Error("[AVATAR CONNECTOR]: SimulationService missing from OpanSim.ini"); | 77 | // m_log.Error("[AVATAR CONNECTOR]: SimulationService missing from OpenSim.ini"); |
78 | // return; | 78 | // return; |
79 | //} | 79 | //} |
80 | 80 | ||
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/RemoteUserAccountServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/RemoteUserAccountServiceConnector.cs index 13acdf2..1140692 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/RemoteUserAccountServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserAccounts/RemoteUserAccountServiceConnector.cs | |||
@@ -69,7 +69,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserAccounts | |||
69 | IConfig userConfig = source.Configs["UserAccountService"]; | 69 | IConfig userConfig = source.Configs["UserAccountService"]; |
70 | if (userConfig == null) | 70 | if (userConfig == null) |
71 | { | 71 | { |
72 | m_log.Error("[USER CONNECTOR]: UserAccountService missing from OpanSim.ini"); | 72 | m_log.Error("[USER CONNECTOR]: UserAccountService missing from OpenSim.ini"); |
73 | return; | 73 | return; |
74 | } | 74 | } |
75 | 75 | ||
diff --git a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs index 4652d70..2211f3e 100644 --- a/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs +++ b/OpenSim/Region/CoreModules/World/Permissions/PermissionsModule.cs | |||
@@ -609,16 +609,17 @@ namespace OpenSim.Region.CoreModules.World.Permissions | |||
609 | if (IsFriendWithPerms(user, objectOwner)) | 609 | if (IsFriendWithPerms(user, objectOwner)) |
610 | return objectOwnerMask; | 610 | return objectOwnerMask; |
611 | 611 | ||
612 | // Estate users should be able to edit anything in the sim | 612 | // Estate users should be able to edit anything in the sim if RegionOwnerIsGod is set |
613 | if (IsEstateManager(user) && m_RegionOwnerIsGod && (!IsAdministrator(objectOwner)) || objectOwner == user) | 613 | if (IsEstateManager(user) && m_RegionOwnerIsGod) |
614 | return objectOwnerMask; | 614 | return objectOwnerMask; |
615 | 615 | ||
616 | // Admin should be able to edit anything in the sim (including admin objects) | 616 | // Admin should be able to edit anything in the sim (including admin objects) |
617 | if (IsAdministrator(user)) | 617 | if (IsAdministrator(user)) |
618 | return objectOwnerMask; | 618 | return objectOwnerMask; |
619 | 619 | ||
620 | // Users should be able to edit what is over their land. | 620 | // Users should be able to edit what is over their land. |
621 | ILandObject parcel = m_scene.LandChannel.GetLandObject(task.AbsolutePosition.X, task.AbsolutePosition.Y); | 621 | Vector3 taskPos = task.AbsolutePosition; |
622 | ILandObject parcel = m_scene.LandChannel.GetLandObject(taskPos.X, taskPos.Y); | ||
622 | if (parcel != null && parcel.LandData.OwnerID == user && m_ParcelOwnerIsGod) | 623 | if (parcel != null && parcel.LandData.OwnerID == user && m_ParcelOwnerIsGod) |
623 | { | 624 | { |
624 | // Admin objects should not be editable by the above | 625 | // Admin objects should not be editable by the above |
diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs index c2753d9..8d27f9c 100644 --- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs +++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs | |||
@@ -1154,5 +1154,9 @@ namespace OpenSim.Region.Examples.SimpleModule | |||
1154 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) | 1154 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) |
1155 | { | 1155 | { |
1156 | } | 1156 | } |
1157 | |||
1158 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
1159 | { | ||
1160 | } | ||
1157 | } | 1161 | } |
1158 | } | 1162 | } |
diff --git a/OpenSim/Region/Framework/Interfaces/IDialogModule.cs b/OpenSim/Region/Framework/Interfaces/IDialogModule.cs index ce57c44..35b4b63 100644 --- a/OpenSim/Region/Framework/Interfaces/IDialogModule.cs +++ b/OpenSim/Region/Framework/Interfaces/IDialogModule.cs | |||
@@ -131,5 +131,10 @@ namespace OpenSim.Region.Framework.Interfaces | |||
131 | /// <param name="fromAvatarName">The name of the user doing the sending</param> | 131 | /// <param name="fromAvatarName">The name of the user doing the sending</param> |
132 | /// <param name="message">The message being sent to the user</param> | 132 | /// <param name="message">The message being sent to the user</param> |
133 | void SendNotificationToUsersInEstate(UUID fromAvatarID, string fromAvatarName, string message); | 133 | void SendNotificationToUsersInEstate(UUID fromAvatarID, string fromAvatarName, string message); |
134 | |||
135 | /// <summary> | ||
136 | /// Send a textbox entry for the client to respond to | ||
137 | /// </summary> | ||
138 | void SendTextBoxToUser(UUID avatarid, string message, int chatChannel, string name, UUID objectid, UUID ownerid); | ||
134 | } | 139 | } |
135 | } | 140 | } |
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 884f13a..d5d1825 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -4307,7 +4307,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
4307 | return m_sceneGraph.GetGroupByPrim(localID); | 4307 | return m_sceneGraph.GetGroupByPrim(localID); |
4308 | } | 4308 | } |
4309 | 4309 | ||
4310 | public bool TryGetAvatar(UUID avatarId, out ScenePresence avatar) | 4310 | public override bool TryGetAvatar(UUID avatarId, out ScenePresence avatar) |
4311 | { | 4311 | { |
4312 | return m_sceneGraph.TryGetAvatar(avatarId, out avatar); | 4312 | return m_sceneGraph.TryGetAvatar(avatarId, out avatar); |
4313 | } | 4313 | } |
diff --git a/OpenSim/Region/Framework/Scenes/SceneBase.cs b/OpenSim/Region/Framework/Scenes/SceneBase.cs index 4f6e824..74476ed 100644 --- a/OpenSim/Region/Framework/Scenes/SceneBase.cs +++ b/OpenSim/Region/Framework/Scenes/SceneBase.cs | |||
@@ -190,6 +190,21 @@ namespace OpenSim.Region.Framework.Scenes | |||
190 | /// <param name="agentID"></param> | 190 | /// <param name="agentID"></param> |
191 | public abstract void RemoveClient(UUID agentID); | 191 | public abstract void RemoveClient(UUID agentID); |
192 | 192 | ||
193 | public bool TryGetAvatar(UUID agentID, out object scenePresence) | ||
194 | { | ||
195 | scenePresence = null; | ||
196 | ScenePresence sp = null; | ||
197 | if (TryGetAvatar(agentID, out sp)) | ||
198 | { | ||
199 | scenePresence = sp; | ||
200 | return true; | ||
201 | } | ||
202 | |||
203 | return false; | ||
204 | } | ||
205 | |||
206 | public abstract bool TryGetAvatar(UUID agentID, out ScenePresence scenePresence); | ||
207 | |||
193 | #endregion | 208 | #endregion |
194 | 209 | ||
195 | /// <summary> | 210 | /// <summary> |
diff --git a/OpenSim/Region/Framework/Scenes/Tests/SceneBaseTests.cs b/OpenSim/Region/Framework/Scenes/Tests/SceneBaseTests.cs index 8230f32..840039c 100644 --- a/OpenSim/Region/Framework/Scenes/Tests/SceneBaseTests.cs +++ b/OpenSim/Region/Framework/Scenes/Tests/SceneBaseTests.cs | |||
@@ -65,6 +65,11 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
65 | { | 65 | { |
66 | throw new NotImplementedException(); | 66 | throw new NotImplementedException(); |
67 | } | 67 | } |
68 | |||
69 | public override bool TryGetAvatar(UUID agentID, out ScenePresence scenePresence) | ||
70 | { | ||
71 | throw new NotImplementedException(); | ||
72 | } | ||
68 | } | 73 | } |
69 | 74 | ||
70 | [Test] | 75 | [Test] |
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index 711052c..f5b148f 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs | |||
@@ -1680,5 +1680,9 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server | |||
1680 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) | 1680 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) |
1681 | { | 1681 | { |
1682 | } | 1682 | } |
1683 | |||
1684 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
1685 | { | ||
1686 | } | ||
1683 | } | 1687 | } |
1684 | } | 1688 | } |
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index ebf9333..338c04b 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | |||
@@ -1160,5 +1160,9 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
1160 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) | 1160 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) |
1161 | { | 1161 | { |
1162 | } | 1162 | } |
1163 | |||
1164 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
1165 | { | ||
1166 | } | ||
1163 | } | 1167 | } |
1164 | } | 1168 | } |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index aa2c8b3..093cd0b 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -4201,10 +4201,34 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
4201 | ScriptSleep(5000); | 4201 | ScriptSleep(5000); |
4202 | } | 4202 | } |
4203 | 4203 | ||
4204 | public void llTextBox(string avatar, string message, int chat_channel) | 4204 | public void llTextBox(string agent, string message, int chatChannel) |
4205 | { | 4205 | { |
4206 | IDialogModule dm = World.RequestModuleInterface<IDialogModule>(); | ||
4207 | |||
4208 | if (dm == null) | ||
4209 | return; | ||
4210 | |||
4206 | m_host.AddScriptLPS(1); | 4211 | m_host.AddScriptLPS(1); |
4207 | NotImplemented("llTextBox"); | 4212 | UUID av = new UUID(); |
4213 | if (!UUID.TryParse(agent,out av)) | ||
4214 | { | ||
4215 | LSLError("First parameter to llDialog needs to be a key"); | ||
4216 | return; | ||
4217 | } | ||
4218 | |||
4219 | if( message == string.Empty) | ||
4220 | { | ||
4221 | ShoutError("Trying to use llTextBox with empty message."); | ||
4222 | } | ||
4223 | else if (message.Length > 512) | ||
4224 | { | ||
4225 | ShoutError("Trying to use llTextBox with message over 512 characters."); | ||
4226 | } | ||
4227 | else | ||
4228 | { | ||
4229 | dm.SendTextBoxToUser(av, message, chatChannel, m_host.Name, m_host.UUID, m_host.OwnerID); | ||
4230 | ScriptSleep(1000); | ||
4231 | } | ||
4208 | } | 4232 | } |
4209 | 4233 | ||
4210 | public void llModifyLand(int action, int brush) | 4234 | public void llModifyLand(int action, int brush) |
@@ -4219,6 +4243,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
4219 | 4243 | ||
4220 | public void llCollisionSound(string impact_sound, double impact_volume) | 4244 | public void llCollisionSound(string impact_sound, double impact_volume) |
4221 | { | 4245 | { |
4246 | |||
4222 | m_host.AddScriptLPS(1); | 4247 | m_host.AddScriptLPS(1); |
4223 | // TODO: Parameter check logic required. | 4248 | // TODO: Parameter check logic required. |
4224 | UUID soundId = UUID.Zero; | 4249 | UUID soundId = UUID.Zero; |
diff --git a/OpenSim/Services/Connectors/Asset/AssetServiceConnector.cs b/OpenSim/Services/Connectors/Asset/AssetServiceConnector.cs index 6847852..a5c157d 100644 --- a/OpenSim/Services/Connectors/Asset/AssetServiceConnector.cs +++ b/OpenSim/Services/Connectors/Asset/AssetServiceConnector.cs | |||
@@ -68,7 +68,7 @@ namespace OpenSim.Services.Connectors | |||
68 | IConfig assetConfig = source.Configs["AssetService"]; | 68 | IConfig assetConfig = source.Configs["AssetService"]; |
69 | if (assetConfig == null) | 69 | if (assetConfig == null) |
70 | { | 70 | { |
71 | m_log.Error("[ASSET CONNECTOR]: AssetService missing from OpanSim.ini"); | 71 | m_log.Error("[ASSET CONNECTOR]: AssetService missing from OpenSim.ini"); |
72 | throw new Exception("Asset connector init error"); | 72 | throw new Exception("Asset connector init error"); |
73 | } | 73 | } |
74 | 74 | ||
diff --git a/OpenSim/Services/Connectors/Authentication/AuthenticationServiceConnector.cs b/OpenSim/Services/Connectors/Authentication/AuthenticationServiceConnector.cs index f36fe5b..6f77a2d 100644 --- a/OpenSim/Services/Connectors/Authentication/AuthenticationServiceConnector.cs +++ b/OpenSim/Services/Connectors/Authentication/AuthenticationServiceConnector.cs | |||
@@ -67,7 +67,7 @@ namespace OpenSim.Services.Connectors | |||
67 | IConfig assetConfig = source.Configs["AuthenticationService"]; | 67 | IConfig assetConfig = source.Configs["AuthenticationService"]; |
68 | if (assetConfig == null) | 68 | if (assetConfig == null) |
69 | { | 69 | { |
70 | m_log.Error("[AUTH CONNECTOR]: AuthenticationService missing from OpanSim.ini"); | 70 | m_log.Error("[AUTH CONNECTOR]: AuthenticationService missing from OpenSim.ini"); |
71 | throw new Exception("Authentication connector init error"); | 71 | throw new Exception("Authentication connector init error"); |
72 | } | 72 | } |
73 | 73 | ||
diff --git a/OpenSim/Services/Connectors/Inventory/XInventoryConnector.cs b/OpenSim/Services/Connectors/Inventory/XInventoryConnector.cs index 3309d16..9821dd4 100644 --- a/OpenSim/Services/Connectors/Inventory/XInventoryConnector.cs +++ b/OpenSim/Services/Connectors/Inventory/XInventoryConnector.cs | |||
@@ -68,7 +68,7 @@ namespace OpenSim.Services.Connectors | |||
68 | IConfig assetConfig = source.Configs["InventoryService"]; | 68 | IConfig assetConfig = source.Configs["InventoryService"]; |
69 | if (assetConfig == null) | 69 | if (assetConfig == null) |
70 | { | 70 | { |
71 | m_log.Error("[INVENTORY CONNECTOR]: InventoryService missing from OpanSim.ini"); | 71 | m_log.Error("[INVENTORY CONNECTOR]: InventoryService missing from OpenSim.ini"); |
72 | throw new Exception("Inventory connector init error"); | 72 | throw new Exception("Inventory connector init error"); |
73 | } | 73 | } |
74 | 74 | ||
diff --git a/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs b/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs index e1621b8..8e7c92b 100644 --- a/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs +++ b/OpenSim/Services/Connectors/UserAccounts/UserAccountServiceConnector.cs | |||
@@ -131,7 +131,7 @@ namespace OpenSim.Services.Connectors | |||
131 | //sendData["SCOPEID"] = scopeID.ToString(); | 131 | //sendData["SCOPEID"] = scopeID.ToString(); |
132 | sendData["VERSIONMIN"] = ProtocolVersions.ClientProtocolVersionMin.ToString(); | 132 | sendData["VERSIONMIN"] = ProtocolVersions.ClientProtocolVersionMin.ToString(); |
133 | sendData["VERSIONMAX"] = ProtocolVersions.ClientProtocolVersionMax.ToString(); | 133 | sendData["VERSIONMAX"] = ProtocolVersions.ClientProtocolVersionMax.ToString(); |
134 | sendData["METHOD"] = "getagents"; | 134 | sendData["METHOD"] = "getaccounts"; |
135 | 135 | ||
136 | sendData["ScopeID"] = scopeID.ToString(); | 136 | sendData["ScopeID"] = scopeID.ToString(); |
137 | sendData["query"] = query; | 137 | sendData["query"] = query; |
diff --git a/OpenSim/Services/PresenceService/PresenceService.cs b/OpenSim/Services/PresenceService/PresenceService.cs index 1a31965..304538a 100644 --- a/OpenSim/Services/PresenceService/PresenceService.cs +++ b/OpenSim/Services/PresenceService/PresenceService.cs | |||
@@ -206,7 +206,7 @@ namespace OpenSim.Services.PresenceService | |||
206 | } | 206 | } |
207 | } | 207 | } |
208 | 208 | ||
209 | m_log.DebugFormat("[PRESENCE SERVICE]: GetAgents for {0} userIDs found {1} presences", userIDs.Length, info.Count); | 209 | // m_log.DebugFormat("[PRESENCE SERVICE]: GetAgents for {0} userIDs found {1} presences", userIDs.Length, info.Count); |
210 | return info.ToArray(); | 210 | return info.ToArray(); |
211 | } | 211 | } |
212 | 212 | ||
diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs index 715e1a4..f015db2 100644 --- a/OpenSim/Tests/Common/Mock/TestClient.cs +++ b/OpenSim/Tests/Common/Mock/TestClient.cs | |||
@@ -1214,5 +1214,9 @@ namespace OpenSim.Tests.Common.Mock | |||
1214 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) | 1214 | public void SendChangeUserRights(UUID agentID, UUID friendID, int rights) |
1215 | { | 1215 | { |
1216 | } | 1216 | } |
1217 | |||
1218 | public void SendTextBoxRequest(string message, int chatChannel, string objectname, string ownerFirstName, string ownerLastName, UUID objectId) | ||
1219 | { | ||
1220 | } | ||
1217 | } | 1221 | } |
1218 | } | 1222 | } |