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/DamageResult.cs | 320 +++++++++++++++++++++ 1 file changed, 320 insertions(+) create mode 100644 Client/Assets/Scripts/XMainClient/KKSG/DamageResult.cs (limited to 'Client/Assets/Scripts/XMainClient/KKSG/DamageResult.cs') diff --git a/Client/Assets/Scripts/XMainClient/KKSG/DamageResult.cs b/Client/Assets/Scripts/XMainClient/KKSG/DamageResult.cs new file mode 100644 index 00000000..b3bc0981 --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/KKSG/DamageResult.cs @@ -0,0 +1,320 @@ +using System; +using System.ComponentModel; +using System.Xml.Serialization; +using ProtoBuf; + +namespace KKSG +{ + [ProtoContract(Name = "DamageResult")] + [Serializable] + public class DamageResult : IExtensible + { + [ProtoMember(1, IsRequired = false, Name = "Result", DataFormat = DataFormat.TwosComplement)] + public uint Result + { + get + { + return this._Result ?? 0u; + } + set + { + this._Result = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool ResultSpecified + { + get + { + return this._Result != null; + } + set + { + bool flag = value == (this._Result == null); + if (flag) + { + this._Result = (value ? new uint?(this.Result) : null); + } + } + } + + [ProtoMember(2, IsRequired = false, Name = "Value", DataFormat = DataFormat.TwosComplement)] + public double Value + { + get + { + return this._Value ?? 0.0; + } + set + { + this._Value = new double?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool ValueSpecified + { + get + { + return this._Value != null; + } + set + { + bool flag = value == (this._Value == null); + if (flag) + { + this._Value = (value ? new double?(this.Value) : null); + } + } + } + + [ProtoMember(3, IsRequired = false, Name = "Flag", DataFormat = DataFormat.TwosComplement)] + public int Flag + { + get + { + return this._Flag ?? 0; + } + set + { + this._Flag = new int?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool FlagSpecified + { + get + { + return this._Flag != null; + } + set + { + bool flag = value == (this._Flag == null); + if (flag) + { + this._Flag = (value ? new int?(this.Flag) : null); + } + } + } + + [ProtoMember(4, IsRequired = false, Name = "DamageType", DataFormat = DataFormat.TwosComplement)] + public uint DamageType + { + get + { + return this._DamageType ?? 0u; + } + set + { + this._DamageType = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool DamageTypeSpecified + { + get + { + return this._DamageType != null; + } + set + { + bool flag = value == (this._DamageType == null); + if (flag) + { + this._DamageType = (value ? new uint?(this.DamageType) : null); + } + } + } + + [ProtoMember(5, IsRequired = false, Name = "ElementType", DataFormat = DataFormat.TwosComplement)] + public int ElementType + { + get + { + return this._ElementType ?? 0; + } + set + { + this._ElementType = new int?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool ElementTypeSpecified + { + get + { + return this._ElementType != null; + } + set + { + bool flag = value == (this._ElementType == null); + if (flag) + { + this._ElementType = (value ? new int?(this.ElementType) : null); + } + } + } + + [ProtoMember(6, IsRequired = false, Name = "IsTargetDead", DataFormat = DataFormat.Default)] + public bool IsTargetDead + { + get + { + return this._IsTargetDead ?? false; + } + set + { + this._IsTargetDead = new bool?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool IsTargetDeadSpecified + { + get + { + return this._IsTargetDead != null; + } + set + { + bool flag = value == (this._IsTargetDead == null); + if (flag) + { + this._IsTargetDead = (value ? new bool?(this.IsTargetDead) : null); + } + } + } + + [ProtoMember(7, IsRequired = false, Name = "ComboCount", DataFormat = DataFormat.TwosComplement)] + public int ComboCount + { + get + { + return this._ComboCount ?? 0; + } + set + { + this._ComboCount = new int?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool ComboCountSpecified + { + get + { + return this._ComboCount != null; + } + set + { + bool flag = value == (this._ComboCount == null); + if (flag) + { + this._ComboCount = (value ? new int?(this.ComboCount) : null); + } + } + } + + private uint? _Result; + + private double? _Value; + + private int? _Flag; + + private uint? _DamageType; + + private int? _ElementType; + + private bool? _IsTargetDead; + + private int? _ComboCount; + + private IExtension extensionObject; + + private bool ShouldSerializeResult() + { + return this.ResultSpecified; + } + + private void ResetResult() + { + this.ResultSpecified = false; + } + + private bool ShouldSerializeValue() + { + return this.ValueSpecified; + } + + private void ResetValue() + { + this.ValueSpecified = false; + } + + private bool ShouldSerializeFlag() + { + return this.FlagSpecified; + } + + private void ResetFlag() + { + this.FlagSpecified = false; + } + + private bool ShouldSerializeDamageType() + { + return this.DamageTypeSpecified; + } + + private void ResetDamageType() + { + this.DamageTypeSpecified = false; + } + + private bool ShouldSerializeElementType() + { + return this.ElementTypeSpecified; + } + + private void ResetElementType() + { + this.ElementTypeSpecified = false; + } + + private bool ShouldSerializeIsTargetDead() + { + return this.IsTargetDeadSpecified; + } + + private void ResetIsTargetDead() + { + this.IsTargetDeadSpecified = false; + } + + private bool ShouldSerializeComboCount() + { + return this.ComboCountSpecified; + } + + private void ResetComboCount() + { + this.ComboCountSpecified = false; + } + + IExtension IExtensible.GetExtensionObject(bool createIfMissing) + { + return Extensible.GetExtensionObject(ref this.extensionObject, createIfMissing); + } + } +} -- cgit v1.1-26-g67d0