// // SongSelectNode::init from 0x83edfc to 0x83f658 (2140 bytes) // // 2 xrefs: // > SongSelectNode::create @ 0x83f764 // > @ 0xa1970 // // This function is hookable on this platform! // // Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA // Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings // // local variable allocation has failed, the output may be wrong! bool SongSelectNode::init( SongSelectNode *a1, int a2, bool a3, LevelSettingsObject *a4, SongSelectType a5, cocos2d::CCPoint a6, cocos2d::CCNode *a7, cocos2d::CCMenu *a8, bool a9) { cocos2d::CCNode *v16; // x21 _BOOL8 v17; // x0 bool v18; // w25 cocos2d::CCArray *v20; // x0 cocos2d::CCNode *v21; // x22 void (__fastcall *setContentSize)(cocos2d::CCNode *__hidden, const cocos2d::CCSize *); // x23 void (__fastcall *setPosition)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x23 cocos2d::CCArray *v24; // x0 cocos2d::CCArray *v25; // x0 cocos2d::CCArray *v26; // x0 cocos2d::CCArray *v27; // x0 cocos2d::CCLabelBMFont *v28; // x0 cocos2d::CCMenu_vtbl *v29; // x2 cocos2d::CCLabelBMFont *m_audioLabel; // x23 void (__fastcall *v31)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 __int64 v32; // x0 float y; // s9 cocos2d::CCSprite *v34; // x27 CCMenuItemSpriteExtra *v35; // x27 cocos2d::CCSprite *v36; // x27 CCMenuItemSpriteExtra *v37; // x27 cocos2d::CCNode *v38; // x0 CCMenuItemSpriteExtra *v39; // x0 float v40; // s1 void (__fastcall *v41)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x26 cocos2d::CCNode *v42; // x0 CCMenuItemSpriteExtra *v43; // x0 CCMenuItemSpriteExtra *m_customButton; // x26 void (__fastcall *v45)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x27 const char *v46; // x6 cocos2d::CCNode *v47; // x0 CCMenuItemSpriteExtra *v48; // x0 cocos2d::CCNode_vtbl *v49; // x2 CCMenuItemSpriteExtra *m_selectButton; // x28 const cocos2d::CCPoint *v51; // x0 cocos2d::CCSprite *v52; // x0 CCMenuItemSpriteExtra *v53; // x0 cocos2d::CCNode_vtbl *v54; // x2 CCMenuItemSpriteExtra *m_changeButton; // x27 void (__fastcall *v56)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x28 SongInfoObject *SongInfoObject; // x0 MusicDownloadManager *v58; // x0 CustomSongWidget *v59; // x0 cocos2d::CCMenu_vtbl *v60; // x2 CustomSongWidget *m_songWidget; // x20 void (__fastcall *v62)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // x21 __int64 v63; // x0 CCMenuItemSpriteExtra *v64; // x1 cocos2d::CCLabelBMFont *v65; // x23 char *v66; // [xsp+90h] [xbp+80h] void (__fastcall *v67)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // [xsp+98h] [xbp+88h] void (__fastcall *v68)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // [xsp+98h] [xbp+88h] CCMenuItemSpriteExtra *m_normalButton; // [xsp+98h] [xbp+88h] const cocos2d::CCPoint *v70; // [xsp+98h] [xbp+88h] void (__fastcall *v71)(cocos2d::CCNode *__hidden, const cocos2d::CCPoint *); // [xsp+98h] [xbp+88h] __int64 v72; // [xsp+98h] [xbp+88h] __int64 v73; // [xsp+A0h] [xbp+90h] BYREF char v74[8]; // [xsp+A8h] [xbp+98h] BYREF cocos2d::CCPoint v75; // [xsp+B0h] [xbp+A0h] BYREF cocos2d::CCRect v76; // [xsp+B8h] [xbp+A8h] BYREF char v77; // [xsp+D0h] [xbp+C0h] cocos2d::CCPoint v78; // 0:kr00_8.8 cocos2d::CCPoint v79; // 0:kr08_8.8 cocos2d::CCPoint v80; // 0:kr10_8.8 cocos2d::CCPoint v81; // 0:kr18_8.8 cocos2d::CCPoint v82; // 0:kr20_8.8 cocos2d::SEL_MenuHandler v83; // 0:x2.16 cocos2d::SEL_MenuHandler v84; // 0:x2.16 cocos2d::SEL_MenuHandler v85; // 0:x2.16 cocos2d::SEL_MenuHandler v86; // 0:x2.16 cocos2d::SEL_MenuHandler v87; // 0:x2.16 cocos2d::SEL_MenuHandler v88; // 0:x2.16 cocos2d::CCRect v89; // 0:s0.4,4:s1.4,8:s2.4,12:s3.4 v16 = (cocos2d::CCNode *)a9; v17 = cocos2d::CCNode::init(a1); v18 = v17; if ( v17 ) { v20 = (cocos2d::CCArray *)cocos2d::CCArray::create((cocos2d::CCArray *)v17); a1->m_selectSongObjects = v20; cocos2d::CCObject::retain(v20); a1->m_selectedSongID = a2; a1->m_settingsObject = a4; if ( a5 == Custom ) { a1->m_isCustomSong = 1; } else { if ( a5 == Default2 ) a3 = 0; a1->m_isCustomSong = a3; } cocos2d::CCPoint::CCPoint(&v76.origin, -65.0, 60.0); cocos2d::CCPoint::operator+(&v73, a7, &v76); if ( !v77 ) { v65 = cocos2d::CCLabelBMFont::create(); a8->addChild(a8, v65); v65->setScale(v65, 0.8); v65->setPosition(v65, (const cocos2d::CCPoint *)&v73); cocos2d::CCArray::addObject(a1->m_selectSongObjects, v65); } cocos2d::CCRect::CCRect(&v76, 0.0, 0.0, 80.0, 80.0); v21 = (cocos2d::CCNode *)cocos2d::extension::CCScale9Sprite::create( (cocos2d::extension::CCScale9Sprite *)"square02_001.png", (const char *)&v76, v89); ((void (__fastcall *)(cocos2d::CCNode *, __int64))v21->__vftable[1].~CCNode_0)(v21, 75); setContentSize = v21->setContentSize; cocos2d::CCSize::CCSize((cocos2d::CCSize *)&v76, 300.0, 90.0); setContentSize(v21, (const cocos2d::CCSize *)&v76); a8->addChild_0(a8, v21, -1); setPosition = v21->setPosition; cocos2d::CCPoint::CCPoint(&v76.origin, *(float *)&a7->__vftable, *((float *)&v73 + 1) - 58.0); setPosition(v21, &v76.origin); v24 = (cocos2d::CCArray *)cocos2d::CCArray::addObject(a1->m_selectSongObjects, v21); v25 = (cocos2d::CCArray *)cocos2d::CCArray::create(v24); a1->m_normalSongObjects = v25; cocos2d::CCObject::retain(v25); v27 = (cocos2d::CCArray *)cocos2d::CCArray::create(v26); a1->m_changeSongObjects = v27; cocos2d::CCObject::retain(v27); v28 = cocos2d::CCLabelBMFont::create(); v29 = a8->cocos2d::CCLayerRGBA::cocos2d::CCLayer::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; a1->m_audioLabel = v28; ((void (__fastcall *)(cocos2d::CCMenu *))v29->addChild)(a8); m_audioLabel = a1->m_audioLabel; v31 = m_audioLabel->setPosition; v32 = (__int64)v21->getPosition(v21); v31(m_audioLabel, (const cocos2d::CCPoint *)v32); cocos2d::CCArray::addObject(a1->m_normalSongObjects, a1->m_audioLabel); if ( !a1->m_isCustomSong ) SongSelectNode::updateAudioLabel(a1); v66 = "bigFont.fnt"; y = a1->m_audioLabel->getPosition(a1->m_audioLabel)->y; v34 = cocos2d::CCSprite::createWithSpriteFrameName("edit_leftBtn_001.png"); v34->setScale(v34, 1.2); v83.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v83.adj = (size_t)SongSelectNode::audioPrevious; v35 = CCMenuItemSpriteExtra::create(v34, nullptr, v83); v16->addChild(v16, v35); cocos2d::CCArray::addObject(a1->m_normalSongObjects, v35); v67 = v35->setPosition; cocos2d::CCPoint::CCPoint(&v76.origin, *(float *)&a7->__vftable - 120.0, y); v78 = cocos2d::CCNode::convertToNodeSpace(v16, &v76.origin); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCPoint *, float, float))v67)(v35, &v75, v78.x, v78.y); CCMenuItemSpriteExtra::setSizeMult(v35, 2.0); v36 = cocos2d::CCSprite::createWithSpriteFrameName("edit_rightBtn_001.png"); v36->setScale(v36, 1.2); v84.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v84.adj = (size_t)SongSelectNode::audioNext; v37 = CCMenuItemSpriteExtra::create(v36, nullptr, v84); v16->addChild(v16, v37); cocos2d::CCArray::addObject(a1->m_normalSongObjects, v37); v68 = v37->setPosition; cocos2d::CCPoint::CCPoint(&v76.origin, *(float *)&a7->__vftable + 120.0, y); v79 = cocos2d::CCNode::convertToNodeSpace(v16, &v76.origin); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCPoint *, float, float))v68)(v37, &v75, v79.x, v79.y); CCMenuItemSpriteExtra::setSizeMult(v37, 2.0); v38 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"Normal", (const char *)&qword_28, 0, 0, 0.4, v66, "GJ_button_01.png", v66, 20.0); v85.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v85.adj = (size_t)SongSelectNode::onSongMode; v39 = CCMenuItemSpriteExtra::create(v38, nullptr, v85); a1->m_normalButton = v39; CCMenuItemSpriteExtra::setSizeMult(v39, 1.1); v16->addChild(v16, a1->m_normalButton); v40 = *(float *)&a7->__vftable; m_normalButton = a1->m_normalButton; v41 = m_normalButton->setPosition; cocos2d::CCPoint::CCPoint(&v76.origin, v40 + 40.0, *((float *)&v73 + 1) - 1.0); v80 = cocos2d::CCNode::convertToNodeSpace(v16, &v76.origin); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCPoint *, float, float))v41)( m_normalButton, &v75, v80.x, v80.y); a1->m_normalButton->setTag(a1->m_normalButton, 1); v42 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"Custom", (const char *)&qword_28, 0, 0, 0.4, v66, "GJ_button_01.png", v66, 20.0); v86.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v86.adj = (size_t)SongSelectNode::onSongMode; v43 = CCMenuItemSpriteExtra::create(v42, nullptr, v86); a1->m_customButton = v43; CCMenuItemSpriteExtra::setSizeMult(v43, 1.1); v16->addChild(v16, a1->m_customButton); m_customButton = a1->m_customButton; v45 = m_customButton->setPosition; v70 = a1->m_normalButton->getPosition(a1->m_normalButton); cocos2d::CCPoint::CCPoint(&v76.origin, 62.0, 0.0); cocos2d::CCPoint::operator+(&v75, v70, &v76); v45(m_customButton, &v75); a1->m_customButton->setTag(a1->m_customButton, 2); if ( a5 ) { a1->m_normalButton->setVisible(a1->m_normalButton, 0); a1->m_normalButton->setEnabled(a1->m_normalButton, 0); a1->m_customButton->setVisible(a1->m_customButton, 0); a1->m_customButton->setEnabled(a1->m_customButton, 0); } v47 = (cocos2d::CCNode *)ButtonSprite::create( (ButtonSprite *)"Select Custom song", (const char *)off_88 + 4, 0, 1, 0.8, "bigFont.fnt", "GJ_button_04.png", v46, 30.0); v87.adj = (size_t)SongSelectNode::onOpenCustomSong; v87.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v48 = CCMenuItemSpriteExtra::create(v47, nullptr, v87); v49 = v16->__vftable; a1->m_selectButton = v48; ((void (__fastcall *)(cocos2d::CCNode *))v49->addChild)(v16); m_selectButton = a1->m_selectButton; v71 = m_selectButton->setPosition; v51 = v21->getPosition(v21); v81 = cocos2d::CCNode::convertToNodeSpace(v16, v51); ((void (__fastcall *)(CCMenuItemSpriteExtra *, cocos2d::CCRect *, float, float))v71)( m_selectButton, &v76, v81.x, v81.y); cocos2d::CCArray::addObject(a1->m_changeSongObjects, a1->m_selectButton); v52 = cocos2d::CCSprite::createWithSpriteFrameName("GJ_changeSongBtn_001.png"); v88.adj = (size_t)SongSelectNode::onOpenCustomSong; v88.ptr = (void (__cdecl *)(cocos2d::CCObject *))a1; v53 = CCMenuItemSpriteExtra::create(v52, nullptr, v88); v54 = v16->__vftable; a1->m_changeButton = v53; v54->addChild(v16, v53); m_changeButton = a1->m_changeButton; v56 = m_changeButton->setPosition; v72 = (__int64)v21->getPosition(v21); cocos2d::CCPoint::CCPoint(&v76.origin, 127.0, -20.0); cocos2d::CCPoint::operator+(&v75, v72, &v76); v82 = cocos2d::CCNode::convertToNodeSpace(v16, &v75); ((void (__fastcall *)(CCMenuItemSpriteExtra *, char *, float, float))v56)(m_changeButton, v74, v82.x, v82.y); cocos2d::CCArray::addObject(a1->m_changeSongObjects, a1->m_changeButton); SongInfoObject = nullptr; if ( a1->m_isCustomSong && a1->m_selectedSongID ) { v58 = MusicDownloadManager::sharedState(); SongInfoObject = MusicDownloadManager::getSongInfoObject(v58, a1->m_selectedSongID); } v59 = CustomSongWidget::create(SongInfoObject, &a1->CustomSongDelegate, 0, 1, 0, 0, 1, 0, 0); v60 = a8->cocos2d::CCLayerRGBA::cocos2d::CCLayer::cocos2d::CCNode::cocos2d::CCObject::cocos2d::CCCopying::__vftable; a1->m_songWidget = v59; ((void (__fastcall *)(cocos2d::CCMenu *))v60->addChild)(a8); m_songWidget = a1->m_songWidget; v62 = m_songWidget->setPosition; v63 = (__int64)v21->getPosition(v21); v62(m_songWidget, (const cocos2d::CCPoint *)v63); cocos2d::CCArray::addObject(a1->m_selectSongObjects, a1->m_songWidget); v64 = a1->m_normalButton; if ( a1->m_isCustomSong ) v64 = a1->m_customButton; SongSelectNode::onSongMode(a1, v64); } return v18; }
GD Web Decomp Icon

GD Web Decomp

Raw Source