use crate::{ common_strings::COMMON_STRINGS, helper::{AlignExt, Endianness, ReadExt}, }; use anyhow::Result; use log::{debug, trace}; use std::io::{Cursor, Read, Seek}; #[derive(Debug)] pub struct TypeTreeNode { pub version: u16, pub level: u8, pub type_flags: u8, pub type_string: String, pub name_string: String, pub byte_size: i32, pub index: i32, pub flags: i32, pub ref_type_hash: u64, } #[derive(Debug)] pub struct SeralizedType { pub class_id: i32, pub stripped_type: bool, pub script_type_index: i16, pub script_id: u128, pub type_tree: Vec, pub type_deps: Vec, } #[derive(Debug)] pub struct ObjectInfo { path_id: i64, data_offset: u64, data_size: u32, type_id: i32, } #[derive(Debug)] pub struct Script { file_index: u32, identifier: i64, } #[derive(Debug)] pub struct External { something: String, guid: u128, r#type: i32, path_name: String, } #[derive(Debug)] pub struct SerializedFile { pub types: Vec, pub externals: Vec, pub scripts: Vec