Skip to content

Commit

Permalink
Fix unlock all upgrades triggering the ghost
Browse files Browse the repository at this point in the history
  • Loading branch information
Dregu committed Aug 23, 2024
1 parent 2e17181 commit fbfc3ee
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions ui.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -581,11 +581,11 @@ void UI::DrawPlayer() {
}
}
{
bool all = (*Max::get().upgrades() & 0x57FFFE07) == 0x57FFFE07;
bool all = (*Max::get().upgrades() & 0x37FFFE07) == 0x37FFFE07;
if (ImGui::Checkbox("Unlock all upgrades##UnlockAllUpgrades2", &all) ||
everything) {
if (everything || all) {
*Max::get().upgrades() |= 0x57FFFE07;
*Max::get().upgrades() |= 0x37FFFE07;
} else {
*Max::get().upgrades() = 0;
}
Expand Down Expand Up @@ -760,10 +760,10 @@ void UI::DrawPlayer() {
if (ImGui::CollapsingHeader("Miscellaneous##PlayerMisc")) {
ImGui::PushID("PlayerSectionMisc");
DebugPtr(Max::get().upgrades());
bool all = (*Max::get().upgrades() & 0x57FFFE07) == 0x57FFFE07;
bool all = (*Max::get().upgrades() & 0x17FFFE07) == 0x17FFFE07;
if (ImGui::Checkbox("Unlock all upgrades##UnlockAllUpgrades", &all)) {
if (all) {
*Max::get().upgrades() |= 0x57FFFE07;
*Max::get().upgrades() |= 0x37FFFE07;
} else {
*Max::get().upgrades() = 0;
}
Expand Down

0 comments on commit fbfc3ee

Please sign in to comment.