Author: ilor
Date: Mon Jul 14 23:31:37 2008
New Revision: 28037

URL: http://svn.gna.org/viewcvs/wesnoth?rev=28037&view=rev
Log:
Make brushes actually work

Modified:
    trunk/src/editor2/mouse_action.cpp

Modified: trunk/src/editor2/mouse_action.cpp
URL: 
http://svn.gna.org/viewcvs/wesnoth/trunk/src/editor2/mouse_action.cpp?rev=28037&r1=28036&r2=28037&view=diff
==============================================================================
--- trunk/src/editor2/mouse_action.cpp (original)
+++ trunk/src/editor2/mouse_action.cpp Mon Jul 14 23:31:37 2008
@@ -53,7 +53,12 @@
 {
        gamemap::location hex = disp.hex_clicked_on(x, y);
        t_translation::t_terrain terrain = mode_.get_foreground_terrain();
-       editor_action_paint_hex* a = new editor_action_paint_hex(hex, terrain);
+       editor_action* a;
+       if (mode_.get_brush() != NULL) {
+               a = new 
editor_action_paint_area(mode_.get_brush()->project(hex), terrain);
+       } else {
+               a = new editor_action_paint_hex(hex, terrain);
+       }
        previous_hex_ = hex;
        return a;
 }


_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits

Reply via email to