mirror of
https://github.com/opensim/opensim.git
synced 2026-08-01 06:06:06 +08:00
* You can add and remove a friend in standalone now within the same simulator. It saves.
* You can add and remove a friend in grid mode now within the same simulator. It doesn't save yet. * I got rid of Mr. OpenSim as a friend.. he bothers me /:b...
This commit is contained in:
@@ -551,6 +551,10 @@ namespace OpenSim.Region.ClientStack
|
||||
public event RegionInfoRequest OnRegionInfoRequest;
|
||||
public event EstateCovenantRequest OnEstateCovenantRequest;
|
||||
|
||||
public event FriendActionDelegate OnApproveFriendRequest;
|
||||
public event FriendActionDelegate OnDenyFriendRequest;
|
||||
public event FriendshipTermination OnTerminateFriendship;
|
||||
|
||||
#region Scene/Avatar to Client
|
||||
|
||||
/// <summary>
|
||||
@@ -2555,6 +2559,39 @@ namespace OpenSim.Region.ClientStack
|
||||
msgpack.MessageBlock.BinaryBucket);
|
||||
}
|
||||
break;
|
||||
|
||||
case PacketType.AcceptFriendship:
|
||||
AcceptFriendshipPacket afriendpack = (AcceptFriendshipPacket)Pack;
|
||||
|
||||
// My guess is this is the folder to stick the calling card into
|
||||
List<LLUUID> callingCardFolders = new List<LLUUID>();
|
||||
|
||||
LLUUID agentID = afriendpack.AgentData.AgentID;
|
||||
LLUUID transactionID = afriendpack.TransactionBlock.TransactionID;
|
||||
|
||||
for (int fi = 0; fi < afriendpack.FolderData.Length; fi++)
|
||||
{
|
||||
callingCardFolders.Add(afriendpack.FolderData[fi].FolderID);
|
||||
}
|
||||
|
||||
if (OnApproveFriendRequest != null)
|
||||
{
|
||||
OnApproveFriendRequest(this, agentID, transactionID, callingCardFolders);
|
||||
}
|
||||
|
||||
|
||||
break;
|
||||
case PacketType.TerminateFriendship:
|
||||
TerminateFriendshipPacket tfriendpack = (TerminateFriendshipPacket)Pack;
|
||||
LLUUID listOwnerAgentID = tfriendpack.AgentData.AgentID;
|
||||
LLUUID exFriendID = tfriendpack.ExBlock.OtherID;
|
||||
|
||||
if (OnTerminateFriendship != null)
|
||||
{
|
||||
OnTerminateFriendship(this, listOwnerAgentID, exFriendID);
|
||||
}
|
||||
|
||||
break;
|
||||
case PacketType.RezObject:
|
||||
RezObjectPacket rezPacket = (RezObjectPacket) Pack;
|
||||
if (OnRezObject != null)
|
||||
|
||||
Reference in New Issue
Block a user