This commit is contained in:
2025-08-07 09:17:13 +08:00
parent 246ab02390
commit abb211e0da
24 changed files with 492 additions and 8486 deletions

View File

@@ -221,7 +221,7 @@ namespace NBC
[ProtoMember(5)]
public long GetTime { get; set; }
[ProtoMember(6)]
public long Abrasion { get; set; }
public int Abrasion { get; set; }
}
/// <summary>
/// fish信息

View File

@@ -21,10 +21,11 @@ namespace NBC
Id = default;
Title = default;
Content = default;
SendTime = default;
Type = default;
CreateTime = default;
ExpireTime = default;
MailType = default;
MailState = default;
Items.Clear();
IsRead = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<MailInfo>(this);
#endif
@@ -36,12 +37,14 @@ namespace NBC
[ProtoMember(3)]
public string Content { get; set; }
[ProtoMember(4)]
public long SendTime { get; set; }
public long CreateTime { get; set; }
[ProtoMember(5)]
public int Type { get; set; }
public long ExpireTime { get; set; }
[ProtoMember(6)]
public List<AwardInfo> Items = new List<AwardInfo>();
public int MailType { get; set; }
[ProtoMember(7)]
public bool IsRead { get; set; }
public int MailState { get; set; }
[ProtoMember(8)]
public List<AwardInfo> Items = new List<AwardInfo>();
}
}

View File

@@ -21,6 +21,7 @@ namespace NBC
Username = default;
Password = default;
LoginType = default;
Region = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<C2A_LoginRequest>(this);
#endif
@@ -34,6 +35,8 @@ namespace NBC
public string Password { get; set; }
[ProtoMember(3)]
public int LoginType { get; set; }
[ProtoMember(4)]
public int Region { get; set; }
}
[ProtoContract]
public partial class A2C_LoginResponse : AMessage, IResponse, IProto
@@ -184,4 +187,165 @@ namespace NBC
[ProtoMember(3)]
public uint ErrorCode { get; set; }
}
/// <summary>
/// 请求邮件列表
/// </summary>
[ProtoContract]
public partial class C2Game_GetMailsRequest : AMessage, ICustomRouteRequest, IProto
{
public static C2Game_GetMailsRequest Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<C2Game_GetMailsRequest>();
}
public override void Dispose()
{
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<C2Game_GetMailsRequest>(this);
#endif
}
[ProtoIgnore]
public Game2C_GetMailsResponse ResponseType { get; set; }
public uint OpCode() { return OuterOpcode.C2Game_GetMailsRequest; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.GameRoute;
}
/// <summary>
/// 获取邮件列表响应
/// </summary>
[ProtoContract]
public partial class Game2C_GetMailsResponse : AMessage, ICustomRouteResponse, IProto
{
public static Game2C_GetMailsResponse Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<Game2C_GetMailsResponse>();
}
public override void Dispose()
{
ErrorCode = default;
Mail.Clear();
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<Game2C_GetMailsResponse>(this);
#endif
}
public uint OpCode() { return OuterOpcode.Game2C_GetMailsResponse; }
[ProtoMember(1)]
public List<MailInfo> Mail = new List<MailInfo>();
[ProtoMember(2)]
public uint ErrorCode { get; set; }
}
/// <summary>
/// 新邮件推送
/// </summary>
[ProtoContract]
public partial class Game2C_HaveMail : AMessage, ICustomRouteMessage, IProto
{
public static Game2C_HaveMail Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<Game2C_HaveMail>();
}
public override void Dispose()
{
Mail = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<Game2C_HaveMail>(this);
#endif
}
public uint OpCode() { return OuterOpcode.Game2C_HaveMail; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public MailInfo Mail { get; set; }
}
[ProtoContract]
public partial class Game2C_MailState : AMessage, ICustomRouteMessage, IProto
{
public static Game2C_MailState Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<Game2C_MailState>();
}
public override void Dispose()
{
MailState = default;
MailId = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<Game2C_MailState>(this);
#endif
}
public uint OpCode() { return OuterOpcode.Game2C_MailState; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.GameRoute;
[ProtoMember(1)]
public int MailState { get; set; }
[ProtoMember(2)]
public long MailId { get; set; }
}
/// <summary>
/// 发送聊天
/// </summary>
[ProtoContract]
public partial class C2Chat_SendMessageRequest : AMessage, ICustomRouteRequest, IProto
{
public static C2Chat_SendMessageRequest Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<C2Chat_SendMessageRequest>();
}
public override void Dispose()
{
Message = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<C2Chat_SendMessageRequest>(this);
#endif
}
[ProtoIgnore]
public Caht2C_SendMessageResponse ResponseType { get; set; }
public uint OpCode() { return OuterOpcode.C2Chat_SendMessageRequest; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.ChatRoute;
[ProtoMember(1)]
public string Message { get; set; }
}
/// <summary>
/// 发送聊天响应
/// </summary>
[ProtoContract]
public partial class Caht2C_SendMessageResponse : AMessage, ICustomRouteResponse, IProto
{
public static Caht2C_SendMessageResponse Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<Caht2C_SendMessageResponse>();
}
public override void Dispose()
{
ErrorCode = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<Caht2C_SendMessageResponse>(this);
#endif
}
public uint OpCode() { return OuterOpcode.Caht2C_SendMessageResponse; }
[ProtoMember(1)]
public uint ErrorCode { get; set; }
}
/// <summary>
/// 推送消息
/// </summary>
[ProtoContract]
public partial class Chat2C_Message : AMessage, ICustomRouteMessage, IProto
{
public static Chat2C_Message Create(Scene scene)
{
return scene.MessagePoolComponent.Rent<Chat2C_Message>();
}
public override void Dispose()
{
Message = default;
#if FANTASY_NET || FANTASY_UNITY
GetScene().MessagePoolComponent.Return<Chat2C_Message>(this);
#endif
}
public uint OpCode() { return OuterOpcode.Chat2C_Message; }
[ProtoIgnore]
public int RouteType => Fantasy.RouteType.ChatRoute;
[ProtoMember(1)]
public string Message { get; set; }
}
}

View File

@@ -9,5 +9,12 @@ namespace Fantasy
public const uint G2C_RepeatLogin = 134227729;
public const uint C2Game_GetRoleInfoRequest = 2281711377;
public const uint Game2C_GetRoleInfoResponse = 2415929105;
public const uint C2Game_GetMailsRequest = 2281711378;
public const uint Game2C_GetMailsResponse = 2415929106;
public const uint Game2C_HaveMail = 2147493649;
public const uint Game2C_MailState = 2147493650;
public const uint C2Chat_SendMessageRequest = 2281711379;
public const uint Caht2C_SendMessageResponse = 2415929107;
public const uint Chat2C_Message = 2147493651;
}
}