about summary refs log tree commit diff stats
path: root/src/ap_state.cpp
diff options
context:
space:
mode:
authorStar Rauchenberger <fefferburbia@gmail.com>2024-05-16 17:06:33 -0400
committerStar Rauchenberger <fefferburbia@gmail.com>2024-05-16 17:06:33 -0400
commit4d8e36245e8ce43eef9b687a9108fd4c353f756f (patch)
treeba63b4a72c2d62816ad4056c6a45a72b3becce95 /src/ap_state.cpp
parent249817743c12b453338c6d0a355180bf5084c73c (diff)
downloadlingo-ap-tracker-4d8e36245e8ce43eef9b687a9108fd4c353f756f.tar.gz
lingo-ap-tracker-4d8e36245e8ce43eef9b687a9108fd4c353f756f.tar.bz2
lingo-ap-tracker-4d8e36245e8ce43eef9b687a9108fd4c353f756f.zip
Added door popups that report requirements
Diffstat (limited to 'src/ap_state.cpp')
-rw-r--r--src/ap_state.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/ap_state.cpp b/src/ap_state.cpp index f245c2b..20245e5 100644 --- a/src/ap_state.cpp +++ b/src/ap_state.cpp
@@ -271,6 +271,7 @@ struct APState {
271 connected = true; 271 connected = true;
272 has_connection_result = true; 272 has_connection_result = true;
273 273
274 ResetReachabilityRequirements();
274 RefreshTracker(true); 275 RefreshTracker(true);
275 276
276 std::list<std::string> corrected_keys; 277 std::list<std::string> corrected_keys;
@@ -447,6 +448,8 @@ struct APState {
447 return ap_id; 448 return ap_id;
448 } 449 }
449 450
451 std::string GetItemName(int id) { return apclient->get_item_name(id); }
452
450 bool HasReachedGoal() { 453 bool HasReachedGoal() {
451 return data_storage.count(victory_data_storage_key) && 454 return data_storage.count(victory_data_storage_key) &&
452 std::any_cast<int>(data_storage.at(victory_data_storage_key)) == 455 std::any_cast<int>(data_storage.at(victory_data_storage_key)) ==
@@ -485,6 +488,10 @@ bool AP_HasItem(int item_id, int quantity) {
485 return GetState().HasItem(item_id, quantity); 488 return GetState().HasItem(item_id, quantity);
486} 489}
487 490
491std::string AP_GetItemName(int item_id) {
492 return GetState().GetItemName(item_id);
493}
494
488DoorShuffleMode AP_GetDoorShuffleMode() { return GetState().door_shuffle_mode; } 495DoorShuffleMode AP_GetDoorShuffleMode() { return GetState().door_shuffle_mode; }
489 496
490bool AP_IsColorShuffle() { return GetState().color_shuffle; } 497bool AP_IsColorShuffle() { return GetState().color_shuffle; }