Store user data in $HOME
[kball.git] / include / mapedit.h
blobb3c1f33b068584fb01c983207ae597121b38643b
1 // -----------------------------------------------
2 // mapedit.h
3 // -----------------------------------------------
4 // Built-in map editor (totally l33t!)
5 // -----------------------------------------------
6 // By Kronoman - July 2003 - December 2003
7 // In loving memory of my father
8 // -----------------------------------------------
10 #ifndef MAPEDIT_H
11 #define MAPEDIT_H
13 #include <allegro.h>
15 #include "tmap.h" // tile map class
16 #include "gerror.h" // to show any error that may arise
17 #include "misc_def.h"
18 #include "mytracer.h"
19 #include "backgbmp.h"
22 class CMapEditor
24 public:
25 CMapEditor();
26 ~CMapEditor();
28 void start_map_editor();
30 private:
31 void map_editor_help_message();
33 void redraw_the_tile_map(int layer, bool grid);
35 void do_change_mouse_cursor();
37 void kprint(char *msg); // helper for printing messages on screen
40 int tx, ty; // current scroll in the map
41 int ts; // current tile selected from the tile set (1..255)
42 int tl; // current layer of map selected 0..MAP_LAYERS-1 (MAP_LAYERS in tmap.h)
43 bool draw_grid; // draw grid?
45 CTMap game_map; // game map
46 CBackground background; // backgrounds availables
48 // two bitmaps for internal use
49 BITMAP *dbuffer; // doble buffer
50 BITMAP *mcursor; // mouse cursor
52 // helper function for text print
53 int ykprint, ckprint;
55 // debugger
56 CMyTracer mtracer;
59 #endif