diff options
| -rw-r--r-- | assets/subway.yaml | 3 | ||||
| -rw-r--r-- | src/subway_map.cpp | 22 |
2 files changed, 9 insertions, 16 deletions
| diff --git a/assets/subway.yaml b/assets/subway.yaml index 266b722..8ef3aee 100644 --- a/assets/subway.yaml +++ b/assets/subway.yaml | |||
| @@ -630,6 +630,7 @@ | |||
| 630 | - blue_ch | 630 | - blue_ch |
| 631 | - yellow_ch | 631 | - yellow_ch |
| 632 | - green_ch | 632 | - green_ch |
| 633 | - early_ch | ||
| 633 | - pos: [1567, 1264] | 634 | - pos: [1567, 1264] |
| 634 | tags: | 635 | tags: |
| 635 | - red_ch | 636 | - red_ch |
| @@ -686,8 +687,6 @@ | |||
| 686 | tags: | 687 | tags: |
| 687 | - blueman_courtyard | 688 | - blueman_courtyard |
| 688 | - blueman_starting | 689 | - blueman_starting |
| 689 | - pos: [60, 970] | ||
| 690 | special: early_color_hallways | ||
| 691 | - pos: [402, 1012] | 690 | - pos: [402, 1012] |
| 692 | room: Outside The Undeterred | 691 | room: Outside The Undeterred |
| 693 | door: Green Painting | 692 | door: Green Painting |
| diff --git a/src/subway_map.cpp b/src/subway_map.cpp index c7b2c8a..e3b844d 100644 --- a/src/subway_map.cpp +++ b/src/subway_map.cpp | |||
| @@ -1,9 +1,9 @@ | |||
| 1 | #include "subway_map.h" | 1 | #include "subway_map.h" |
| 2 | 2 | ||
| 3 | #include <fmt/core.h> | ||
| 3 | #include <wx/dcbuffer.h> | 4 | #include <wx/dcbuffer.h> |
| 4 | #include <wx/dcgraph.h> | 5 | #include <wx/dcgraph.h> |
| 5 | 6 | ||
| 6 | #include <fmt/core.h> | ||
| 7 | #include <sstream> | 7 | #include <sstream> |
| 8 | 8 | ||
| 9 | #include "ap_state.h" | 9 | #include "ap_state.h" |
| @@ -71,9 +71,8 @@ void SubwayMap::OnConnect() { | |||
| 71 | std::map<std::string, std::vector<int>> tagged; | 71 | std::map<std::string, std::vector<int>> tagged; |
| 72 | for (const SubwayItem &subway_item : GD_GetSubwayItems()) { | 72 | for (const SubwayItem &subway_item : GD_GetSubwayItems()) { |
| 73 | if (AP_HasEarlyColorHallways() && | 73 | if (AP_HasEarlyColorHallways() && |
| 74 | (subway_item.special == "starting_room_paintings" || | 74 | subway_item.special == "starting_room_paintings") { |
| 75 | subway_item.special == "early_color_hallways")) { | 75 | tagged["early_ch"].push_back(subway_item.id); |
| 76 | tagged["early_color_hallways"].push_back(subway_item.id); | ||
| 77 | } | 76 | } |
| 78 | 77 | ||
| 79 | if (AP_IsPaintingShuffle() && !subway_item.paintings.empty()) { | 78 | if (AP_IsPaintingShuffle() && !subway_item.paintings.empty()) { |
| @@ -406,7 +405,7 @@ void SubwayMap::OnMouseMove(wxMouseEvent &event) { | |||
| 406 | std::vector<int> hovered = tree_->query( | 405 | std::vector<int> hovered = tree_->query( |
| 407 | {static_cast<float>(mouse_pos.x), static_cast<float>(mouse_pos.y), 2, 2}); | 406 | {static_cast<float>(mouse_pos.x), static_cast<float>(mouse_pos.y), 2, 2}); |
| 408 | if (!hovered.empty()) { | 407 | if (!hovered.empty()) { |
| 409 | actual_hover_= hovered[0]; | 408 | actual_hover_ = hovered[0]; |
| 410 | } else { | 409 | } else { |
| 411 | actual_hover_ = std::nullopt; | 410 | actual_hover_ = std::nullopt; |
| 412 | } | 411 | } |
| @@ -532,15 +531,9 @@ void SubwayMap::Redraw() { | |||
| 532 | std::optional<wxColour> shade_color; | 531 | std::optional<wxColour> shade_color; |
| 533 | 532 | ||
| 534 | if (AP_HasEarlyColorHallways() && | 533 | if (AP_HasEarlyColorHallways() && |
| 535 | (subway_item.special == "starting_room_paintings" || | 534 | subway_item.special == "starting_room_paintings") { |
| 536 | subway_item.special == "early_color_hallways")) { | ||
| 537 | draw_type = ItemDrawType::kOwl; | 535 | draw_type = ItemDrawType::kOwl; |
| 538 | 536 | shade_color = wxColour(0, 255, 0, 128); | |
| 539 | if (subway_item.special == "starting_room_paintings") { | ||
| 540 | shade_color = wxColour(0, 255, 0, 128); | ||
| 541 | } else { | ||
| 542 | shade_color = wxColour(255, 0, 0, 128); | ||
| 543 | } | ||
| 544 | } else if (subway_item.special == "sun_painting") { | 537 | } else if (subway_item.special == "sun_painting") { |
| 545 | if (!AP_IsPilgrimageEnabled()) { | 538 | if (!AP_IsPilgrimageEnabled()) { |
| 546 | if (IsDoorOpen(*subway_item.door)) { | 539 | if (IsDoorOpen(*subway_item.door)) { |
| @@ -572,7 +565,8 @@ void SubwayMap::Redraw() { | |||
| 572 | } | 565 | } |
| 573 | } | 566 | } |
| 574 | 567 | ||
| 575 | if (has_unchecked_painting || has_mapped_painting || has_codomain_painting) { | 568 | if (has_unchecked_painting || has_mapped_painting || |
| 569 | has_codomain_painting) { | ||
| 576 | draw_type = ItemDrawType::kOwl; | 570 | draw_type = ItemDrawType::kOwl; |
| 577 | 571 | ||
| 578 | if (has_checked_painting) { | 572 | if (has_checked_painting) { |
