From c351d287c7f3a970c7b794de810cd8ea8294e28e Mon Sep 17 00:00:00 2001 From: Jim Radford Date: Sat, 9 May 2009 00:35:06 +0000 Subject: [PATCH] LIBOMV-526 Adds ability to send a string message when requesting friendship with OfferFriendship method. git-svn-id: http://libopenmetaverse.googlecode.com/svn/libopenmetaverse/trunk@2724 52acb1d6-8a22-11de-b505-999d5b087335 --- OpenMetaverse/FriendsManager.cs | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/OpenMetaverse/FriendsManager.cs b/OpenMetaverse/FriendsManager.cs index 4c5aec37..9fcdb56b 100644 --- a/OpenMetaverse/FriendsManager.cs +++ b/OpenMetaverse/FriendsManager.cs @@ -390,10 +390,20 @@ namespace OpenMetaverse } /// - /// Offer friendship to an avatar. + /// Overload: Offer friendship to an avatar. /// /// System ID of the avatar you are offering friendship to public void OfferFriendship(UUID agentID) + { + OfferFriendship(agentID, "Do ya wanna be my buddy?"); + } + + /// + /// Offer friendship to an avatar. + /// + /// System ID of the avatar you are offering friendship to + /// A message to send with the request + public void OfferFriendship(UUID agentID, string message) { // HACK: folder id stored as "message" UUID callingCardFolder = Client.Inventory.FindFolderForType(AssetType.CallingCard); @@ -405,7 +415,7 @@ namespace OpenMetaverse InstantMessageOnline.Online, Client.Self.SimPosition, Client.Network.CurrentSim.ID, - Utils.EmptyBytes); + Utils.StringToBytes(message)); }