Skip to content

Commit

Permalink
another one to check off the list
Browse files Browse the repository at this point in the history
  • Loading branch information
FireMario211 committed Mar 12, 2024
1 parent 5291b09 commit 2f60f5c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
- Made the Prism Button hidden if you are in the Editor.
- Fixed bug with progress saving even in Test Mode.
- Fixed the ordering of the buttons for "Uncomplete Level".
- Fixed bug with Prism Button not working when using "Uncomplete Level".
- Updated Portuguese Translations.
- Updated Czech Translations.
- Fixed No Spikes.
Expand Down
7 changes: 6 additions & 1 deletion src/hacks.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include "hacks.hpp"
#include "CustomSettings.hpp"
#include "PrismUI.hpp"

std::vector<HackItem> allHacks;

Expand Down Expand Up @@ -139,7 +140,7 @@ void proceedWithReset(LevelInfoLayer* levelInfoLayer, GJGameLevel* level, bool r
level->m_coinsVerified = 0;
GLM->deleteLevel(level);
levelInfoLayer->onBack(nullptr);
FLAlertLayer::create("Uncompleted Level", fmt::format("The level <cy>{}</c> ({}) has been reset!\nYou will need to download it again in order to play it.", level->m_levelName, level->m_levelID.value()), "OK")->show();
//FLAlertLayer::create("Uncompleted Level", fmt::format("The level <cy>{}</c> ({}) has been reset!\nYou will need to download it again in order to play it.", level->m_levelName, level->m_levelID.value()), "OK")->show();
}
}, true, true
);
Expand All @@ -149,6 +150,10 @@ void proceedWithReset(LevelInfoLayer* levelInfoLayer, GJGameLevel* level, bool r
#endif

void Hacks::resetLevel(LevelInfoLayer* levelInfoLayer, GJGameLevel* level) {
auto prismUIExists = CCScene::get()->getChildByID("prism-menu");
if (prismUIExists != nullptr) {
static_cast<PrismUI*>(prismUIExists)->onClose(CCNode::create());
}
#ifdef GEODE_IS_MACOS
FLAlertLayer::create("Notice", "This currently does not work on <cy>Mac OS</c>\n(you can blame the people who rushed me to work on this)", "OK")->show();
#else
Expand Down

0 comments on commit 2f60f5c

Please sign in to comment.