升级框架
This commit is contained in:
@@ -1,311 +1,592 @@
|
||||
using ProtoBuf;
|
||||
|
||||
using LightProto;
|
||||
using MemoryPack;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
using Fantasy;
|
||||
using Fantasy.Pool;
|
||||
using Fantasy.Network.Interface;
|
||||
using Fantasy.Serialize;
|
||||
|
||||
// ReSharper disable InconsistentNaming
|
||||
// ReSharper disable RedundantUsingDirective
|
||||
// ReSharper disable RedundantOverriddenMember
|
||||
// ReSharper disable CollectionNeverUpdated.Global
|
||||
// ReSharper disable RedundantTypeArgumentsOfMethod
|
||||
// ReSharper disable PartialTypeWithSinglePart
|
||||
// ReSharper disable UnusedAutoPropertyAccessor.Global
|
||||
// ReSharper disable PreferConcreteValueOverDefault
|
||||
// ReSharper disable RedundantNameQualifier
|
||||
// ReSharper disable MemberCanBePrivate.Global
|
||||
// ReSharper disable CheckNamespace
|
||||
// ReSharper disable FieldCanBeMadeReadOnly.Global
|
||||
// ReSharper disable RedundantUsingDirective
|
||||
// ReSharper disable ConditionIsAlwaysTrueOrFalseAccordingToNullableAPIContract
|
||||
#pragma warning disable CS8625 // Cannot convert null literal to non-nullable reference type.
|
||||
#pragma warning disable CS8618
|
||||
|
||||
namespace Fantasy
|
||||
{
|
||||
/// <summary>
|
||||
/// 通知游戏服角色进入该游戏服
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class G2Common_EnterRequest : AMessage, IRouteRequest
|
||||
{
|
||||
public static G2Common_EnterRequest Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<G2Common_EnterRequest>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
AccountId = default;
|
||||
GateRouteId = default;
|
||||
RouteType = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<G2Common_EnterRequest>(this);
|
||||
#endif
|
||||
}
|
||||
[ProtoIgnore]
|
||||
public G2Common_EnterResponse ResponseType { get; set; }
|
||||
public uint OpCode() { return InnerOpcode.G2Common_EnterRequest; }
|
||||
[ProtoMember(1)]
|
||||
public long AccountId { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long GateRouteId { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public int RouteType { get; set; }
|
||||
}
|
||||
[ProtoContract]
|
||||
public partial class G2Common_EnterResponse : AMessage, IRouteResponse
|
||||
{
|
||||
public static G2Common_EnterResponse Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<G2Common_EnterResponse>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
ErrorCode = default;
|
||||
UnitRouteId = default;
|
||||
RouteType = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<G2Common_EnterResponse>(this);
|
||||
#endif
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2Common_EnterResponse; }
|
||||
[ProtoMember(1)]
|
||||
public long UnitRouteId { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public int RouteType { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public uint ErrorCode { get; set; }
|
||||
}
|
||||
[ProtoContract]
|
||||
public partial class G2Common_ExitRequest : AMessage, IRouteRequest
|
||||
{
|
||||
public static G2Common_ExitRequest Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<G2Common_ExitRequest>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
AccountId = default;
|
||||
GateRouteId = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<G2Common_ExitRequest>(this);
|
||||
#endif
|
||||
}
|
||||
[ProtoIgnore]
|
||||
public Common2G_ExitResponse ResponseType { get; set; }
|
||||
public uint OpCode() { return InnerOpcode.G2Common_ExitRequest; }
|
||||
[ProtoMember(1)]
|
||||
public long AccountId { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long GateRouteId { get; set; }
|
||||
}
|
||||
[ProtoContract]
|
||||
public partial class Common2G_ExitResponse : AMessage, IRouteResponse
|
||||
{
|
||||
public static Common2G_ExitResponse Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<Common2G_ExitResponse>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
ErrorCode = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<Common2G_ExitResponse>(this);
|
||||
#endif
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Common2G_ExitResponse; }
|
||||
[ProtoMember(1)]
|
||||
public uint ErrorCode { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 获取玩家基础信息
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class S2G_GetPlayerBasicInfoRequest : AMessage, IRouteRequest
|
||||
{
|
||||
public static S2G_GetPlayerBasicInfoRequest Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<S2G_GetPlayerBasicInfoRequest>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
IdList.Clear();
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<S2G_GetPlayerBasicInfoRequest>(this);
|
||||
#endif
|
||||
}
|
||||
[ProtoIgnore]
|
||||
public G2S_GetPlayerBasicInfoResponse ResponseType { get; set; }
|
||||
public uint OpCode() { return InnerOpcode.S2G_GetPlayerBasicInfoRequest; }
|
||||
[ProtoMember(1)]
|
||||
public List<long> IdList = new List<long>();
|
||||
}
|
||||
/// <summary>
|
||||
/// 获取玩家基础信息响应
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class G2S_GetPlayerBasicInfoResponse : AMessage, IRouteResponse
|
||||
{
|
||||
public static G2S_GetPlayerBasicInfoResponse Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<G2S_GetPlayerBasicInfoResponse>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
ErrorCode = default;
|
||||
RoleList.Clear();
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<G2S_GetPlayerBasicInfoResponse>(this);
|
||||
#endif
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2S_GetPlayerBasicInfoResponse; }
|
||||
[ProtoMember(1)]
|
||||
public List<RoleSimpleInfo> RoleList = new List<RoleSimpleInfo>();
|
||||
[ProtoMember(2)]
|
||||
public uint ErrorCode { get; set; }
|
||||
}
|
||||
[ProtoContract]
|
||||
public partial class S2G_ChatMessage : AMessage, IRouteMessage
|
||||
{
|
||||
public static S2G_ChatMessage Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<S2G_ChatMessage>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
Message = default;
|
||||
IdList.Clear();
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<S2G_ChatMessage>(this);
|
||||
#endif
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.S2G_ChatMessage; }
|
||||
[ProtoMember(1)]
|
||||
public ChatMessageInfo Message { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public List<long> IdList = new List<long>();
|
||||
}
|
||||
/// <summary>
|
||||
/// 创建聊天频道
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class Club2Chat_CreateChannel : AMessage, IRouteMessage
|
||||
{
|
||||
public static Club2Chat_CreateChannel Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<Club2Chat_CreateChannel>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
ChannelId = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<Club2Chat_CreateChannel>(this);
|
||||
#endif
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Club2Chat_CreateChannel; }
|
||||
[ProtoMember(1)]
|
||||
public long ChannelId { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求进入房间
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class G2Map_EnterMapRequest : AMessage, IRouteRequest
|
||||
{
|
||||
public static G2Map_EnterMapRequest Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<G2Map_EnterMapRequest>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
RoomCode = default;
|
||||
AccountId = default;
|
||||
MapId = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<G2Map_EnterMapRequest>(this);
|
||||
#endif
|
||||
}
|
||||
[ProtoIgnore]
|
||||
public Map2G_EnterMapResponse ResponseType { get; set; }
|
||||
public uint OpCode() { return InnerOpcode.G2Map_EnterMapRequest; }
|
||||
[ProtoMember(1)]
|
||||
public string RoomCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long AccountId { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public int MapId { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求进入房间响应
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class Map2G_EnterMapResponse : AMessage, IRouteResponse
|
||||
{
|
||||
public static Map2G_EnterMapResponse Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<Map2G_EnterMapResponse>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
ErrorCode = default;
|
||||
RoomCode = default;
|
||||
MapId = default;
|
||||
Units.Clear();
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<Map2G_EnterMapResponse>(this);
|
||||
#endif
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Map2G_EnterMapResponse; }
|
||||
[ProtoMember(1)]
|
||||
public string RoomCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public int MapId { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public List<MapUnitInfo> Units = new List<MapUnitInfo>();
|
||||
[ProtoMember(4)]
|
||||
public uint ErrorCode { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求离开房间
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class G2Map_ExitRoomRequest : AMessage, IRouteRequest
|
||||
{
|
||||
public static G2Map_ExitRoomRequest Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<G2Map_ExitRoomRequest>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
RoomCode = default;
|
||||
AccountId = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<G2Map_ExitRoomRequest>(this);
|
||||
#endif
|
||||
}
|
||||
[ProtoIgnore]
|
||||
public Map2G_ExiRoomResponse ResponseType { get; set; }
|
||||
public uint OpCode() { return InnerOpcode.G2Map_ExitRoomRequest; }
|
||||
[ProtoMember(1)]
|
||||
public string RoomCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long AccountId { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求离开房间响应
|
||||
/// </summary>
|
||||
[ProtoContract]
|
||||
public partial class Map2G_ExiRoomResponse : AMessage, IRouteResponse
|
||||
{
|
||||
public static Map2G_ExiRoomResponse Create(Scene scene)
|
||||
{
|
||||
return scene.MessagePoolComponent.Rent<Map2G_ExiRoomResponse>();
|
||||
}
|
||||
public override void Dispose()
|
||||
{
|
||||
ErrorCode = default;
|
||||
#if FANTASY_NET || FANTASY_UNITY
|
||||
GetScene().MessagePoolComponent.Return<Map2G_ExiRoomResponse>(this);
|
||||
#endif
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Map2G_ExiRoomResponse; }
|
||||
[ProtoMember(1)]
|
||||
public uint ErrorCode { get; set; }
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 通知游戏服角色进入该游戏服
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class G2Common_EnterRequest : AMessage, IAddressRequest
|
||||
{
|
||||
public static G2Common_EnterRequest Create(bool autoReturn = true)
|
||||
{
|
||||
var g2Common_EnterRequest = MessageObjectPool<G2Common_EnterRequest>.Rent();
|
||||
g2Common_EnterRequest.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
g2Common_EnterRequest.SetIsPool(false);
|
||||
}
|
||||
|
||||
return g2Common_EnterRequest;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
AccountId = default;
|
||||
GateRouteId = default;
|
||||
RouteType = default;
|
||||
MessageObjectPool<G2Common_EnterRequest>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2Common_EnterRequest; }
|
||||
[ProtoIgnore]
|
||||
public G2Common_EnterResponse ResponseType { get; set; }
|
||||
[ProtoMember(1)]
|
||||
public long AccountId { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long GateRouteId { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public int RouteType { get; set; }
|
||||
}
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class G2Common_EnterResponse : AMessage, IAddressResponse
|
||||
{
|
||||
public static G2Common_EnterResponse Create(bool autoReturn = true)
|
||||
{
|
||||
var g2Common_EnterResponse = MessageObjectPool<G2Common_EnterResponse>.Rent();
|
||||
g2Common_EnterResponse.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
g2Common_EnterResponse.SetIsPool(false);
|
||||
}
|
||||
|
||||
return g2Common_EnterResponse;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
ErrorCode = 0;
|
||||
UnitRouteId = default;
|
||||
RouteType = default;
|
||||
MessageObjectPool<G2Common_EnterResponse>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2Common_EnterResponse; }
|
||||
[ProtoMember(1)]
|
||||
public uint ErrorCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long UnitRouteId { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public int RouteType { get; set; }
|
||||
}
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class G2Common_ExitRequest : AMessage, IAddressRequest
|
||||
{
|
||||
public static G2Common_ExitRequest Create(bool autoReturn = true)
|
||||
{
|
||||
var g2Common_ExitRequest = MessageObjectPool<G2Common_ExitRequest>.Rent();
|
||||
g2Common_ExitRequest.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
g2Common_ExitRequest.SetIsPool(false);
|
||||
}
|
||||
|
||||
return g2Common_ExitRequest;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
AccountId = default;
|
||||
GateRouteId = default;
|
||||
MessageObjectPool<G2Common_ExitRequest>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2Common_ExitRequest; }
|
||||
[ProtoIgnore]
|
||||
public Common2G_ExitResponse ResponseType { get; set; }
|
||||
[ProtoMember(1)]
|
||||
public long AccountId { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long GateRouteId { get; set; }
|
||||
}
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class Common2G_ExitResponse : AMessage, IAddressResponse
|
||||
{
|
||||
public static Common2G_ExitResponse Create(bool autoReturn = true)
|
||||
{
|
||||
var common2G_ExitResponse = MessageObjectPool<Common2G_ExitResponse>.Rent();
|
||||
common2G_ExitResponse.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
common2G_ExitResponse.SetIsPool(false);
|
||||
}
|
||||
|
||||
return common2G_ExitResponse;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
ErrorCode = 0;
|
||||
MessageObjectPool<Common2G_ExitResponse>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Common2G_ExitResponse; }
|
||||
[ProtoMember(1)]
|
||||
public uint ErrorCode { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 获取玩家基础信息
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class S2G_GetPlayerBasicInfoRequest : AMessage, IAddressRequest
|
||||
{
|
||||
public static S2G_GetPlayerBasicInfoRequest Create(bool autoReturn = true)
|
||||
{
|
||||
var s2G_GetPlayerBasicInfoRequest = MessageObjectPool<S2G_GetPlayerBasicInfoRequest>.Rent();
|
||||
s2G_GetPlayerBasicInfoRequest.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
s2G_GetPlayerBasicInfoRequest.SetIsPool(false);
|
||||
}
|
||||
|
||||
return s2G_GetPlayerBasicInfoRequest;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
IdList.Clear();
|
||||
MessageObjectPool<S2G_GetPlayerBasicInfoRequest>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.S2G_GetPlayerBasicInfoRequest; }
|
||||
[ProtoIgnore]
|
||||
public G2S_GetPlayerBasicInfoResponse ResponseType { get; set; }
|
||||
[ProtoMember(1)]
|
||||
public List<long> IdList { get; set; } = new List<long>();
|
||||
}
|
||||
/// <summary>
|
||||
/// 获取玩家基础信息响应
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class G2S_GetPlayerBasicInfoResponse : AMessage, IAddressResponse
|
||||
{
|
||||
public static G2S_GetPlayerBasicInfoResponse Create(bool autoReturn = true)
|
||||
{
|
||||
var g2S_GetPlayerBasicInfoResponse = MessageObjectPool<G2S_GetPlayerBasicInfoResponse>.Rent();
|
||||
g2S_GetPlayerBasicInfoResponse.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
g2S_GetPlayerBasicInfoResponse.SetIsPool(false);
|
||||
}
|
||||
|
||||
return g2S_GetPlayerBasicInfoResponse;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
ErrorCode = 0;
|
||||
RoleList.Clear();
|
||||
MessageObjectPool<G2S_GetPlayerBasicInfoResponse>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2S_GetPlayerBasicInfoResponse; }
|
||||
[ProtoMember(1)]
|
||||
public uint ErrorCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public List<RoleSimpleInfo> RoleList { get; set; } = new List<RoleSimpleInfo>();
|
||||
}
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class S2G_ChatMessage : AMessage, IAddressMessage
|
||||
{
|
||||
public static S2G_ChatMessage Create(bool autoReturn = true)
|
||||
{
|
||||
var s2G_ChatMessage = MessageObjectPool<S2G_ChatMessage>.Rent();
|
||||
s2G_ChatMessage.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
s2G_ChatMessage.SetIsPool(false);
|
||||
}
|
||||
|
||||
return s2G_ChatMessage;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
Message = default;
|
||||
IdList.Clear();
|
||||
MessageObjectPool<S2G_ChatMessage>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.S2G_ChatMessage; }
|
||||
[ProtoMember(1)]
|
||||
public ChatMessageInfo Message { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public List<long> IdList { get; set; } = new List<long>();
|
||||
}
|
||||
/// <summary>
|
||||
/// 创建聊天频道
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class Club2Chat_CreateChannel : AMessage, IAddressMessage
|
||||
{
|
||||
public static Club2Chat_CreateChannel Create(bool autoReturn = true)
|
||||
{
|
||||
var club2Chat_CreateChannel = MessageObjectPool<Club2Chat_CreateChannel>.Rent();
|
||||
club2Chat_CreateChannel.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
club2Chat_CreateChannel.SetIsPool(false);
|
||||
}
|
||||
|
||||
return club2Chat_CreateChannel;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
ChannelId = default;
|
||||
MessageObjectPool<Club2Chat_CreateChannel>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Club2Chat_CreateChannel; }
|
||||
[ProtoMember(1)]
|
||||
public long ChannelId { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求进入房间
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class G2Map_EnterMapRequest : AMessage, IAddressRequest
|
||||
{
|
||||
public static G2Map_EnterMapRequest Create(bool autoReturn = true)
|
||||
{
|
||||
var g2Map_EnterMapRequest = MessageObjectPool<G2Map_EnterMapRequest>.Rent();
|
||||
g2Map_EnterMapRequest.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
g2Map_EnterMapRequest.SetIsPool(false);
|
||||
}
|
||||
|
||||
return g2Map_EnterMapRequest;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
RoomCode = default;
|
||||
AccountId = default;
|
||||
MapId = default;
|
||||
MessageObjectPool<G2Map_EnterMapRequest>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2Map_EnterMapRequest; }
|
||||
[ProtoIgnore]
|
||||
public Map2G_EnterMapResponse ResponseType { get; set; }
|
||||
[ProtoMember(1)]
|
||||
public string RoomCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long AccountId { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public int MapId { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求进入房间响应
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class Map2G_EnterMapResponse : AMessage, IAddressResponse
|
||||
{
|
||||
public static Map2G_EnterMapResponse Create(bool autoReturn = true)
|
||||
{
|
||||
var map2G_EnterMapResponse = MessageObjectPool<Map2G_EnterMapResponse>.Rent();
|
||||
map2G_EnterMapResponse.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
map2G_EnterMapResponse.SetIsPool(false);
|
||||
}
|
||||
|
||||
return map2G_EnterMapResponse;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
ErrorCode = 0;
|
||||
RoomCode = default;
|
||||
MapId = default;
|
||||
Units.Clear();
|
||||
MessageObjectPool<Map2G_EnterMapResponse>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Map2G_EnterMapResponse; }
|
||||
[ProtoMember(1)]
|
||||
public uint ErrorCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public string RoomCode { get; set; }
|
||||
[ProtoMember(3)]
|
||||
public int MapId { get; set; }
|
||||
[ProtoMember(4)]
|
||||
public List<MapUnitInfo> Units { get; set; } = new List<MapUnitInfo>();
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求离开房间
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class G2Map_ExitRoomRequest : AMessage, IAddressRequest
|
||||
{
|
||||
public static G2Map_ExitRoomRequest Create(bool autoReturn = true)
|
||||
{
|
||||
var g2Map_ExitRoomRequest = MessageObjectPool<G2Map_ExitRoomRequest>.Rent();
|
||||
g2Map_ExitRoomRequest.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
g2Map_ExitRoomRequest.SetIsPool(false);
|
||||
}
|
||||
|
||||
return g2Map_ExitRoomRequest;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
RoomCode = default;
|
||||
AccountId = default;
|
||||
MessageObjectPool<G2Map_ExitRoomRequest>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.G2Map_ExitRoomRequest; }
|
||||
[ProtoIgnore]
|
||||
public Map2G_ExiRoomResponse ResponseType { get; set; }
|
||||
[ProtoMember(1)]
|
||||
public string RoomCode { get; set; }
|
||||
[ProtoMember(2)]
|
||||
public long AccountId { get; set; }
|
||||
}
|
||||
/// <summary>
|
||||
/// 请求离开房间响应
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
[ProtoContract]
|
||||
public partial class Map2G_ExiRoomResponse : AMessage, IAddressResponse
|
||||
{
|
||||
public static Map2G_ExiRoomResponse Create(bool autoReturn = true)
|
||||
{
|
||||
var map2G_ExiRoomResponse = MessageObjectPool<Map2G_ExiRoomResponse>.Rent();
|
||||
map2G_ExiRoomResponse.AutoReturn = autoReturn;
|
||||
|
||||
if (!autoReturn)
|
||||
{
|
||||
map2G_ExiRoomResponse.SetIsPool(false);
|
||||
}
|
||||
|
||||
return map2G_ExiRoomResponse;
|
||||
}
|
||||
|
||||
public void Return()
|
||||
{
|
||||
if (!AutoReturn)
|
||||
{
|
||||
SetIsPool(true);
|
||||
AutoReturn = true;
|
||||
}
|
||||
else if (!IsPool())
|
||||
{
|
||||
return;
|
||||
}
|
||||
Dispose();
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (!IsPool()) return;
|
||||
ErrorCode = 0;
|
||||
MessageObjectPool<Map2G_ExiRoomResponse>.Return(this);
|
||||
}
|
||||
public uint OpCode() { return InnerOpcode.Map2G_ExiRoomResponse; }
|
||||
[ProtoMember(1)]
|
||||
public uint ErrorCode { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user