00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef EDITOR_TILE_H_
00015 #define EDITOR_TILE_H_
00016
00017 #include "../Config.h"
00018
00019 #include "TileSetEditor.h"
00020 #include "../Game/Tile.h"
00021 #include "../Graphics/draw.h"
00022
00023 namespace Editor {
00024 class EditorTile : public Graphics::DrawableAt {
00025 public:
00026 EditorTile(Game::AbstractTile* tile, int tileSetIndex);
00027 ~EditorTile();
00028 void drawAt(SDL_Surface* surf, SDL_Rect* dest);
00029
00030 void incrementTile(const TileSetEditor& ts);
00031 void decrementTile(const TileSetEditor& ts);
00033 void reload(const TileSetEditor& ts);
00034
00035 void setAsTile(const TileSetEditor& ts, int index);
00036
00037 int getIndex() const;
00038 private:
00039 Game::AbstractTile* tile;
00040 int curIndex;
00041 };
00042 }
00043
00044 #endif // ifndef EDITOR_TILE_H_