TrinityCore
Loading...
Searching...
No Matches
loadlib.h
Go to the documentation of this file.
1
/*
2
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
3
*
4
* This program is free software; you can redistribute it and/or modify it
5
* under the terms of the GNU General Public License as published by the
6
* Free Software Foundation; either version 2 of the License, or (at your
7
* option) any later version.
8
*
9
* This program is distributed in the hope that it will be useful, but WITHOUT
10
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12
* more details.
13
*
14
* You should have received a copy of the GNU General Public License along
15
* with this program. If not, see <http://www.gnu.org/licenses/>.
16
*/
17
18
#ifndef LOAD_LIB_H
19
#define LOAD_LIB_H
20
21
#include "
Define.h
"
22
23
#define FILE_FORMAT_VERSION 18
24
25
#pragma pack(push, 1)
26
27
//
28
// File version chunk
29
//
30
struct
file_MVER
31
{
32
union
{
33
uint32
fcc
;
34
char
fcc_txt
[4];
35
};
36
uint32
size
;
37
uint32
ver
;
38
};
39
40
class
FileLoader
{
41
uint8
*
data
;
42
uint32
data_size
;
43
public
:
44
virtual
bool
prepareLoadedData
();
45
uint8
*
GetData
() {
return
data
;}
46
uint32
GetDataSize
() {
return
data_size
;}
47
48
file_MVER
*
version
;
49
FileLoader
();
50
~FileLoader
();
51
bool
loadFile
(
char
*filename,
bool
log =
true
);
52
virtual
void
free
();
53
};
54
55
#pragma pack(pop)
56
57
#endif
Define.h
uint8
uint8_t uint8
Definition
Define.h:135
uint32
uint32_t uint32
Definition
Define.h:133
FileLoader
Definition
loadlib.h:48
FileLoader::~FileLoader
~FileLoader()
FileLoader::GetDataSize
uint32 GetDataSize()
Definition
loadlib.h:46
FileLoader::data_size
uint32 data_size
Definition
loadlib.h:50
FileLoader::version
file_MVER * version
Definition
loadlib.h:56
FileLoader::prepareLoadedData
virtual bool prepareLoadedData()
FileLoader::loadFile
bool loadFile(char *filename, bool log=true)
FileLoader::FileLoader
FileLoader()
FileLoader::GetData
uint8 * GetData()
Definition
loadlib.h:45
FileLoader::free
virtual void free()
FileLoader::data
uint8 * data
Definition
loadlib.h:49
file_MVER
Definition
loadlib.h:39
file_MVER::size
uint32 size
Definition
loadlib.h:44
file_MVER::fcc_txt
char fcc_txt[4]
Definition
loadlib.h:42
file_MVER::ver
uint32 ver
Definition
loadlib.h:45
file_MVER::fcc
uint32 fcc
Definition
loadlib.h:41
tools
vmap4_extractor
loadlib
loadlib.h
Generated on Sun May 10 2026 02:30:26 for TrinityCore by
1.9.8