예제 #1
0
 public CombatStyle()
 {
     EditorID     = new SimpleSubrecord <String>("EDID");
     DecisionData = new CombatStyleDecision("CSTD");
     AdvancedData = new CombatStyleAdvanced("CSAD");
     SimpleData   = new CombatStyleSimple("CSSD");
 }
예제 #2
0
 public CombatStyle(SimpleSubrecord <String> EditorID, CombatStyleDecision DecisionData, CombatStyleAdvanced AdvancedData, CombatStyleSimple SimpleData)
 {
     this.EditorID     = EditorID;
     this.DecisionData = DecisionData;
     this.AdvancedData = AdvancedData;
     this.SimpleData   = SimpleData;
 }
예제 #3
0
        public override void ReadData(ESPReader reader, long dataEnd)
        {
            while (reader.BaseStream.Position < dataEnd)
            {
                string subTag = reader.PeekTag();

                switch (subTag)
                {
                case "EDID":
                    if (EditorID == null)
                    {
                        EditorID = new SimpleSubrecord <String>();
                    }

                    EditorID.ReadBinary(reader);
                    break;

                case "CSTD":
                    if (DecisionData == null)
                    {
                        DecisionData = new CombatStyleDecision();
                    }

                    DecisionData.ReadBinary(reader);
                    break;

                case "CSAD":
                    if (AdvancedData == null)
                    {
                        AdvancedData = new CombatStyleAdvanced();
                    }

                    AdvancedData.ReadBinary(reader);
                    break;

                case "CSSD":
                    if (SimpleData == null)
                    {
                        SimpleData = new CombatStyleSimple();
                    }

                    SimpleData.ReadBinary(reader);
                    break;

                default:
                    throw new Exception();
                }
            }
        }
예제 #4
0
        public override void ReadDataXML(XElement ele, ElderScrollsPlugin master)
        {
            XElement subEle;

            if (ele.TryPathTo("EditorID", false, out subEle))
            {
                if (EditorID == null)
                {
                    EditorID = new SimpleSubrecord <String>();
                }

                EditorID.ReadXML(subEle, master);
            }
            if (ele.TryPathTo("DecisionData", false, out subEle))
            {
                if (DecisionData == null)
                {
                    DecisionData = new CombatStyleDecision();
                }

                DecisionData.ReadXML(subEle, master);
            }
            if (ele.TryPathTo("AdvancedData", false, out subEle))
            {
                if (AdvancedData == null)
                {
                    AdvancedData = new CombatStyleAdvanced();
                }

                AdvancedData.ReadXML(subEle, master);
            }
            if (ele.TryPathTo("SimpleData", false, out subEle))
            {
                if (SimpleData == null)
                {
                    SimpleData = new CombatStyleSimple();
                }

                SimpleData.ReadXML(subEle, master);
            }
        }