using MessagePack;
#if GameClient
using GameFramework;
#endif

namespace GameMessage
{
    [Message(MessageCode.ClubCreateRequest)]
    [MessagePackObject]
    public class ClubCreateRequest : MessageData
    {
        /// <summary>
        /// 俱乐部名称
        /// </summary>
        [Key(0)] public string ClubName;

        /// <summary>
        /// 公告
        /// </summary>
        [Key(1)] public string Notice;

#if GameClient
        public static ClubCreateRequest Create(string clubName,string notice)
        {
            ClubCreateRequest request = ReferencePool.Acquire<ClubCreateRequest>();
            request.ClubName = clubName;
            request.Notice = notice;
            return request;
        }

        public override void Clear()
        {
            ClubName = null;
            Notice = null;
        }
#endif
    }

    [Message(MessageCode.ClubCreateResponse)]
    [MessagePackObject]
    public class ClubCreateResponse : MessageData
    {
        [Key(0)] public ClubBasicInfo BasicInfo;

        [Key(1)] public int ResultCode;
    }
}