Skip to content

Commit f0a7893

Browse files
ade the show cursor only on windows cuz yea
1 parent 9be864b commit f0a7893

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

src/modified/GJBaseGameLayer.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,9 @@ class $modify(HorribleGJBaseGameLayer, GJBaseGameLayer) {
5656

5757
}
5858
if (auto quiz = MathQuiz::create()) {
59+
#ifdef GEODE_IS_WINDOWS
5960
CCEGLView::sharedOpenGLView()->showCursor(true);
61+
#endif
6062
m_fields->m_currentQuiz = quiz;
6163
m_fields->m_currentQuiz->customSetup();
6264

@@ -80,9 +82,10 @@ class $modify(HorribleGJBaseGameLayer, GJBaseGameLayer) {
8082
m_fields->m_adCooldown = 0.f;
8183

8284
log::warn("ad time!");
85+
#ifdef GEODE_IS_WINDOWS
8386
// Show cursor when ad appears
8487
CCEGLView::sharedOpenGLView()->showCursor(true);
85-
88+
#endif
8689
if (!m_isPracticeMode && !m_fields->m_currentAd) {
8790
if (auto popup = RandomAdPopup::create()) {
8891
m_fields->m_currentAd = popup;
@@ -97,10 +100,12 @@ class $modify(HorribleGJBaseGameLayer, GJBaseGameLayer) {
97100
m_fields->m_currentAd = nullptr;
98101
};
99102
}
103+
#ifdef GEODE_IS_WINDOWS
100104
// Hide cursor if ad popup is closed
101105
if (!m_fields->m_currentAd && !CCScene::get()->getChildByID("ad"_spr)) {
102106
CCEGLView::sharedOpenGLView()->showCursor(false);
103107
}
108+
#endif
104109
}
105110

106111
GJBaseGameLayer::update(p0);

0 commit comments

Comments
 (0)