diff options
Diffstat (limited to 'src/ap_state.cpp')
-rw-r--r-- | src/ap_state.cpp | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/src/ap_state.cpp b/src/ap_state.cpp index e4d892b..876fdd8 100644 --- a/src/ap_state.cpp +++ b/src/ap_state.cpp | |||
@@ -550,16 +550,27 @@ int AP_GetMasteryRequirement() { return GetState().mastery_requirement; } | |||
550 | int AP_GetLevel2Requirement() { return GetState().level_2_requirement; } | 550 | int AP_GetLevel2Requirement() { return GetState().level_2_requirement; } |
551 | 551 | ||
552 | bool AP_IsLocationVisible(int classification) { | 552 | bool AP_IsLocationVisible(int classification) { |
553 | int world_state = 0; | ||
554 | |||
553 | switch (GetState().location_checks) { | 555 | switch (GetState().location_checks) { |
554 | case kNORMAL_LOCATIONS: | 556 | case kNORMAL_LOCATIONS: |
555 | return classification & kLOCATION_NORMAL; | 557 | world_state = kLOCATION_NORMAL; |
558 | break; | ||
556 | case kREDUCED_LOCATIONS: | 559 | case kREDUCED_LOCATIONS: |
557 | return classification & kLOCATION_REDUCED; | 560 | world_state = kLOCATION_REDUCED; |
561 | break; | ||
558 | case kPANELSANITY: | 562 | case kPANELSANITY: |
559 | return classification & kLOCATION_INSANITY; | 563 | world_state = kLOCATION_INSANITY; |
564 | break; | ||
560 | default: | 565 | default: |
561 | return false; | 566 | return false; |
562 | } | 567 | } |
568 | |||
569 | if (GetState().door_shuffle_mode && !GetState().early_color_hallways) { | ||
570 | world_state |= kLOCATION_SMALL_SPHERE_ONE; | ||
571 | } | ||
572 | |||
573 | return (world_state & classification); | ||
563 | } | 574 | } |
564 | 575 | ||
565 | VictoryCondition AP_GetVictoryCondition() { | 576 | VictoryCondition AP_GetVictoryCondition() { |