From 6eb915c129fc90c6f4c82ae097dd6ffad5239efc Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 25 Jan 2021 14:28:30 +0800 Subject: +scripts --- .../XMainClient/KKSG/HeroBattleTeamRoleData.cs | 128 +++++++++++++++++++++ 1 file changed, 128 insertions(+) create mode 100644 Client/Assets/Scripts/XMainClient/KKSG/HeroBattleTeamRoleData.cs (limited to 'Client/Assets/Scripts/XMainClient/KKSG/HeroBattleTeamRoleData.cs') diff --git a/Client/Assets/Scripts/XMainClient/KKSG/HeroBattleTeamRoleData.cs b/Client/Assets/Scripts/XMainClient/KKSG/HeroBattleTeamRoleData.cs new file mode 100644 index 00000000..2a36753b --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/KKSG/HeroBattleTeamRoleData.cs @@ -0,0 +1,128 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Xml.Serialization; +using ProtoBuf; + +namespace KKSG +{ + [ProtoContract(Name = "HeroBattleTeamRoleData")] + [Serializable] + public class HeroBattleTeamRoleData : IExtensible + { + [ProtoMember(1, IsRequired = false, Name = "team1", DataFormat = DataFormat.TwosComplement)] + public uint team1 + { + get + { + return this._team1 ?? 0u; + } + set + { + this._team1 = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool team1Specified + { + get + { + return this._team1 != null; + } + set + { + bool flag = value == (this._team1 == null); + if (flag) + { + this._team1 = (value ? new uint?(this.team1) : null); + } + } + } + + [ProtoMember(2, Name = "members1", DataFormat = DataFormat.Default)] + public List members1 + { + get + { + return this._members1; + } + } + + [ProtoMember(3, IsRequired = false, Name = "team2", DataFormat = DataFormat.TwosComplement)] + public uint team2 + { + get + { + return this._team2 ?? 0u; + } + set + { + this._team2 = new uint?(value); + } + } + + [XmlIgnore] + [Browsable(false)] + public bool team2Specified + { + get + { + return this._team2 != null; + } + set + { + bool flag = value == (this._team2 == null); + if (flag) + { + this._team2 = (value ? new uint?(this.team2) : null); + } + } + } + + [ProtoMember(4, Name = "members2", DataFormat = DataFormat.Default)] + public List members2 + { + get + { + return this._members2; + } + } + + private uint? _team1; + + private readonly List _members1 = new List(); + + private uint? _team2; + + private readonly List _members2 = new List(); + + private IExtension extensionObject; + + private bool ShouldSerializeteam1() + { + return this.team1Specified; + } + + private void Resetteam1() + { + this.team1Specified = false; + } + + private bool ShouldSerializeteam2() + { + return this.team2Specified; + } + + private void Resetteam2() + { + this.team2Specified = false; + } + + IExtension IExtensible.GetExtensionObject(bool createIfMissing) + { + return Extensible.GetExtensionObject(ref this.extensionObject, createIfMissing); + } + } +} -- cgit v1.1-26-g67d0