From 6eb915c129fc90c6f4c82ae097dd6ffad5239efc Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 25 Jan 2021 14:28:30 +0800 Subject: +scripts --- .../Scripts/XMainClient/KKSG/PayPrivilegeShop.cs | 148 +++++++++++++++++++++ 1 file changed, 148 insertions(+) create mode 100644 Client/Assets/Scripts/XMainClient/KKSG/PayPrivilegeShop.cs (limited to 'Client/Assets/Scripts/XMainClient/KKSG/PayPrivilegeShop.cs') diff --git a/Client/Assets/Scripts/XMainClient/KKSG/PayPrivilegeShop.cs b/Client/Assets/Scripts/XMainClient/KKSG/PayPrivilegeShop.cs new file mode 100644 index 00000000..85a7dca4 --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/KKSG/PayPrivilegeShop.cs @@ -0,0 +1,148 @@ +using System; +using System.ComponentModel; +using System.Xml.Serialization; +using ProtoBuf; + +namespace KKSG +{ + [ProtoContract(Name = "PayPrivilegeShop")] + [Serializable] + public class PayPrivilegeShop : IExtensible + { + [ProtoMember(1, IsRequired = false, Name = "goodsID", DataFormat = DataFormat.TwosComplement)] + public int goodsID + { + get + { + return this._goodsID ?? 0; + } + set + { + this._goodsID = new int?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool goodsIDSpecified + { + get + { + return this._goodsID != null; + } + set + { + bool flag = value == (this._goodsID == null); + if (flag) + { + this._goodsID = (value ? new int?(this.goodsID) : null); + } + } + } + + [ProtoMember(2, IsRequired = false, Name = "totalCount", DataFormat = DataFormat.TwosComplement)] + public int totalCount + { + get + { + return this._totalCount ?? 0; + } + set + { + this._totalCount = new int?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool totalCountSpecified + { + get + { + return this._totalCount != null; + } + set + { + bool flag = value == (this._totalCount == null); + if (flag) + { + this._totalCount = (value ? new int?(this.totalCount) : null); + } + } + } + + [ProtoMember(3, IsRequired = false, Name = "usedCount", DataFormat = DataFormat.TwosComplement)] + public int usedCount + { + get + { + return this._usedCount ?? 0; + } + set + { + this._usedCount = new int?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool usedCountSpecified + { + get + { + return this._usedCount != null; + } + set + { + bool flag = value == (this._usedCount == null); + if (flag) + { + this._usedCount = (value ? new int?(this.usedCount) : null); + } + } + } + + private int? _goodsID; + + private int? _totalCount; + + private int? _usedCount; + + private IExtension extensionObject; + + private bool ShouldSerializegoodsID() + { + return this.goodsIDSpecified; + } + + private void ResetgoodsID() + { + this.goodsIDSpecified = false; + } + + private bool ShouldSerializetotalCount() + { + return this.totalCountSpecified; + } + + private void ResettotalCount() + { + this.totalCountSpecified = false; + } + + private bool ShouldSerializeusedCount() + { + return this.usedCountSpecified; + } + + private void ResetusedCount() + { + this.usedCountSpecified = false; + } + + IExtension IExtensible.GetExtensionObject(bool createIfMissing) + { + return Extensible.GetExtensionObject(ref this.extensionObject, createIfMissing); + } + } +} -- cgit v1.1-26-g67d0