diff options
| author | Star Rauchenberger <fefferburbia@gmail.com> | 2023-05-02 20:14:43 -0400 |
|---|---|---|
| committer | Star Rauchenberger <fefferburbia@gmail.com> | 2023-05-02 20:14:43 -0400 |
| commit | 70f1c629a6e08e0f9c58707f0470e08c6ffeca34 (patch) | |
| tree | a2262b898f02c551d3de298ffbd61505cdd384d2 /area_popup.cpp | |
| parent | 09d67fbad9df92caf2251d36b4abd7979fd27126 (diff) | |
| download | lingo-ap-tracker-70f1c629a6e08e0f9c58707f0470e08c6ffeca34.tar.gz lingo-ap-tracker-70f1c629a6e08e0f9c58707f0470e08c6ffeca34.tar.bz2 lingo-ap-tracker-70f1c629a6e08e0f9c58707f0470e08c6ffeca34.zip | |
Added reachability checking (only no doors rn)
Diffstat (limited to 'area_popup.cpp')
| -rw-r--r-- | area_popup.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
| diff --git a/area_popup.cpp b/area_popup.cpp index e46e4ec..4cc3c63 100644 --- a/area_popup.cpp +++ b/area_popup.cpp | |||
| @@ -2,6 +2,7 @@ | |||
| 2 | 2 | ||
| 3 | #include "ap_state.h" | 3 | #include "ap_state.h" |
| 4 | #include "game_data.h" | 4 | #include "game_data.h" |
| 5 | #include "tracker_state.h" | ||
| 5 | 6 | ||
| 6 | AreaPopup::AreaPopup(wxWindow* parent, int area_id) | 7 | AreaPopup::AreaPopup(wxWindow* parent, int area_id) |
| 7 | : wxPanel(parent, wxID_ANY), area_id_(area_id) { | 8 | : wxPanel(parent, wxID_ANY), area_id_(area_id) { |
| @@ -43,7 +44,9 @@ void AreaPopup::UpdateIndicators() { | |||
| 43 | for (int section_id = 0; section_id < map_area.locations.size(); | 44 | for (int section_id = 0; section_id < map_area.locations.size(); |
| 44 | section_id++) { | 45 | section_id++) { |
| 45 | bool checked = GetAPState().HasCheckedGameLocation(area_id_, section_id); | 46 | bool checked = GetAPState().HasCheckedGameLocation(area_id_, section_id); |
| 46 | const wxColour* text_color = checked ? wxWHITE : wxGREEN; | 47 | bool reachable = |
| 48 | GetTrackerState().IsLocationReachable(area_id_, section_id); | ||
| 49 | const wxColour* text_color = reachable ? wxWHITE : wxRED; | ||
| 47 | 50 | ||
| 48 | section_labels_[section_id]->SetForegroundColour(*text_color); | 51 | section_labels_[section_id]->SetForegroundColour(*text_color); |
| 49 | eye_indicators_[section_id]->SetChecked(checked); | 52 | eye_indicators_[section_id]->SetChecked(checked); |
