From 6eb915c129fc90c6f4c82ae097dd6ffad5239efc Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 25 Jan 2021 14:28:30 +0800 Subject: +scripts --- .../Assets/Scripts/XMainClient/KKSG/PandoraDrop.cs | 257 +++++++++++++++++++++ 1 file changed, 257 insertions(+) create mode 100644 Client/Assets/Scripts/XMainClient/KKSG/PandoraDrop.cs (limited to 'Client/Assets/Scripts/XMainClient/KKSG/PandoraDrop.cs') diff --git a/Client/Assets/Scripts/XMainClient/KKSG/PandoraDrop.cs b/Client/Assets/Scripts/XMainClient/KKSG/PandoraDrop.cs new file mode 100644 index 00000000..cc1f4d9b --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/KKSG/PandoraDrop.cs @@ -0,0 +1,257 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Xml.Serialization; +using ProtoBuf; + +namespace KKSG +{ + [ProtoContract(Name = "PandoraDrop")] + [Serializable] + public class PandoraDrop : IExtensible + { + [ProtoMember(1, IsRequired = false, Name = "pandoraDropID", DataFormat = DataFormat.TwosComplement)] + public uint pandoraDropID + { + get + { + return this._pandoraDropID ?? 0u; + } + set + { + this._pandoraDropID = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool pandoraDropIDSpecified + { + get + { + return this._pandoraDropID != null; + } + set + { + bool flag = value == (this._pandoraDropID == null); + if (flag) + { + this._pandoraDropID = (value ? new uint?(this.pandoraDropID) : null); + } + } + } + + [ProtoMember(2, IsRequired = false, Name = "betterDropTimes", DataFormat = DataFormat.TwosComplement)] + public uint betterDropTimes + { + get + { + return this._betterDropTimes ?? 0u; + } + set + { + this._betterDropTimes = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool betterDropTimesSpecified + { + get + { + return this._betterDropTimes != null; + } + set + { + bool flag = value == (this._betterDropTimes == null); + if (flag) + { + this._betterDropTimes = (value ? new uint?(this.betterDropTimes) : null); + } + } + } + + [ProtoMember(3, IsRequired = false, Name = "noUsedBestDropTimes", DataFormat = DataFormat.TwosComplement)] + public uint noUsedBestDropTimes + { + get + { + return this._noUsedBestDropTimes ?? 0u; + } + set + { + this._noUsedBestDropTimes = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool noUsedBestDropTimesSpecified + { + get + { + return this._noUsedBestDropTimes != null; + } + set + { + bool flag = value == (this._noUsedBestDropTimes == null); + if (flag) + { + this._noUsedBestDropTimes = (value ? new uint?(this.noUsedBestDropTimes) : null); + } + } + } + + [ProtoMember(4, IsRequired = false, Name = "nextBetterDropTimes", DataFormat = DataFormat.TwosComplement)] + public uint nextBetterDropTimes + { + get + { + return this._nextBetterDropTimes ?? 0u; + } + set + { + this._nextBetterDropTimes = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool nextBetterDropTimesSpecified + { + get + { + return this._nextBetterDropTimes != null; + } + set + { + bool flag = value == (this._nextBetterDropTimes == null); + if (flag) + { + this._nextBetterDropTimes = (value ? new uint?(this.nextBetterDropTimes) : null); + } + } + } + + [ProtoMember(5, IsRequired = false, Name = "noUsedNextBestDropTimes", DataFormat = DataFormat.TwosComplement)] + public uint noUsedNextBestDropTimes + { + get + { + return this._noUsedNextBestDropTimes ?? 0u; + } + set + { + this._noUsedNextBestDropTimes = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool noUsedNextBestDropTimesSpecified + { + get + { + return this._noUsedNextBestDropTimes != null; + } + set + { + bool flag = value == (this._noUsedNextBestDropTimes == null); + if (flag) + { + this._noUsedNextBestDropTimes = (value ? new uint?(this.noUsedNextBestDropTimes) : null); + } + } + } + + [ProtoMember(6, Name = "bestDropTimes", DataFormat = DataFormat.TwosComplement)] + public List bestDropTimes + { + get + { + return this._bestDropTimes; + } + } + + [ProtoMember(7, Name = "nextBestDropTimes", DataFormat = DataFormat.TwosComplement)] + public List nextBestDropTimes + { + get + { + return this._nextBestDropTimes; + } + } + + private uint? _pandoraDropID; + + private uint? _betterDropTimes; + + private uint? _noUsedBestDropTimes; + + private uint? _nextBetterDropTimes; + + private uint? _noUsedNextBestDropTimes; + + private readonly List _bestDropTimes = new List(); + + private readonly List _nextBestDropTimes = new List(); + + private IExtension extensionObject; + + private bool ShouldSerializepandoraDropID() + { + return this.pandoraDropIDSpecified; + } + + private void ResetpandoraDropID() + { + this.pandoraDropIDSpecified = false; + } + + private bool ShouldSerializebetterDropTimes() + { + return this.betterDropTimesSpecified; + } + + private void ResetbetterDropTimes() + { + this.betterDropTimesSpecified = false; + } + + private bool ShouldSerializenoUsedBestDropTimes() + { + return this.noUsedBestDropTimesSpecified; + } + + private void ResetnoUsedBestDropTimes() + { + this.noUsedBestDropTimesSpecified = false; + } + + private bool ShouldSerializenextBetterDropTimes() + { + return this.nextBetterDropTimesSpecified; + } + + private void ResetnextBetterDropTimes() + { + this.nextBetterDropTimesSpecified = false; + } + + private bool ShouldSerializenoUsedNextBestDropTimes() + { + return this.noUsedNextBestDropTimesSpecified; + } + + private void ResetnoUsedNextBestDropTimes() + { + this.noUsedNextBestDropTimesSpecified = false; + } + + IExtension IExtensible.GetExtensionObject(bool createIfMissing) + { + return Extensible.GetExtensionObject(ref this.extensionObject, createIfMissing); + } + } +} -- cgit v1.1-26-g67d0