/// <summary>
        ///     Revokes the quest with the specified name for the PartyMember.
        /// </summary>
        /// <param name="name">The quest name, which must not be <c>null</c>.</param>
        /// <exception cref="ArgumentNullException"><paramref name="name" /> is <c>null</c>.</exception>
        public static void RevokeQuest(this PartyMember partyMember, string name)
        {
            if (name == null)
            {
                throw new ArgumentNullException(nameof(name));
            }

            var session = CustomQuestsPlugin.Instance.GetSession(partyMember);

            session.RevokeQuest(name);
        }
        public static void SendStatus(this PartyMember member, string status)
        {
            if (status == null)
            {
                throw new ArgumentNullException(nameof(status));
            }

            var text = status + "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n" +
                       "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n";

            member.Player.SendData(PacketTypes.Status, text);
        }
        public static void GiveItem(this PartyMember member, string name, int stackSize = 1, byte prefix = 0)
        {
            if (name == null)
            {
                throw new ArgumentNullException(nameof(name));
            }
            if (stackSize <= 0)
            {
                throw new ArgumentOutOfRangeException(nameof(stackSize), "Stack size must be positive.");
            }
            if (prefix > PrefixID.Count)
            {
                throw new ArgumentOutOfRangeException(nameof(prefix), "Prefix must be within range.");
            }

            var itemId = GetItemIdFromName(name);

            if (itemId == null)
            {
                throw new FormatException($"Invalid item name '{name}'.");
            }

            member.Player.GiveItem((int)itemId, "", 20, 42, stackSize, prefix);
        }
 /// <summary>
 ///     Sends the tile square to the PartyMember.
 /// </summary>
 /// <param name="x">The X coordinate.</param>
 /// <param name="y">The Y coordinate.</param>
 /// <exception cref="ArgumentOutOfRangeException"><paramref name="radius" /> is <c>null</c>.</exception>
 public static void SendTileSquare(PartyMember partyMember, int x, int y)
 {
     SendTileSquare(partyMember, x, y, 1);
 }
 public static void Teleport(this PartyMember member, int x, int y)
 {
     member.Player.Teleport(16 * x, 16 * y);
 }
        public static void RemoveItem(this PartyMember member, string name, int stackSize = 1, byte prefix = 0)
        {
            var members = new PartyMember[] { member };

            members.RemoveItem(name, stackSize, prefix);
        }
 public static void RemoveItem(this PartyMember member, string name)
 {
     member.RemoveItem(name, 1, 0);
 }
 public static void SendData(this PartyMember member, PacketTypes packetType, string text = "", int number = 0, float number2 = 0,
                             float number3 = 0, float number4 = 0, int number5 = 0)
 {
     member.Player.SendData(packetType, text, number, number2, number3, number4, number5);
 }
        public static void SendMessage(this PartyMember member, string message)
        {
            var color = Color.White;

            member.Player.SendMessage(message, color);
        }