namespace pkNX.Structures.FlatBuffers.ZA.Trinity;
attribute "fs_serializer";

table TrinityPropertySheetField1 { Value:ulong; FieldType:byte; }
table TrinityPropertySheetField2 { Value:uint;  FieldType:byte; }
table TrinityPropertySheetFieldStringValue { Value:string (required); }
table TrinityPropertySheetField4 { }
table TrinityPropertySheetField5 { }
table TrinityPropertySheetField6 { }
table TrinityPropertySheetFieldEnumName { Enum:string (required); Value:uint; }

 /// Recursive!
table TrinityPropertySheetObject { Fields:[TrinityPropertySheetField] (required); }

union TrinityPropertySheetValue {
    TrinityPropertySheetField1,
    TrinityPropertySheetField2,
    TrinityPropertySheetFieldStringValue,
    TrinityPropertySheetField4,
    TrinityPropertySheetField5,
    TrinityPropertySheetField6,
    TrinityPropertySheetFieldEnumName,
    TrinityPropertySheetObjectArray,
    TrinityPropertySheetObject
}

table TrinityPropertySheetObjectArray { Value:[TrinityPropertySheetValue] (required); }

table TrinityPropertySheetField {
    Name:string (required);
    Data:TrinityPropertySheetValue (required);
}

table TrinityPropertySheet (fs_serializer) {
    Name:string (required);
    Extra:string (required);
    Properties:[TrinityPropertySheetObject] (required);
}

root_type TrinityPropertySheet;
