public void Read(FileReader reader)
            {
                reader.ByteOrder = Syroot.BinaryData.ByteOrder.LittleEndian;
                reader.ReadSignature(4, "XLNK");
                uint FileSize                         = reader.ReadUInt32();
                uint Version                          = reader.ReadUInt32();
                uint numResParam                      = reader.ReadUInt32();
                uint numResAssetParam                 = reader.ReadUInt32();
                uint numResTriggerOverwriteParam      = reader.ReadUInt32();
                uint triggerOverwriteParamTablePos    = reader.ReadUInt32();
                uint localPropertyNameRefTablePos     = reader.ReadUInt32();
                uint numLocalPropertyNameRefTable     = reader.ReadUInt32();
                uint numLocalPropertyEnumNameRefTable = reader.ReadUInt32();
                uint numDirectValueTable              = reader.ReadUInt32();
                uint numRandomTable                   = reader.ReadUInt32();
                uint numCurveTable                    = reader.ReadUInt32();
                uint numCurvePointTable               = reader.ReadUInt32();
                uint exRegionPos                      = reader.ReadUInt32();
                uint numUser                          = reader.ReadUInt32();
                uint conditionTablePos                = reader.ReadUInt32();
                uint nameTablePos                     = reader.ReadUInt32();

                UserDataTable = new UserDataTable();
                UserDataTable.Read(reader, (int)numUser);

                ParamDefineTable = new ParamDefineTable();
                ParamDefineTable.Read(reader);
            }
Example #2
0
            public void Read(FileReader reader)
            {
                reader.ByteOrder = Syroot.BinaryData.ByteOrder.LittleEndian;
                reader.ReadSignature(4, "XLNK");
                uint FileSize                         = reader.ReadUInt32();
                uint Version                          = reader.ReadUInt32();
                uint numResParam                      = reader.ReadUInt32();
                uint numResAssetParam                 = reader.ReadUInt32();
                uint numResTriggerOverwriteParam      = reader.ReadUInt32();
                uint triggerOverwriteParamTablePos    = reader.ReadUInt32();
                uint localPropertyNameRefTablePos     = reader.ReadUInt32();
                uint numLocalPropertyNameRefTable     = reader.ReadUInt32();
                uint numLocalPropertyEnumNameRefTable = reader.ReadUInt32();
                uint numDirectValueTable              = reader.ReadUInt32();
                uint numRandomTable                   = reader.ReadUInt32();
                uint numCurveTable                    = reader.ReadUInt32();
                uint numCurvePointTable               = reader.ReadUInt32();
                uint exRegionPos                      = reader.ReadUInt32();
                uint numUser                          = reader.ReadUInt32();
                uint conditionTablePos                = reader.ReadUInt32();

                nameTablePos = reader.ReadUInt32();

                UserDataTable = new UserDataTable();
                UserDataTable.Read(reader, (int)numUser);

                ParamDefineTable = new ParamDefineTable();
                ParamDefineTable.Read(reader, this);

                for (int i = 0; i < numResAssetParam; i++)
                {
                    var resAssetsParam = new ResourceAssetParamTable();
                    resAssetsParam.Read(reader);
                    ResourceAssetParamTables.Add(resAssetsParam);
                }

                reader.SeekBegin(triggerOverwriteParamTablePos);
                for (int i = 0; i < numResTriggerOverwriteParam; i++)
                {
                    var triggerOverwriteParamTbl = new TriggerOverwriteParamTable();
                    triggerOverwriteParamTbl.Read(reader);
                    TriggerOverwriteParamTables.Add(triggerOverwriteParamTbl);
                }

                reader.SeekBegin(localPropertyNameRefTablePos);
                for (int i = 0; i < numLocalPropertyNameRefTable; i++)
                {
                    var localNameProp = new LocalNameProperty();
                    localNameProp.Read(reader, nameTablePos);
                    LocalNameProperties.Add(localNameProp);
                }

                for (int i = 0; i < numLocalPropertyEnumNameRefTable; i++)
                {
                    var localNameProp = new LocalNameProperty();
                    localNameProp.Read(reader, nameTablePos);
                    LocalNameEnumProperties.Add(localNameProp);
                }
            }