diff --git a/src/GJWorldNodeDecomp.cpp b/src/GJWorldNodeDecomp.cpp index f6526d6..0a6c484 100644 --- a/src/GJWorldNodeDecomp.cpp +++ b/src/GJWorldNodeDecomp.cpp @@ -30,7 +30,7 @@ bool GJWorldNodeDecomp::init( m_index = index; - std::cout << index << std::endl; + /* std::cout << index << std::endl;*/ m_worldSelectLayer = worldSelectLayer; diff --git a/src/SubZeroSelectLayer.cpp b/src/SubZeroSelectLayer.cpp index 99b19af..cc3e430 100644 --- a/src/SubZeroSelectLayer.cpp +++ b/src/SubZeroSelectLayer.cpp @@ -347,7 +347,7 @@ void SubZeroSelectLayer::updateColors() { m_ground->updateGround01Color(color); m_ground->updateGround02Color(color); } -void SubZeroSelectLayer::scollLayerMoved(CCPoint point) { +void SubZeroSelectLayer::scrollLayerMoved(CCPoint point) { log::info("scrollLayerMoved"); std::cout << "Works!" << std::endl; diff --git a/src/SubZeroSelectLayer.h b/src/SubZeroSelectLayer.h index b971862..1e99ffe 100644 --- a/src/SubZeroSelectLayer.h +++ b/src/SubZeroSelectLayer.h @@ -25,7 +25,7 @@ class SubZeroSelectLayer : public cocos2d::CCLayer, public BoomScrollLayerDelega void onPlay(cocos2d::CCObject*); void onBack(cocos2d::CCObject*); void keyBackClicked(); - void scollLayerMoved(cocos2d::CCPoint); + void scrollLayerMoved(cocos2d::CCPoint) override; void keyDown(int); void updateColors(); void instantPage(cocos2d::CCObject*,int); diff --git a/src/main.cpp b/src/main.cpp index e63316a..2ea89b9 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -12,6 +12,9 @@ #include #include #include +#include +#include +#include #include #include "SubZeroSelectLayer.h" #include "SubZeroSelectLayer.cpp" @@ -30,6 +33,28 @@ using namespace geode::prelude; #include using namespace more; +//class $modify(LeaderboardsLayer) +//{ +// void onTop(cocos2d::CCObject * a1) +// { +// LeaderboardsLayer::onTop(a1); +// +// +// // Suponiendo que m_userScores es un CCArray de GJUserScore +// for (int i = 0; i < this->m_userScores->count(); ++i) { +// // Obtener el GJUserScore en la posición 'i' +// GJUserScore* userScore = dynamic_cast(this->m_userScores->objectAtIndex(i)); +// +// // Verificar si la conversión fue exitosa +// if (userScore != nullptr) { +// // Imprimir el m_userName utilizando std::cout +// std::cout << "m_userName: " << userScore->m_userName.c_str() << std::endl; +// } +// } +// +// return true; +// } +//}; //class TestLayer : public CCLayer, BoomScrollLayerDelegate, DynamicScrollDelegate { //public: // static TestLayer* create() { @@ -285,6 +310,38 @@ using namespace more; // BoomScrollLayer* m_scrollLayer; //}; #include +//class $modify(GJUserScore) +//{ +// static GJUserScore* create(cocos2d::CCDictionary * a1) +// { +// // User ID +// Mod::get()->setSavedValue("mgcruser", a1->valueForKey("2")->intValue()); +// +// // Glow Color +// Mod::get()->setSavedValue("mgcrglow", a1->valueForKey("51")->intValue()); +// +// return GJUserScore::create(a1); +// } +//}; +// +//class $modify(GJScoreCell) +//{ +// TodoReturn loadFromScore(GJUserScore * a1) +// { +// GJScoreCell::loadFromScore(a1); +// +// int userID = a1->m_userID; +// int savedUserID = Mod::get()->getSavedValue("mgcruser"); +// +// if (userID == savedUserID) +// { +// int glowColor = Mod::get()->getSavedValue("mgcrglow"); +// std::cout << "Glow Color for User ID " << userID << ": " << glowColor << std::endl; +// } +// } +//}; + + class $modify(LoadingLayer) { void loadAssets()