-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathtileset.h
executable file
·45 lines (38 loc) · 1002 Bytes
/
tileset.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#ifndef TILESET_H
#define TILESET_H
#include "tile.h"
#include <QImage>
class Metatile;
class Tileset
{
public:
Tileset();
public:
QString name;
QString is_compressed;
QString is_secondary;
QString padding;
QString tiles_label;
QString palettes_label;
QString metatiles_label;
QString callback_label;
QString metatile_attrs_label;
QList<QImage> *tiles = NULL;
QList<Metatile*> *metatiles = NULL;
QList<QList<QRgb>> *palettes = NULL;
};
class Metatile
{
public:
Metatile();
public:
QList<Tile> *tiles = NULL;
int attr;
static QImage getMetatileImage(int, Tileset*, Tileset*);
static Metatile* getMetatile(int, Tileset*, Tileset*);
static QImage getMetatileTile(int, Tileset*, Tileset*);
static Tileset* getBlockTileset(int, Tileset*, Tileset*);
static int getBlockIndex(int);
static QList<QList<QRgb>> getBlockPalettes(Tileset*, Tileset*);
};
#endif // TILESET_H