Fix bug #16347 (broken big editor brush area)

Now use a repeated overlay similar to the mouseover overlay.
This commit is contained in:
Ali El Gariani 2010-08-06 18:26:45 +00:00
parent e7ecd91a58
commit b741019b80
5 changed files with 10 additions and 0 deletions

View file

@ -98,6 +98,7 @@
grid_bottom="terrain/grid-bottom.png"
mouseover="misc/hover-hex.png"
selected=""
editor_brush="editor/brush.png"
unreachable="terrain/darken.png"
linger="terrain/darken-linger.png"

View file

Before

Width:  |  Height:  |  Size: 5.2 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

View file

@ -82,6 +82,12 @@ void editor_display::draw_hex(const map_location& loc)
image::get_image("editor/selection-overlay.png", image::SCALED_TO_HEX)));
}
if (brush_locations_.find(loc) != brush_locations_.end()) {
static const image::locator brush(game_config::images::editor_brush);
drawing_buffer_add(LAYER_MOVE_INFO, loc, tblit(xpos, ypos,
image::get_image(brush, image::UNMASKED)));
}
if(loc == mouseoverHex_ && !game_config::images::mouseover.empty()) {
static const image::locator mouseover(game_config::images::mouseover);
drawing_buffer_add(LAYER_MOVE_INFO, loc, tblit(xpos, ypos,

View file

@ -83,6 +83,7 @@ namespace game_config
grid_bottom,
mouseover,
selected,
editor_brush,
unreachable,
linger,
// GUI elements
@ -204,6 +205,7 @@ namespace game_config
grid_bottom = i["grid_bottom"].str();
mouseover = i["mouseover"].str();
selected = i["selected"].str();
editor_brush = i["editor_brush"].str();
unreachable = i["unreachable"].str();
linger = i["linger"].str();

View file

@ -89,6 +89,7 @@ namespace game_config
grid_bottom,
mouseover,
selected,
editor_brush,
unreachable,
linger,
// GUI elements