Files
Main/Assets/Code/Logic/_NetMessage/Messages/UniverseEx.cs

748 lines
25 KiB
C#
Raw Permalink Normal View History

2025-01-25 04:38:09 +08:00
using System.Collections.Generic;
using Thousandto.Plugins.Common;
using Thousandto.Code.Logic.Network;
namespace MSG_Universe
{
public partial class UniverseMonsterInfo : ProtoBuf.IMessageInfo, ProtoBuf.IExtensible
{
public void Send(){}
public void Excute(){}
public void ReadMessage(ref int readPos, int totalCount)
{
int endIndex = totalCount + readPos - 1;
while (readPos <= endIndex)
{
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1 :
modelId = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2 :
type = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 3 :
refreshTime = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 4 :
care = ProtoBufUtils.ReadBoolean(ref readPos);
break;
default:
break;
}
}
}
public int WriteMessage(int fieldNumber)
{
ProtoBufUtils.WriteHeader(fieldNumber, ProtoBuf.WireType.String);
int subItemInfoId = ProtoBufUtils.GetSubItemInfoId();
ProtoBufUtils.SetEmptyLength(subItemInfoId);
ProtoBufUtils.SetVBeginIndex(subItemInfoId);
ProtoBufUtils.WriteInt32(1,modelId);
ProtoBufUtils.WriteInt32(2,type);
ProtoBufUtils.WriteInt32(3,refreshTime);
ProtoBufUtils.WriteBoolean(4,care);
ProtoBufUtils.SetVEndIndex(subItemInfoId);
return ProtoBufUtils.CheckAndSetLength(subItemInfoId);
}
public void Clear()
{
modelId = 0;
type = 0;
refreshTime = 0;
care = false;
}
public int modelId;
public int type;
public int refreshTime;
public bool care;
}
public partial class ReqUniverseWarPanel : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 525201;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
}
}
public partial class G2PReqUniverseWarPanel : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_G2PReqUniverseWarPanel(this);
}
public const uint MsgID = 525301;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
roleId = ProtoBufUtils.ReadInt64(ref readPos);
break;
case 2:
anger = ProtoBufUtils.ReadInt32(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
roleId = 0;
anger = 0;
}
public long roleId;
public int anger;
}
public partial class P2FReqUniverseWarPanel : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_P2FReqUniverseWarPanel(this);
}
public const uint MsgID = 525401;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
roleId = ProtoBufUtils.ReadInt64(ref readPos);
break;
case 2:
roomID = ProtoBufUtils.ReadInt64(ref readPos);
break;
case 3:
platServerId = ProtoBufUtils.ReadString(ref readPos);
break;
case 4:
anger = ProtoBufUtils.ReadInt32(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
roleId = 0;
roomID = 0;
platServerId = null;
anger = 0;
}
public long roleId;
public long roomID;
public string platServerId;
public int anger;
}
public partial class F2GResUniverseWarPanel : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_F2GResUniverseWarPanel(this);
}
public const uint MsgID = 525403;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
if(monsterInfos == null)
{
monsterInfos = new List<UniverseMonsterInfo>();
}
monsterInfos.Add(new UniverseMonsterInfo());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
monsterInfos[monsterInfos.Count - 1].ReadMessage(ref readPos, totalCount);
break;
case 2:
campBossHP = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 3:
finalBossHP = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 4:
anger = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 5:
roleId = ProtoBufUtils.ReadInt64(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
if(monsterInfos != null)
{
monsterInfos.Clear();
}
campBossHP = 0;
finalBossHP = 0;
anger = 0;
roleId = 0;
}
public List<UniverseMonsterInfo> monsterInfos = new List<UniverseMonsterInfo>();
public int campBossHP;
public int finalBossHP;
public int anger;
public long roleId;
}
public partial class ResUniverseWarPanel : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResUniverseWarPanel(this);
}
public const uint MsgID = 525101;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
if(monsterInfos == null)
{
monsterInfos = new List<UniverseMonsterInfo>();
}
monsterInfos.Add(new UniverseMonsterInfo());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
monsterInfos[monsterInfos.Count - 1].ReadMessage(ref readPos, totalCount);
break;
case 2:
campBossHP = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 3:
finalBossHP = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 4:
anger = ProtoBufUtils.ReadInt32(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
if(monsterInfos != null)
{
monsterInfos.Clear();
}
campBossHP = 0;
finalBossHP = 0;
anger = 0;
}
public List<UniverseMonsterInfo> monsterInfos = new List<UniverseMonsterInfo>();
public int campBossHP;
public int finalBossHP;
public int anger;
}
public partial class ReqCareMonster : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 525202;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteInt32(1,modelId);
ProtoBufUtils.WriteInt32(2,type);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
modelId = 0;
type = 0;
}
public int modelId;
public int type;
}
public partial class ResCareMonster : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResCareMonster(this);
}
public const uint MsgID = 525102;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
modelId = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2:
type = ProtoBufUtils.ReadInt32(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
modelId = 0;
type = 0;
}
public int modelId;
public int type;
}
public partial class ResSynAnger : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResSynAnger(this);
}
public const uint MsgID = 525103;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
anger = ProtoBufUtils.ReadInt32(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
anger = 0;
}
public int anger;
}
public partial class ResUpdateMonsterRefresh : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResUpdateMonsterRefresh(this);
}
public const uint MsgID = 525104;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
if(monsterInfos == null)
{
monsterInfos = new List<UniverseMonsterInfo>();
}
monsterInfos.Add(new UniverseMonsterInfo());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
monsterInfos[monsterInfos.Count - 1].ReadMessage(ref readPos, totalCount);
break;
default:
break;
}
}
}
}
public void Clear()
{
if(monsterInfos != null)
{
monsterInfos.Clear();
}
}
public List<UniverseMonsterInfo> monsterInfos = new List<UniverseMonsterInfo>();
}
public partial class G2PEnterDaily : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_G2PEnterDaily(this);
}
public const uint MsgID = 525302;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
roleId = ProtoBufUtils.ReadInt64(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
roleId = 0;
}
public long roleId;
}
public partial class P2FOpenBlock : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_P2FOpenBlock(this);
}
public const uint MsgID = 525402;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
roomID = ProtoBufUtils.ReadInt64(ref readPos);
break;
case 2:
open = ProtoBufUtils.ReadBoolean(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
roomID = 0;
open = false;
}
public long roomID;
public bool open;
}
public partial class DamageInfo : ProtoBuf.IMessageInfo, ProtoBuf.IExtensible
{
public void Send(){}
public void Excute(){}
public void ReadMessage(ref int readPos, int totalCount)
{
int endIndex = totalCount + readPos - 1;
while (readPos <= endIndex)
{
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1 :
rank = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2 :
name = ProtoBufUtils.ReadString(ref readPos);
break;
case 3 :
damage = ProtoBufUtils.ReadInt64(ref readPos);
break;
default:
break;
}
}
}
public int WriteMessage(int fieldNumber)
{
ProtoBufUtils.WriteHeader(fieldNumber, ProtoBuf.WireType.String);
int subItemInfoId = ProtoBufUtils.GetSubItemInfoId();
ProtoBufUtils.SetEmptyLength(subItemInfoId);
ProtoBufUtils.SetVBeginIndex(subItemInfoId);
ProtoBufUtils.WriteInt32(1,rank);
ProtoBufUtils.WriteString(2,name);
ProtoBufUtils.WriteInt64(3,damage);
ProtoBufUtils.SetVEndIndex(subItemInfoId);
return ProtoBufUtils.CheckAndSetLength(subItemInfoId);
}
public void Clear()
{
rank = 0;
name = null;
damage = 0;
}
public int rank;
public string name;
public long damage;
}
public partial class DamageRank : ProtoBuf.IMessageInfo, ProtoBuf.IExtensible
{
public void Send(){}
public void Excute(){}
public void ReadMessage(ref int readPos, int totalCount)
{
int endIndex = totalCount + readPos - 1;
while (readPos <= endIndex)
{
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1 :
if(damageList == null)
{
damageList = new List<DamageInfo>();
}
damageList.Add(new DamageInfo());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
damageList[damageList.Count - 1].ReadMessage(ref readPos, totalCount);
break;
case 2 :
if(myDamage == null)
{
myDamage = new DamageInfo();
}
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
myDamage.ReadMessage(ref readPos, totalCount);
break;
default:
break;
}
}
}
public int WriteMessage(int fieldNumber)
{
ProtoBufUtils.WriteHeader(fieldNumber, ProtoBuf.WireType.String);
int subItemInfoId = ProtoBufUtils.GetSubItemInfoId();
ProtoBufUtils.SetEmptyLength(subItemInfoId);
ProtoBufUtils.SetVBeginIndex(subItemInfoId);
for (int i = 0; i < damageList.Count; i++)
{
if(damageList != null)
{
damageList[i].WriteMessage(1);
}
}
if(myDamage != null)
{
myDamage.WriteMessage(2);
}
ProtoBufUtils.SetVEndIndex(subItemInfoId);
return ProtoBufUtils.CheckAndSetLength(subItemInfoId);
}
public void Clear()
{
if(damageList != null)
{
damageList.Clear();
}
if(myDamage != null)
{
myDamage.Clear();
}
}
public List<DamageInfo> damageList = new List<DamageInfo>();
public DamageInfo myDamage;
}
public partial class ReqDamageRank : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 525203;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteInt64(1,monsterId);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
monsterId = 0;
}
public long monsterId;
}
public partial class ResDamageRank : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResDamageRank(this);
}
public const uint MsgID = 525105;
public void Send(){}
public void ReadMessage(byte[] bytes)
{
lock (ProtoBufUtils.ReadLocker)
{
Clear();
int endIndex = bytes.Length - 1;
int readPos = 0;
int totalCount = 0;
ProtoBufUtils.InitReadData(bytes, ref readPos);
while (readPos <= endIndex)
{
int curType = bytes[readPos] & 7;
int fieldNumber = ProtoBufUtils.ReadFieldNumber(ref readPos);
switch (fieldNumber)
{
case 1:
if(playerRank == null)
{
playerRank = new DamageRank();
}
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
playerRank.ReadMessage(ref readPos, totalCount);
break;
case 2:
if(serverRank == null)
{
serverRank = new DamageRank();
}
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
serverRank.ReadMessage(ref readPos, totalCount);
break;
default:
break;
}
}
}
}
public void Clear()
{
if(playerRank != null)
{
playerRank.Clear();
}
if(serverRank != null)
{
serverRank.Clear();
}
}
public DamageRank playerRank;
public DamageRank serverRank;
}
}