Skip to content

Commit 9d42802

Browse files
committed
feat(rl-button): Fixed incompatibility with ninxout.redash
1 parent 7b514e0 commit 9d42802

File tree

5 files changed

+18
-11
lines changed

5 files changed

+18
-11
lines changed

ABOUT.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ A Geometry Dash Level Roulette.
1010
- GD List
1111
- Skip levels you can't beat
1212
- Auto pause after reaching the goal percentage (can be disabled)
13+
- Resume playing after leaving the game
1314

1415
## How To Play
1516

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/)
66
and this project adheres to [Semantic Versioning](http://semver.org/).
77

8+
## [3.0.2] - 2024-12-05
9+
10+
### Fixed
11+
12+
- Incompatibility with Ninxout's Overcharged Menu
13+
814
## [3.0.1] - 2024-11-28
915

1016
### Fixed

mod.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"android": "2.2074",
66
"mac": "2.2074"
77
},
8-
"version": "v3.0.1",
8+
"version": "v3.0.2",
99
"id": "spaghettdev.gd-roulette",
1010
"name": "GD-Roulette",
1111
"developer": "SpaghettDev",

src/layers/CreatorLayer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ class $modify(RouletteButton, CreatorLayer)
1212
if (g_rouletteManager.rouletteLayer = RLRouletteLayer::create(); g_rouletteManager.rouletteLayer)
1313
g_rouletteManager.rouletteLayer->show();
1414

15-
if (auto exMark = this->getChildByID("center-left-menu"_spr)->getChildByID("roulette-button"_spr)->getChildByID("exclamation-mark"))
15+
if (auto exMark = this->getChildByIDRecursive("exclamation-mark"_spr))
1616
exMark->removeFromParent();
1717
}
1818

src/roulette/manager/RouletteManager.hpp

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -56,19 +56,19 @@ struct RouletteManager
5656

5757
void addExclamationMark(CCMenuItemSpriteExtra* button = nullptr)
5858
{
59+
auto parent = button
60+
? button
61+
: rouletteLayer->getParent()->getChildByIDRecursive("roulette-button"_spr);
62+
5963
auto exclamationSprite = CCSprite::createWithSpriteFrameName(
6064
"exMark_001.png"
6165
);
6266
exclamationSprite->setScale(.6f);
63-
exclamationSprite->setID("exclamation-mark");
64-
(button
65-
? button
66-
: rouletteLayer
67-
->getParent()
68-
->getChildByType<CreatorLayer>(0)
69-
->getChildByID("center-left-menu"_spr)
70-
->getChildByID("roulette-button"_spr)
71-
)->addChild(exclamationSprite);
67+
exclamationSprite->setID("exclamation-mark"_spr);
68+
parent->addChild(exclamationSprite);
69+
70+
if (Loader::get()->isModLoaded("ninxout.redash") && !parent->getLayout())
71+
exclamationSprite->getParent()->setLayout(AnchorLayout::create());
7272

7373
exclamationSprite->setLayoutOptions(
7474
AnchorLayoutOptions::create()

0 commit comments

Comments
 (0)