mirror of
https://github.com/OpenDiablo2/OpenDiablo2
synced 2024-11-10 22:36:23 -05:00
db83814527
* d2mpq refactor * d2mpq refactor last standing lint error * d2mpq refactor: less linter noise * d2mpq refactor: more linter issues
17 lines
510 B
Go
17 lines
510 B
Go
package d2interface
|
|
|
|
// Archive is an abstract representation of a game archive file
|
|
// For the original Diablo II, archives are always MPQ's, but
|
|
// OpenDiablo2 can handle any kind of archive file as long as it
|
|
// implements this interface
|
|
type Archive interface {
|
|
Path() string
|
|
Contains(string) bool
|
|
Size() uint32
|
|
Close() error
|
|
ReadFile(fileName string) ([]byte, error)
|
|
ReadFileStream(fileName string) (DataStream, error)
|
|
ReadTextFile(fileName string) (string, error)
|
|
Listfile() ([]string, error)
|
|
}
|