00001
00002
00003
00004
00005
00006
00007
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __TILESET_HEADER__
00018 #define __TILESET_HEADER__
00019
00020 #include "utils.h"
00021 #include "defs.h"
00022 #include "script.h"
00023 #include "video.h"
00024
00025 #include <QMessageBox>
00026 #include <Q3Table>
00027 #include <QImageReader>
00028 #include <QRect>
00029 #include <QVariant>
00030
00032 namespace hoa_editor
00033 {
00034
00035 struct AnimatedTileData {
00036 int tile_id;
00037 int time;
00038 };
00039
00041 const int TILE_WIDTH = 32;
00042 const int TILE_HEIGHT = 32;
00043
00048 class Tileset
00049 {
00050 public:
00052 Tileset(QWidget* parent, const QString& name);
00054 ~Tileset();
00055
00056 void Save();
00057
00059 QString tileset_name;
00061 std::vector<hoa_video::StillImage> tiles;
00063 std::map<int, std::vector<int32> > walkability;
00065 Q3Table* table;
00066
00067
00068 private:
00069 std::vector<std::vector<AnimatedTileData> > _animated_tiles;
00070 };
00071
00072 }
00073
00074 #endif
00075