Documentation
¶
Index ¶
Constants ¶
const MagicWDBC = 0x43424457
MagicWDBC is the constant corresponding to "WDBC" in ASCII. 0x57 = 'W', 0x44 = 'D', 0x42 = 'B', 0x43 = 'C'
Variables ¶
This section is empty.
Functions ¶
func UnmarshalRecords ¶
UnmarshalRecords reads raw records into a slice of user-defined structures (e.g., *[]ChrClassesRecord). It uses tags like: `dbc:"column=0,type=uint32"`. Supports basic types: int32/uint32/float32/float64 and strings (via offset). For localized columns (offset + mask), the logic can be extended if needed.
Types ¶
type File ¶
type File struct { Header Header RawRecords []byte // length = RecordCount * RecordSize StringBlock []byte // length = StringBlockSize }
File describes the structure of a read DBC file in raw form.
func MarshalRecords ¶
MarshalRecords performs the reverse operation — forms raw records in a DBCFile from the given slice of structures. Simplified: generates a new stringBlock and sets string offsets. For localized strings with a bitmask (0), reserves 2 columns (offset, mask=0).