From 6eb915c129fc90c6f4c82ae097dd6ffad5239efc Mon Sep 17 00:00:00 2001 From: chai Date: Mon, 25 Jan 2021 14:28:30 +0800 Subject: +scripts --- Client/Assets/Scripts/XMainClient/XOutLookAttr.cs | 54 +++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 Client/Assets/Scripts/XMainClient/XOutLookAttr.cs (limited to 'Client/Assets/Scripts/XMainClient/XOutLookAttr.cs') diff --git a/Client/Assets/Scripts/XMainClient/XOutLookAttr.cs b/Client/Assets/Scripts/XMainClient/XOutLookAttr.cs new file mode 100644 index 00000000..13798992 --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/XOutLookAttr.cs @@ -0,0 +1,54 @@ +using System; +using System.Collections.Generic; +using KKSG; + +namespace XMainClient +{ + public class XOutLookAttr + { + public OutLookGuild guild = null; + + public uint designationID = 0u; + + public string specialDesignation = ""; + + public uint titleID = 0u; + + public uint militaryRank = 0u; + + public uint prerogativeScore = 0u; + + public List prerogativeSetID; + + public XOutLookAttr(OutLook outlook) + { + this.guild = ((outlook != null) ? outlook.guild : null); + this.designationID = ((outlook != null && outlook.designation != null) ? outlook.designation.id : 0u); + this.specialDesignation = ((outlook != null && outlook.designation != null) ? outlook.designation.name : ""); + this.titleID = ((outlook != null && outlook.title != null) ? outlook.title.titleID : 0u); + this.militaryRank = ((outlook != null && outlook.military != null) ? outlook.military.military_rank : 0u); + bool flag = outlook == null || outlook.pre == null; + if (flag) + { + this.prerogativeScore = 0u; + this.prerogativeSetID = null; + } + else + { + this.prerogativeScore = outlook.pre.score; + this.prerogativeSetID = outlook.pre.setid; + } + } + + public XOutLookAttr(uint title, MilitaryRecord military) + { + this.titleID = title; + this.militaryRank = ((military != null) ? military.military_rank : 0u); + } + + public XOutLookAttr(OutLookGuild outguild) + { + this.guild = outguild; + } + } +} -- cgit v1.1-26-g67d0