Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FalloutDat ¶
type FalloutDat interface { GetGame() uint8 GetDirs() []FalloutDir GetDbg() dbg.Map // SetDbg adds various debug info // // If argument is `nil`, all data (including directories data) is cleared; // otherwise data is collected starting from currect stream position // // - stream must be set to same position it was when reading DAT file // - `cmd/fodat(dump)` can be used to display debug info SetDbg(io.Seeker) error // contains filtered or unexported methods }
FalloutDat represents single .dat file
NOTE: Unstable interface
func Fallout1 ¶
func Fallout1(stream io.ReadSeeker) (dat1 FalloutDat, err error)
Fallout1 reads already opened stream as DAT1
func Fallout2 ¶
func Fallout2(stream io.ReadSeeker) (dat2 FalloutDat, err error)
Fallout2 reads already opened stream as DAT2
type FalloutDir ¶
type FalloutDir interface { GetParentDat() FalloutDat GetName() string // returns base name (NAME) GetPath() string // returns full path (DIR//NAME) GetFiles() []FalloutFile GetDbg() dbg.Map // SetDbg adds various debug info // // If argument is `nil`, all data (including files data) is cleared SetDbg(io.Seeker) error }
FalloutDat represents single directory entry
NOTE: Unstable interface
type FalloutFile ¶
type FalloutFile interface { GetParentDat() FalloutDat GetParentDir() FalloutDir GetName() string // returns base name (FILENAME.EXT) GetPath() string // returns full path (DIR/NAME/FILENAME.EXT) GetOffset() int64 GetSizeReal() int64 GetSizePacked() int64 GetPacked() bool GetPackedMode() uint32 GetBytesReal(io.ReadSeeker) ([]byte, error) GetBytesPacked(io.ReadSeeker) ([]byte, error) GetBytesUnpacked([]byte) ([]byte, error) GetDbg() dbg.Map // SetDbg adds various debug info // // If argument is `nil`, all data is cleared SetDbg(io.Seeker) error }
FalloutFile represents a single file entry
NOTE: Unstable interface
Click to show internal directories.
Click to hide internal directories.