Exemple #1
0
        public override Definition ParseMain(BinaryReader f, int RecNo)
        {
            var ret = new Definition();

            if (RConfig.Instance.DatVersionAsEnum >= DatVersion.Gracia_Final)
            {
                var info = new EtcitemgrpInfo_Gracia_Final();
                info.InitFieldValues();

                info = (EtcitemgrpInfo_Gracia_Final)base.ReadFieldValue(f, info, "tag", "UNK_0");
                info = (EtcitemgrpInfo_Gracia_Final)base.ReadFieldValue(f, info, "drop_mesh1", "UNK_1");
                info = (EtcitemgrpInfo_Gracia_Final)base.ReadFieldValue(f, info, "UNK_2");
                info = (EtcitemgrpInfo_Gracia_Final)base.ReadFieldValue(f, info, "UNK_3");
                info = (EtcitemgrpInfo_Gracia_Final)base.ReadFieldValue(f, info, "fort", "grade");

                ret = info;
            }
            else if (RConfig.Instance.DatVersionAsEnum >= DatVersion.Kamael)
            {
                var info = new EtcitemgrpInfo_CT1();
                info.InitFieldValues();
                info = (EtcitemgrpInfo_CT1)base.ReadFieldValue(f, info, "tag", "UNK_1");
                if (RConfig.Instance.DatVersionAsEnum >= DatVersion.HellBound)
                {
                    info = (EtcitemgrpInfo_CT1)base.ReadFieldValue(f, info, "UNK_2");
                }
                if (RConfig.Instance.DatVersionAsEnum >= DatVersion.Gracia_1__Gracia_2)
                {
                    info = (EtcitemgrpInfo_CT1)base.ReadFieldValue(f, info, "UNK_3");
                }
                info = (EtcitemgrpInfo_CT1)base.ReadFieldValue(f, info, "fort", "grade");
                ret  = info;
            }
            else if (RConfig.Instance.DatVersionAsEnum >= DatVersion.C4)
            {
                var info = new EtcitemgrpInfo_C4();
                info = (EtcitemgrpInfo_C4)base.ReadFieldValue(f, info, "tag", "grade");
                ret  = info;
            }
            else
            {
                var info = new EtcitemgrpInfo();
                info = (EtcitemgrpInfo)base.ReadFieldValue(f, info, "tag", "grade");
                ret  = info;
            }
            return(ret);
        }
Exemple #2
0
        public override Definition ParseMain(BinaryReader f, int RecNo)
        {
            var ret = new Definition();

            if (RConfig.Instance.DatVersionAsEnum >= DatVersion.Gracia_Final)
            {
                var info = new EtcitemgrpInfo_Gracia_Final();
                info.InitFieldValues();

                info = (EtcitemgrpInfo_Gracia_Final) base.ReadFieldValue(f, info, "tag", "UNK_0");
                info = (EtcitemgrpInfo_Gracia_Final) base.ReadFieldValue(f, info, "drop_mesh1", "UNK_1");
                info = (EtcitemgrpInfo_Gracia_Final) base.ReadFieldValue(f, info, "UNK_2");
                info = (EtcitemgrpInfo_Gracia_Final) base.ReadFieldValue(f, info, "UNK_3");
                info = (EtcitemgrpInfo_Gracia_Final) base.ReadFieldValue(f, info, "fort", "grade");

                ret = info;
            }
            else if (RConfig.Instance.DatVersionAsEnum >= DatVersion.Kamael)
            {
                var info = new EtcitemgrpInfo_CT1();
                info.InitFieldValues();
                info = (EtcitemgrpInfo_CT1) base.ReadFieldValue(f, info, "tag", "UNK_1");
                if (RConfig.Instance.DatVersionAsEnum >= DatVersion.HellBound)
                    info = (EtcitemgrpInfo_CT1) base.ReadFieldValue(f, info, "UNK_2");
                if (RConfig.Instance.DatVersionAsEnum >= DatVersion.Gracia_1__Gracia_2)
                    info = (EtcitemgrpInfo_CT1) base.ReadFieldValue(f, info, "UNK_3");
                info = (EtcitemgrpInfo_CT1) base.ReadFieldValue(f, info, "fort", "grade");
                ret = info;
            }
            else if (RConfig.Instance.DatVersionAsEnum >= DatVersion.C4)
            {
                var info = new EtcitemgrpInfo_C4();
                info = (EtcitemgrpInfo_C4) base.ReadFieldValue(f, info, "tag", "grade");
                ret = info;
            }
            else
            {
                var info = new EtcitemgrpInfo();
                info = (EtcitemgrpInfo) base.ReadFieldValue(f, info, "tag", "grade");
                ret = info;
            }
            return ret;
        }