diff --git a/game.cpp b/game.cpp index acdd0c3..5879bbf 100644 --- a/game.cpp +++ b/game.cpp @@ -151,14 +151,17 @@ void Game::render() DrawUtils::draw_line(display, 150, display->h - 100, 150, display->h, 2, 0x000000); - if (data.get_current_vertex() != NULL && - data.get_current_vertex()->player == data.get_turn()) { for (list::iterator cursor = buttons.begin(); cursor != buttons.end(); cursor++) { MenuButton* button = *cursor; + if (!(button->get_action() & BUTTON_END_TURN) && + (data.get_current_vertex() == NULL || + data.get_current_vertex()->player != data.get_turn())) + continue; + if ((button->get_action() & (BUTTON_BUILD_ATTACKER | BUTTON_BUILD_DEFENDER | BUTTON_BUILD_PRODUCER)) &&