3 * Created by: ennewalker on Sat Jan 5 01:33:53 2008 UTC
11 #include "tiledgnbuf.h"
23 bool tile_dungeon_tip(const coord_def
&gc
, std::string
&tip
);
24 int tile_click_cell(const coord_def
&gc
, unsigned char mod
);
26 class DungeonRegion
: public TileRegion
29 DungeonRegion(const TileRegionInit
&init
);
30 virtual ~DungeonRegion();
32 virtual void render();
34 virtual int handle_mouse(MouseEvent
&event
);
35 virtual bool update_tip_text(std::string
&tip
);
36 virtual bool update_alt_text(std::string
&alt
);
37 virtual void on_resize();
39 void load_dungeon(const crawl_view_buffer
&vbuf
, const coord_def
&gc
);
40 void place_cursor(cursor_type type
, const coord_def
&gc
);
41 bool on_screen(const coord_def
&gc
) const;
43 void clear_text_tags(text_tag_type type
);
44 void add_text_tag(text_tag_type type
, const std::string
&tag
,
47 const coord_def
&get_cursor() const { return m_cursor
[CURSOR_MOUSE
]; }
49 void add_overlay(const coord_def
&gc
, int idx
);
50 void clear_overlays();
54 void pack_cursor(cursor_type type
, unsigned int tile
);
58 int get_buffer_index(const coord_def
&gc
);
59 void to_screen_coords(const coord_def
&gc
, coord_def
*pc
) const;
61 crawl_view_buffer m_vbuf
;
64 coord_def m_cursor
[CURSOR_MAX
];
65 coord_def m_last_clicked_grid
;
66 std::vector
<TextTag
> m_tags
[TAG_MAX
];
68 DungeonCellBuffer m_buf_dngn
;
69 ShapeBuffer m_buf_flash
;
76 std::vector
<tile_overlay
> m_overlays
;