Skip to content

Commit

Permalink
v1.1.7
Browse files Browse the repository at this point in the history
  • Loading branch information
hiimjasmine00 committed May 28, 2024
1 parent 44faf28 commit 742bc5d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
3 changes: 3 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Fake Rate Changelog
## v1.1.7 (2024-05-27)
- Fixed a few bugs with compatibilty with other mods

## v1.1.6 (2024-05-27)
- Fixed incompatibility with the mod "GDDP Integration" by Minemaker0430

Expand Down
2 changes: 1 addition & 1 deletion mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"win": "2.204",
"mac": "2.200"
},
"version": "v1.1.6",
"version": "v1.1.7",
"id": "hiimjustin000.fake_rate",
"name": "Fake Rate",
"developer": "hiimjustin000",
Expand Down
8 changes: 5 additions & 3 deletions src/FREditPopup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,16 +58,16 @@ void FRLevelInfoLayer::updateFakeRate(int stars, int feature, int difficulty, bo
}
auto gddpOverride = false;
if (auto gddpDifficultySprite = static_cast<CCSprite*>(getChildByID("gddp-difficulty"))) {
gddpOverride = true;
gddpOverride = gddpDifficultySprite->isVisible();
gddpDifficultySprite->setVisible(false);
m_difficultySprite->setOpacity(255);
}
if (Loader::get()->isModLoaded("itzkiba.grandpa_demon") && !gddpOverride) {
removeChildByTag(69420);
if (auto grdDifficulty = getChildByID("grd-difficulty")) grdDifficulty->setVisible(false);
for (auto child : CCArrayExt<CCNode*>(getChildren())) {
if (child->getID() == "grd-difficulty") child->setVisible(false);
}
if (auto grdInfinity = getChildByID("grd-infinity")) grdInfinity->setVisible(false);
m_difficultySprite->setVisible(true);
if (auto featureGlow = m_difficultySprite->getChildByTag(69420))
featureGlow->setPosition(m_difficultySprite->getContentSize() * 0.5f);
Expand All @@ -83,7 +83,9 @@ void FRLevelInfoLayer::updateFakeRate(int stars, int feature, int difficulty, bo
auto children = getChildren();
for (int i = 0; i < children->count(); i++) {
if (auto child = typeinfo_cast<CCMenu*>(children->objectAtIndex(i))) {
if (auto button = typeinfo_cast<CCMenuItemSpriteExtra*>(child->getChildren()->objectAtIndex(0))) {
auto grandchildren = child->getChildren();
if (!grandchildren || grandchildren->count() < 1) continue;
if (auto button = typeinfo_cast<CCMenuItemSpriteExtra*>(grandchildren->objectAtIndex(0))) {
if (button->getNormalImage() == m_difficultySprite) {
nodeToSetPosition = child;
difficultySpriteParent = button;
Expand Down

0 comments on commit 742bc5d

Please sign in to comment.