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

681 lines
22 KiB
C#
Raw 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_Recharge
{
public partial class SubTypeTime : 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 :
subtype = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2 :
remiantime = 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,subtype);
ProtoBufUtils.WriteInt64(2,remiantime);
ProtoBufUtils.SetVEndIndex(subItemInfoId);
return ProtoBufUtils.CheckAndSetLength(subItemInfoId);
}
public void Clear()
{
subtype = 0;
remiantime = 0;
}
public int subtype;
public long remiantime;
}
public partial class ResRechargeTotalValue : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResRechargeTotalValue(this);
}
public const uint MsgID = 139101;
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:
goldTotal = ProtoBufUtils.ReadInt32(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
goldTotal = 0;
}
public int goldTotal;
}
public partial class ReqRechargeData : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139201;
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 RechargeItem : 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 :
id = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2 :
count = ProtoBufUtils.ReadInt32(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,id);
ProtoBufUtils.WriteInt32(2,count);
ProtoBufUtils.SetVEndIndex(subItemInfoId);
return ProtoBufUtils.CheckAndSetLength(subItemInfoId);
}
public void Clear()
{
id = 0;
count = 0;
}
public int id;
public int count;
}
public partial class ResRechargeData : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResRechargeData(this);
}
public const uint MsgID = 139102;
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(items == null)
{
items = new List<RechargeItem>();
}
items.Add(new RechargeItem());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
items[items.Count - 1].ReadMessage(ref readPos, totalCount);
break;
case 2:
if(typeTime == null)
{
typeTime = new List<SubTypeTime>();
}
typeTime.Add(new SubTypeTime());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
typeTime[typeTime.Count - 1].ReadMessage(ref readPos, totalCount);
break;
default:
break;
}
}
}
}
public void Clear()
{
if(items != null)
{
items.Clear();
}
if(typeTime != null)
{
typeTime.Clear();
}
}
public List<RechargeItem> items = new List<RechargeItem>();
public List<SubTypeTime> typeTime = new List<SubTypeTime>();
}
public partial class ReqRecharge : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139202;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteInt32(1,id);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
id = 0;
}
public int id;
}
public partial class DiscountRechargeItem : 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 :
id = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2 :
count = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 3 :
timeout = ProtoBufUtils.ReadInt32(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,id);
ProtoBufUtils.WriteInt32(2,count);
ProtoBufUtils.WriteInt32(3,timeout);
ProtoBufUtils.SetVEndIndex(subItemInfoId);
return ProtoBufUtils.CheckAndSetLength(subItemInfoId);
}
public void Clear()
{
id = 0;
count = 0;
timeout = 0;
}
public int id;
public int count;
public int timeout;
}
public partial class ResDiscountRechargeData : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResDiscountRechargeData(this);
}
public const uint MsgID = 139103;
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(items == null)
{
items = new List<DiscountRechargeItem>();
}
items.Add(new DiscountRechargeItem());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
items[items.Count - 1].ReadMessage(ref readPos, totalCount);
break;
case 2:
first = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 3:
type = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 4:
freeGoodsRemainTime = ProtoBufUtils.ReadInt64(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
if(items != null)
{
items.Clear();
}
first = 0;
type = 0;
freeGoodsRemainTime = 0;
}
public List<DiscountRechargeItem> items = new List<DiscountRechargeItem>();
public int first;
public int type;
public long freeGoodsRemainTime;
}
public partial class ReqDiscountRecharge : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139203;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteInt32(1,type);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
type = 0;
}
public int type;
}
public partial class ReqCheckGoodsIsCanbuy : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139204;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteInt32(1,id);
ProtoBufUtils.WriteString(2,moneyType);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
id = 0;
moneyType = null;
}
public int id;
public string moneyType;
}
public partial class ResCheckGoodsResult : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResCheckGoodsResult(this);
}
public const uint MsgID = 139104;
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:
result = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2:
id = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 3:
orderInfo = ProtoBufUtils.ReadString(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
result = 0;
id = 0;
orderInfo = null;
}
public int result;
public int id;
public string orderInfo;
}
public partial class ResRechargeItems : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResRechargeItems(this);
}
public const uint MsgID = 139105;
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:
rechargeItemJson = ProtoBufUtils.ReadString(ref readPos);
break;
case 2:
md5 = ProtoBufUtils.ReadString(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
rechargeItemJson = null;
md5 = null;
}
public string rechargeItemJson;
public string md5;
}
public partial class ReqCheckRechargeMd5 : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139205;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteString(1,md5);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
md5 = null;
}
public string md5;
}
public partial class CheckDiscState : 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 :
goodsId = ProtoBufUtils.ReadInt32(ref readPos);
break;
case 2 :
state = ProtoBufUtils.ReadInt32(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,goodsId);
ProtoBufUtils.WriteInt32(2,state);
ProtoBufUtils.SetVEndIndex(subItemInfoId);
return ProtoBufUtils.CheckAndSetLength(subItemInfoId);
}
public void Clear()
{
goodsId = 0;
state = 0;
}
public int goodsId;
public int state;
}
public partial class ResCheckDiscRechargeGoods : ProtoBuf.IExtensible, ProtoBuf.IResMessage
{
public void Excute()
{
HandleMsgResult.getInstance().GS2U_ResCheckDiscRechargeGoods(this);
}
public const uint MsgID = 139106;
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(check == null)
{
check = new List<CheckDiscState>();
}
check.Add(new CheckDiscState());
totalCount = ProtoBufUtils.ReadInt32(ref readPos);
check[check.Count - 1].ReadMessage(ref readPos, totalCount);
break;
case 2:
type = ProtoBufUtils.ReadInt32(ref readPos);
break;
default:
break;
}
}
}
}
public void Clear()
{
if(check != null)
{
check.Clear();
}
type = 0;
}
public List<CheckDiscState> check = new List<CheckDiscState>();
public int type;
}
public partial class ReqCheckDiscRechargeGoods : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139206;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
for (int i = 0; i < goodsId.Count; i++)
{
ProtoBufUtils.WriteInt32(1,goodsId[i]);
}
ProtoBufUtils.WriteInt32(2,type);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
if(goodsId != null)
{
goodsId.Clear();
}
type = 0;
}
public List<int> goodsId = new List<int>();
public int type;
}
public partial class ReqDiscRechargeBuyGoods : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139207;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteInt32(1,goodsId);
ProtoBufUtils.WriteInt32(2,count);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
goodsId = 0;
count = 0;
}
public int goodsId;
public int count;
}
public partial class ReqGetFreeDiscGoods : ProtoBuf.IExtensible, ProtoBuf.IReqMessage
{
public const uint MsgID = 139208;
public void Excute(){}
public void Send()
{
lock (ProtoBufUtils.WriteLocker)
{
byte[] bytes = null;
ProtoBufUtils.InitWriteData();
ProtoBufUtils.WriteInt32(1,type);
bytes = ProtoBufUtils.GetData();
Thousandto.Plugins.Common.Networker.Instance.Send(bytes, MsgID);
}
}
public void Clear()
{
type = 0;
}
public int type;
}
}