* Added IClientIM to IClientCore interfaces
* Changed SendInstantMessage, dropped fromAgentSession and imSessionID as security precaution, see http://opensimulator.org/wiki/OpenSim_0.6_IClientAPI#Porting_Guide for details on porting. * Removed unused usings from Framework.*0.6.1-post-fixes
parent
07cfa1e70b
commit
cf0a14bec9
|
@ -25,9 +25,6 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
|
|
|
@ -28,13 +28,9 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections;
|
using System.Collections;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Reflection;
|
|
||||||
using System.Runtime.Serialization;
|
using System.Runtime.Serialization;
|
||||||
using System.Security.Permissions;
|
using System.Security.Permissions;
|
||||||
using log4net;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using OpenMetaverse.Packets;
|
|
||||||
using OpenSim.Framework;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using OpenSim.Framework;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -0,0 +1,45 @@
|
||||||
|
using System;
|
||||||
|
using OpenMetaverse;
|
||||||
|
|
||||||
|
namespace OpenSim.Framework.Client
|
||||||
|
{
|
||||||
|
public class ClientInstantMessageArgs : EventArgs
|
||||||
|
{
|
||||||
|
public IClientCore client;
|
||||||
|
public string message;
|
||||||
|
public DateTime time;
|
||||||
|
public ClientInstantMessageSender sender;
|
||||||
|
}
|
||||||
|
|
||||||
|
public class ClientInstantMessageSender
|
||||||
|
{
|
||||||
|
public UUID ID;
|
||||||
|
public bool online;
|
||||||
|
public string name;
|
||||||
|
public Vector3 position;
|
||||||
|
public UUID regionID;
|
||||||
|
}
|
||||||
|
|
||||||
|
public delegate void ClientInstantMessage(Object sender, ClientInstantMessageArgs e);
|
||||||
|
|
||||||
|
public class ClientInstantMessageParms
|
||||||
|
{
|
||||||
|
public ClientInstantMessageSender senderInfo;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Porting Guide from old IM
|
||||||
|
// SendIM(...)
|
||||||
|
// Loses FromAgentSession - this should be added by implementers manually.
|
||||||
|
//
|
||||||
|
|
||||||
|
public interface IClientIM
|
||||||
|
{
|
||||||
|
void SendInstantMessage(UUID fromAgent, string message, UUID toAgent,
|
||||||
|
string fromName, byte dialog, uint timeStamp);
|
||||||
|
|
||||||
|
void SendInstantMessage(UUID fromAgent, string message, UUID toAgent,
|
||||||
|
string fromName, byte dialog, uint timeStamp,
|
||||||
|
bool fromGroup, byte[] binaryBucket);
|
||||||
|
event ImprovedInstantMessage OnInstantMessage;
|
||||||
|
}
|
||||||
|
}
|
|
@ -28,9 +28,9 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
using log4net;
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using OpenMetaverse.Packets;
|
using OpenMetaverse.Packets;
|
||||||
using log4net;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -26,9 +26,8 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections;
|
|
||||||
using OpenMetaverse;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -25,10 +25,6 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
public class ConfigSettings
|
public class ConfigSettings
|
||||||
|
|
|
@ -31,8 +31,8 @@ using System.Globalization;
|
||||||
using System.Net;
|
using System.Net;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Xml;
|
using System.Xml;
|
||||||
using OpenMetaverse;
|
|
||||||
using log4net;
|
using log4net;
|
||||||
|
using OpenMetaverse;
|
||||||
using OpenSim.Framework.Console;
|
using OpenSim.Framework.Console;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
|
|
|
@ -26,9 +26,6 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -26,11 +26,9 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.IO;
|
|
||||||
using System.Reflection;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using log4net;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -25,7 +25,6 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
|
|
|
@ -25,8 +25,6 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
public class FriendRegionInfo
|
public class FriendRegionInfo
|
||||||
|
|
|
@ -26,11 +26,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
using System;
|
|
||||||
using System.Collections;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -638,7 +638,6 @@ namespace OpenSim.Framework
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Tell this client what items it should be wearing now
|
/// Tell this client what items it should be wearing now
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="wearables"></param>
|
|
||||||
void SendWearables(AvatarWearable[] wearables, int serial);
|
void SendWearables(AvatarWearable[] wearables, int serial);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -660,15 +659,18 @@ namespace OpenSim.Framework
|
||||||
|
|
||||||
void SendAnimations(UUID[] animID, int[] seqs, UUID sourceAgentId);
|
void SendAnimations(UUID[] animID, int[] seqs, UUID sourceAgentId);
|
||||||
void SendRegionHandshake(RegionInfo regionInfo, RegionHandshakeArgs args);
|
void SendRegionHandshake(RegionInfo regionInfo, RegionHandshakeArgs args);
|
||||||
void SendChatMessage(string message, byte type, Vector3 fromPos, string fromName, UUID fromAgentID, byte source, byte audible);
|
|
||||||
void SendChatMessage(byte[] message, byte type, Vector3 fromPos, string fromName, UUID fromAgentID, byte source, byte audible);
|
|
||||||
|
|
||||||
void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
void SendChatMessage(string message, byte type, Vector3 fromPos, string fromName, UUID fromAgentID, byte source,
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp);
|
byte audible);
|
||||||
|
|
||||||
void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
void SendChatMessage(byte[] message, byte type, Vector3 fromPos, string fromName, UUID fromAgentID, byte source,
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp,
|
byte audible);
|
||||||
bool fromGroup, byte[] binaryBucket);
|
|
||||||
|
void SendInstantMessage(UUID fromAgent, string message, UUID toAgent, string fromName, byte dialog,
|
||||||
|
uint timeStamp);
|
||||||
|
|
||||||
|
void SendInstantMessage(UUID fromAgent, string message, UUID toAgent, string fromName, byte dialog,
|
||||||
|
uint timeStamp, bool fromGroup, byte[] binaryBucket);
|
||||||
|
|
||||||
void SendGenericMessage(string method, List<string> message);
|
void SendGenericMessage(string method, List<string> message);
|
||||||
|
|
||||||
|
@ -833,7 +835,6 @@ namespace OpenSim.Framework
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Tell the client that the requested texture cannot be found
|
/// Tell the client that the requested texture cannot be found
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="imageId"></param>
|
|
||||||
void SendImageNotFound(UUID imageid);
|
void SendImageNotFound(UUID imageid);
|
||||||
|
|
||||||
void SendShutdownConnectionNotice();
|
void SendShutdownConnectionNotice();
|
||||||
|
@ -880,7 +881,6 @@ namespace OpenSim.Framework
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Set the debug level at which packet output should be printed to console.
|
/// Set the debug level at which packet output should be printed to console.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="newDebugPacketLevel"></param>
|
|
||||||
void SetDebugPacketLevel(int newDebug);
|
void SetDebugPacketLevel(int newDebug);
|
||||||
|
|
||||||
void InPacket(object NewPack);
|
void InPacket(object NewPack);
|
||||||
|
@ -892,7 +892,7 @@ namespace OpenSim.Framework
|
||||||
event Action<IClientAPI> OnLogout;
|
event Action<IClientAPI> OnLogout;
|
||||||
event Action<IClientAPI> OnConnectionClosed;
|
event Action<IClientAPI> OnConnectionClosed;
|
||||||
|
|
||||||
void SendBlueBoxMessage(UUID FromAvatarID, UUID fromSessionID, String FromAvatarName, String Message);
|
void SendBlueBoxMessage(UUID FromAvatarID, String FromAvatarName, String Message);
|
||||||
|
|
||||||
void SendLogoutPacket();
|
void SendLogoutPacket();
|
||||||
ClientInfo GetClientInfo();
|
ClientInfo GetClientInfo();
|
||||||
|
|
|
@ -26,12 +26,8 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
public class LandStatReportItem
|
public class LandStatReportItem
|
||||||
|
|
|
@ -25,7 +25,6 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
|
|
|
@ -25,10 +25,6 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
public enum ParcelMediaCommandEnum
|
public enum ParcelMediaCommandEnum
|
||||||
|
|
|
@ -26,14 +26,12 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.IO;
|
|
||||||
using System.Xml;
|
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.IO;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using log4net;
|
using log4net;
|
||||||
using Mono.Addins;
|
using Mono.Addins;
|
||||||
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
@ -28,8 +28,8 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
using System.Xml.Serialization;
|
using System.Xml.Serialization;
|
||||||
using OpenMetaverse;
|
|
||||||
using log4net;
|
using log4net;
|
||||||
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -26,10 +26,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections;
|
|
||||||
using System.Net;
|
using System.Net;
|
||||||
using OpenMetaverse;
|
|
||||||
using OpenMetaverse.Packets;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -26,12 +26,11 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Net;
|
using System.Net;
|
||||||
using System.Net.Sockets;
|
using System.Net.Sockets;
|
||||||
using System.Xml;
|
using System.Xml;
|
||||||
using OpenMetaverse;
|
|
||||||
using Nini.Config;
|
using Nini.Config;
|
||||||
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -27,9 +27,7 @@
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Reflection;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using log4net;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -25,9 +25,6 @@
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Text;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
|
|
|
@ -27,12 +27,10 @@
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Reflection;
|
|
||||||
using System.Xml;
|
using System.Xml;
|
||||||
using System.Xml.Schema;
|
using System.Xml.Schema;
|
||||||
using System.Xml.Serialization;
|
using System.Xml.Serialization;
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using log4net;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -26,13 +26,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Reflection;
|
|
||||||
using System.Xml;
|
|
||||||
using System.Xml.Schema;
|
|
||||||
using System.Xml.Serialization;
|
|
||||||
using OpenMetaverse;
|
using OpenMetaverse;
|
||||||
using log4net;
|
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -39,10 +39,10 @@ using System.Security.Cryptography;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
using System.Xml;
|
using System.Xml;
|
||||||
using OpenMetaverse;
|
|
||||||
using log4net;
|
using log4net;
|
||||||
using Nini.Config;
|
using Nini.Config;
|
||||||
using Nwc.XmlRpc;
|
using Nwc.XmlRpc;
|
||||||
|
using OpenMetaverse;
|
||||||
|
|
||||||
namespace OpenSim.Framework
|
namespace OpenSim.Framework
|
||||||
{
|
{
|
||||||
|
|
|
@ -52,7 +52,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
/// Handles new client connections
|
/// Handles new client connections
|
||||||
/// Constructor takes a single Packet and authenticates everything
|
/// Constructor takes a single Packet and authenticates everything
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class LLClientView : IClientAPI, IClientCore
|
public class LLClientView : IClientAPI, IClientCore, IClientIM
|
||||||
{
|
{
|
||||||
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
|
||||||
|
|
||||||
|
@ -394,6 +394,9 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
AuthenticateResponse sessionInfo, UUID agentId, UUID sessionId, uint circuitCode, EndPoint proxyEP,
|
AuthenticateResponse sessionInfo, UUID agentId, UUID sessionId, uint circuitCode, EndPoint proxyEP,
|
||||||
ClientStackUserSettings userSettings)
|
ClientStackUserSettings userSettings)
|
||||||
{
|
{
|
||||||
|
// Should be called first?
|
||||||
|
RegisterInterfaces();
|
||||||
|
|
||||||
m_GroupsModule = scene.RequestModuleInterface<IGroupsModule>();
|
m_GroupsModule = scene.RequestModuleInterface<IGroupsModule>();
|
||||||
m_moneyBalance = 1000;
|
m_moneyBalance = 1000;
|
||||||
|
|
||||||
|
@ -1076,19 +1079,16 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Send an instant message to this client
|
/// Send an instant message to this client
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
public void SendInstantMessage(UUID fromAgent, string message, UUID toAgent, string fromName, byte dialog, uint timeStamp)
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp)
|
|
||||||
{
|
{
|
||||||
SendInstantMessage(
|
SendInstantMessage(fromAgent, message, toAgent, fromName, dialog, timeStamp, false, new byte[0]);
|
||||||
fromAgent, fromAgentSession, message, toAgent,
|
|
||||||
imSessionID, fromName, dialog, timeStamp, false, new byte[0]);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Send an instant message to this client
|
/// Send an instant message to this client
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
public void SendInstantMessage(UUID fromAgent, string message, UUID toAgent,
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp,
|
string fromName, byte dialog, uint timeStamp,
|
||||||
bool fromGroup, byte[] binaryBucket)
|
bool fromGroup, byte[] binaryBucket)
|
||||||
{
|
{
|
||||||
if (((Scene)(m_scene)).ExternalChecks.ExternalChecksCanInstantMessage(fromAgent, toAgent))
|
if (((Scene)(m_scene)).ExternalChecks.ExternalChecksCanInstantMessage(fromAgent, toAgent))
|
||||||
|
@ -1097,15 +1097,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
= (ImprovedInstantMessagePacket)PacketPool.Instance.GetPacket(PacketType.ImprovedInstantMessage);
|
= (ImprovedInstantMessagePacket)PacketPool.Instance.GetPacket(PacketType.ImprovedInstantMessage);
|
||||||
|
|
||||||
msg.AgentData.AgentID = fromAgent;
|
msg.AgentData.AgentID = fromAgent;
|
||||||
msg.AgentData.SessionID = fromAgentSession;
|
msg.AgentData.SessionID = UUID.Zero;
|
||||||
msg.MessageBlock.FromAgentName = Utils.StringToBytes(fromName);
|
msg.MessageBlock.FromAgentName = Utils.StringToBytes(fromName);
|
||||||
msg.MessageBlock.Dialog = dialog;
|
msg.MessageBlock.Dialog = dialog;
|
||||||
msg.MessageBlock.FromGroup = fromGroup;
|
msg.MessageBlock.FromGroup = fromGroup;
|
||||||
msg.MessageBlock.ID = imSessionID;
|
msg.MessageBlock.ID = fromAgent ^ toAgent;
|
||||||
msg.MessageBlock.Offline = 0;
|
msg.MessageBlock.Offline = 0;
|
||||||
msg.MessageBlock.ParentEstateID = 0;
|
msg.MessageBlock.ParentEstateID = 0;
|
||||||
msg.MessageBlock.Position = new Vector3();
|
msg.MessageBlock.Position = new Vector3();
|
||||||
msg.MessageBlock.RegionID = UUID.Random();
|
msg.MessageBlock.RegionID = UUID.Zero;
|
||||||
msg.MessageBlock.Timestamp = timeStamp;
|
msg.MessageBlock.Timestamp = timeStamp;
|
||||||
msg.MessageBlock.ToAgentID = toAgent;
|
msg.MessageBlock.ToAgentID = toAgent;
|
||||||
msg.MessageBlock.Message = Utils.StringToBytes(message);
|
msg.MessageBlock.Message = Utils.StringToBytes(message);
|
||||||
|
@ -6919,10 +6919,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
/// <param name="fromSessionID"></param>
|
/// <param name="fromSessionID"></param>
|
||||||
/// <param name="FromAvatarName"></param>
|
/// <param name="FromAvatarName"></param>
|
||||||
/// <param name="Message"></param>
|
/// <param name="Message"></param>
|
||||||
public void SendBlueBoxMessage(UUID FromAvatarID, UUID fromSessionID, String FromAvatarName, String Message)
|
public void SendBlueBoxMessage(UUID FromAvatarID, String FromAvatarName, String Message)
|
||||||
{
|
{
|
||||||
if (!ChildAgentStatus())
|
if (!ChildAgentStatus())
|
||||||
SendInstantMessage(FromAvatarID, fromSessionID, Message, AgentId, SessionId, FromAvatarName, 1, (uint)Util.UnixTimeSinceEpoch());
|
SendInstantMessage(FromAvatarID, Message, AgentId, FromAvatarName, 1, (uint)Util.UnixTimeSinceEpoch());
|
||||||
|
|
||||||
//SendInstantMessage(FromAvatarID, fromSessionID, Message, AgentId, SessionId, FromAvatarName, (byte)21,(uint) Util.UnixTimeSinceEpoch());
|
//SendInstantMessage(FromAvatarID, fromSessionID, Message, AgentId, SessionId, FromAvatarName, (byte)21,(uint) Util.UnixTimeSinceEpoch());
|
||||||
}
|
}
|
||||||
|
@ -7675,6 +7675,11 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected virtual void RegisterInterfaces()
|
||||||
|
{
|
||||||
|
RegisterInterface<IClientIM>(this);
|
||||||
|
}
|
||||||
|
|
||||||
public bool TryGet<T>(out T iface)
|
public bool TryGet<T>(out T iface)
|
||||||
{
|
{
|
||||||
if (m_clientInterfaces.ContainsKey(typeof(T)))
|
if (m_clientInterfaces.ContainsKey(typeof(T)))
|
||||||
|
|
|
@ -819,9 +819,9 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Currency.SampleMoney
|
||||||
Hashtable retparam = new Hashtable();
|
Hashtable retparam = new Hashtable();
|
||||||
Hashtable requestData = (Hashtable) request.Params[0];
|
Hashtable requestData = (Hashtable) request.Params[0];
|
||||||
|
|
||||||
UUID agentId = UUID.Zero;
|
UUID agentId;
|
||||||
UUID soundId = UUID.Zero;
|
UUID soundId;
|
||||||
UUID regionId = UUID.Zero;
|
UUID regionId;
|
||||||
|
|
||||||
UUID.TryParse((string) requestData["agentId"], out agentId);
|
UUID.TryParse((string) requestData["agentId"], out agentId);
|
||||||
UUID.TryParse((string) requestData["soundId"], out soundId);
|
UUID.TryParse((string) requestData["soundId"], out soundId);
|
||||||
|
@ -832,7 +832,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Currency.SampleMoney
|
||||||
Scene userScene = GetSceneByUUID(regionId);
|
Scene userScene = GetSceneByUUID(regionId);
|
||||||
if (userScene != null)
|
if (userScene != null)
|
||||||
{
|
{
|
||||||
if (userScene.RegionInfo.regionSecret.ToString() == secret)
|
if (userScene.RegionInfo.regionSecret == secret)
|
||||||
{
|
{
|
||||||
|
|
||||||
IClientAPI client = LocateClientObject(agentId);
|
IClientAPI client = LocateClientObject(agentId);
|
||||||
|
@ -842,7 +842,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Currency.SampleMoney
|
||||||
if (soundId != UUID.Zero)
|
if (soundId != UUID.Zero)
|
||||||
client.SendPlayAttachedSound(soundId, UUID.Zero, UUID.Zero, 1.0f, 0);
|
client.SendPlayAttachedSound(soundId, UUID.Zero, UUID.Zero, 1.0f, 0);
|
||||||
|
|
||||||
client.SendBlueBoxMessage(UUID.Zero, UUID.Zero, "", text);
|
client.SendBlueBoxMessage(UUID.Zero, "", text);
|
||||||
|
|
||||||
retparam.Add("success", true);
|
retparam.Add("success", true);
|
||||||
}
|
}
|
||||||
|
|
|
@ -155,8 +155,8 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage
|
||||||
ScenePresence user = (ScenePresence) scene.Entities[toAgentID];
|
ScenePresence user = (ScenePresence) scene.Entities[toAgentID];
|
||||||
if (!user.IsChildAgent)
|
if (!user.IsChildAgent)
|
||||||
{
|
{
|
||||||
user.ControllingClient.SendInstantMessage(fromAgentID, fromAgentSession, message,
|
user.ControllingClient.SendInstantMessage(fromAgentID, message,
|
||||||
toAgentID, imSessionID, fromAgentName, dialog,
|
toAgentID, fromAgentName, dialog,
|
||||||
timestamp, fromGroup, binaryBucket);
|
timestamp, fromGroup, binaryBucket);
|
||||||
// Message sent
|
// Message sent
|
||||||
return;
|
return;
|
||||||
|
@ -172,8 +172,8 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage
|
||||||
// Local message
|
// Local message
|
||||||
ScenePresence user = (ScenePresence) scene.Entities[toAgentID];
|
ScenePresence user = (ScenePresence) scene.Entities[toAgentID];
|
||||||
|
|
||||||
user.ControllingClient.SendInstantMessage(fromAgentID, fromAgentSession, message,
|
user.ControllingClient.SendInstantMessage(fromAgentID, message,
|
||||||
toAgentID, imSessionID, fromAgentName, dialog,
|
toAgentID, fromAgentName, dialog,
|
||||||
timestamp, fromGroup, binaryBucket);
|
timestamp, fromGroup, binaryBucket);
|
||||||
// Message sent
|
// Message sent
|
||||||
return;
|
return;
|
||||||
|
@ -199,7 +199,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage
|
||||||
if (client != null)
|
if (client != null)
|
||||||
{
|
{
|
||||||
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
||||||
client.SendInstantMessage(toAgentID, fromAgentSession, "Unable to send instant message. User is not logged in.", fromAgentID, imSessionID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
client.SendInstantMessage(toAgentID, "Unable to send instant message. User is not logged in.", fromAgentID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -551,7 +551,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage
|
||||||
if (client != null)
|
if (client != null)
|
||||||
{
|
{
|
||||||
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
||||||
client.SendInstantMessage(toAgentID, fromAgentSession, "Unable to send instant message", fromAgentID, imSessionID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
client.SendInstantMessage(toAgentID, "Unable to send instant message", fromAgentID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -562,7 +562,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage
|
||||||
if (client != null)
|
if (client != null)
|
||||||
{
|
{
|
||||||
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
||||||
client.SendInstantMessage(toAgentID, fromAgentSession, "Unable to send instant message", fromAgentID, imSessionID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
client.SendInstantMessage(toAgentID, "Unable to send instant message", fromAgentID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -635,7 +635,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage
|
||||||
if (client != null)
|
if (client != null)
|
||||||
{
|
{
|
||||||
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
if (dialog != (byte)InstantMessageDialog.StartTyping && dialog != (byte)InstantMessageDialog.StopTyping && dialog != (byte)InstantMessageDialog.SessionDrop)
|
||||||
client.SendInstantMessage(toAgentID, fromAgentSession, "Unable to send instant message: Agent Offline", fromAgentID, imSessionID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
client.SendInstantMessage(toAgentID, "Unable to send instant message: Agent Offline", fromAgentID, "System", (byte)InstantMessageDialog.BusyAutoResponse, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -643,7 +643,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage
|
||||||
{
|
{
|
||||||
// send Agent doesn't exist message
|
// send Agent doesn't exist message
|
||||||
if (client != null)
|
if (client != null)
|
||||||
client.SendInstantMessage(toAgentID, fromAgentSession, "Unable to send instant message: Are you sure this agent exists anymore?", fromAgentID, imSessionID, "System", (byte)InstantMessageDialog.MessageFromObject, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
client.SendInstantMessage(toAgentID, "Unable to send instant message: Are you sure this agent exists anymore?", fromAgentID, "System", (byte)InstantMessageDialog.MessageFromObject, (uint)Util.UnixTimeSinceEpoch());// SendAlertMessage("Unable to send instant message");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -135,7 +135,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Inventory.Transfer
|
||||||
m_pendingOffers[imSessionID] = itemId;
|
m_pendingOffers[imSessionID] = itemId;
|
||||||
|
|
||||||
user.ControllingClient.SendInstantMessage(
|
user.ControllingClient.SendInstantMessage(
|
||||||
fromAgentID, fromAgentSession, message, toAgentID, imSessionID, fromAgentName,
|
fromAgentID, message, toAgentID, fromAgentName,
|
||||||
dialog, timestamp, false, binaryBucket);
|
dialog, timestamp, false, binaryBucket);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
@ -167,7 +167,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Inventory.Transfer
|
||||||
if (!user.IsChildAgent)
|
if (!user.IsChildAgent)
|
||||||
{
|
{
|
||||||
user.ControllingClient.SendInstantMessage(
|
user.ControllingClient.SendInstantMessage(
|
||||||
fromAgentID, fromAgentSession, message, toAgentID, imSessionID, fromAgentName,
|
fromAgentID, message, toAgentID, fromAgentName,
|
||||||
dialog, timestamp, false, binaryBucket);
|
dialog, timestamp, false, binaryBucket);
|
||||||
|
|
||||||
if (m_pendingOffers.ContainsKey(imSessionID))
|
if (m_pendingOffers.ContainsKey(imSessionID))
|
||||||
|
@ -213,7 +213,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.Inventory.Transfer
|
||||||
if (!user.IsChildAgent)
|
if (!user.IsChildAgent)
|
||||||
{
|
{
|
||||||
user.ControllingClient.SendInstantMessage(
|
user.ControllingClient.SendInstantMessage(
|
||||||
fromAgentID, fromAgentSession, message, toAgentID, imSessionID, fromAgentName,
|
fromAgentID, message, toAgentID, fromAgentName,
|
||||||
dialog, timestamp, false, binaryBucket);
|
dialog, timestamp, false, binaryBucket);
|
||||||
|
|
||||||
if (m_pendingOffers.ContainsKey(imSessionID))
|
if (m_pendingOffers.ContainsKey(imSessionID))
|
||||||
|
|
|
@ -471,15 +471,14 @@ namespace OpenSim.Region.Environment.Modules.World.NPC
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
public virtual void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
public void SendInstantMessage(UUID fromAgent, string message, UUID toAgent, string fromName, byte dialog, uint timeStamp)
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp)
|
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public virtual void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
public void SendInstantMessage(UUID fromAgent, string message, UUID toAgent, string fromName, byte dialog, uint timeStamp, bool fromGroup, byte[] binaryBucket)
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp,
|
|
||||||
bool fromGroup, byte[] binaryBucket)
|
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SendGenericMessage(string method, List<string> message)
|
public void SendGenericMessage(string method, List<string> message)
|
||||||
|
@ -793,7 +792,7 @@ namespace OpenSim.Region.Environment.Modules.World.NPC
|
||||||
set { m_circuitCode = value; }
|
set { m_circuitCode = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SendBlueBoxMessage(UUID FromAvatarID, UUID fromSessionID, String FromAvatarName, String Message)
|
public void SendBlueBoxMessage(UUID FromAvatarID, String FromAvatarName, String Message)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -3424,7 +3424,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
foreach (ScenePresence presence in presenceList)
|
foreach (ScenePresence presence in presenceList)
|
||||||
{
|
{
|
||||||
if (!presence.IsChildAgent)
|
if (!presence.IsChildAgent)
|
||||||
presence.ControllingClient.SendBlueBoxMessage(FromAvatarID, fromSessionID, FromAvatarName, Message);
|
presence.ControllingClient.SendBlueBoxMessage(FromAvatarID, FromAvatarName, Message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3441,7 +3441,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||||
|
|
||||||
ClientManager.ForEachClient(delegate(IClientAPI controller)
|
ClientManager.ForEachClient(delegate(IClientAPI controller)
|
||||||
{
|
{
|
||||||
controller.SendBlueBoxMessage(FromAvatarID, fromSessionID, FromAvatarName, Message);
|
controller.SendBlueBoxMessage(FromAvatarID, FromAvatarName, Message);
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -383,15 +383,14 @@ namespace OpenSim.Region.Examples.SimpleModule
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
public virtual void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
public void SendInstantMessage(UUID fromAgent, string message, UUID toAgent, string fromName, byte dialog, uint timeStamp)
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp)
|
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public virtual void SendInstantMessage(UUID fromAgent, UUID fromAgentSession, string message, UUID toAgent,
|
public void SendInstantMessage(UUID fromAgent, string message, UUID toAgent, string fromName, byte dialog, uint timeStamp, bool fromGroup, byte[] binaryBucket)
|
||||||
UUID imSessionID, string fromName, byte dialog, uint timeStamp,
|
|
||||||
bool fromGroup, byte[] binaryBucket)
|
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SendGenericMessage(string method, List<string> message)
|
public void SendGenericMessage(string method, List<string> message)
|
||||||
|
@ -780,7 +779,7 @@ namespace OpenSim.Region.Examples.SimpleModule
|
||||||
set { m_circuitCode = value; }
|
set { m_circuitCode = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SendBlueBoxMessage(UUID FromAvatarID, UUID fromSessionID, String FromAvatarName, String Message)
|
public void SendBlueBoxMessage(UUID FromAvatarID, String FromAvatarName, String Message)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue