don't show Jobs button if scenario has no quests in it
This commit is contained in:
@@ -50,9 +50,13 @@
|
|||||||
#include "fileio/resmgr/res_font.hpp"
|
#include "fileio/resmgr/res_font.hpp"
|
||||||
|
|
||||||
rectangle item_screen_button_rects[9] = {
|
rectangle item_screen_button_rects[9] = {
|
||||||
|
// PC 1-6
|
||||||
{125,10,141,28},{125,40,141,58},{125,68,141,86},{125,98,141,116},{125,126,141,144},{125,156,141,174},
|
{125,10,141,28},{125,40,141,58},{125,68,141,86},{125,98,141,116},{125,126,141,144},{125,156,141,174},
|
||||||
|
// Special Items
|
||||||
{126,176,141,211},
|
{126,176,141,211},
|
||||||
|
// Quests
|
||||||
{126,213,141,248},
|
{126,213,141,248},
|
||||||
|
// Help
|
||||||
{127,251,140,267}
|
{127,251,140,267}
|
||||||
};
|
};
|
||||||
rectangle medium_buttons[4] = {
|
rectangle medium_buttons[4] = {
|
||||||
|
|||||||
@@ -532,8 +532,15 @@ void place_item_bottom_buttons() {
|
|||||||
}
|
}
|
||||||
to_rect = item_screen_button_rects[6];
|
to_rect = item_screen_button_rects[6];
|
||||||
rect_draw_some_item(invenbtn_gworld, spec_from_rect, item_stats_gworld(), to_rect, sf::BlendAlpha);
|
rect_draw_some_item(invenbtn_gworld, spec_from_rect, item_stats_gworld(), to_rect, sf::BlendAlpha);
|
||||||
to_rect = item_screen_button_rects[7];
|
|
||||||
rect_draw_some_item(invenbtn_gworld, job_from_rect, item_stats_gworld(), to_rect, sf::BlendAlpha);
|
// Don't draw the Jobs button if the scenario has none
|
||||||
|
item_bottom_button_active[7] = false;
|
||||||
|
if(!univ.scenario.quests.empty()){
|
||||||
|
item_bottom_button_active[7] = true;
|
||||||
|
to_rect = item_screen_button_rects[7];
|
||||||
|
rect_draw_some_item(invenbtn_gworld, job_from_rect, item_stats_gworld(), to_rect, sf::BlendAlpha);
|
||||||
|
}
|
||||||
|
|
||||||
to_rect = item_screen_button_rects[8];
|
to_rect = item_screen_button_rects[8];
|
||||||
rect_draw_some_item(invenbtn_gworld, help_from_rect, item_stats_gworld(), to_rect, sf::BlendAlpha);
|
rect_draw_some_item(invenbtn_gworld, help_from_rect, item_stats_gworld(), to_rect, sf::BlendAlpha);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user