{"type": "func", "start": 3937344, "end": 3937402, "name": "BoomScrollLayer::getPage", "pseudocode": "// \n// BoomScrollLayer::getPage from 0x3c1440 to 0x3c147a (58 bytes)\n// \n// 12 xrefs:\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1a0e\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1a40\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1a68\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1abe\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1acc\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1ada\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1b40\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1b4a\n// > BoomScrollLayer::repositionPagesLooped @ 0x3c1b54\n// > LevelSelectLayer::onDeathTracker @ 0x513622\n// > LevelSelectLayer::onPlay @ 0x51408c\n// > LevelSelectLayer::onInfo @ 0x5150de\n// \n// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:46:31 +0000\n// \n\nint __fastcall BoomScrollLayer::getPage(BoomScrollLayer *this, unsigned int a2)\n{\n  int v3; // r3\n  int v4; // r4\n  cocos2d::CCArray *v5; // r0\n  int v6; // r0\n\n  v3 = *((unsigned __int8 *)this + 348);\n  v4 = a2;\n  v5 = *((cocos2d::CCArray **)this + 91);\n  if ( v3 )\n  {\n    v6 = cocos2d::CCArray::count(v5);\n    if ( v4 <= 0 )\n    {\n      while ( v4 < 0 )\n        v4 += v6;\n    }\n    else\n    {\n      v4 %= v6;\n    }\n    v5 = *((cocos2d::CCArray **)this + 91);\n    a2 = v4;\n  }\n  return cocos2d::CCArray::objectAtIndex(v5, a2);\n}", "assembly": "; \n; BoomScrollLayer::getPage from 0x3c1440 to 0x3c147a (58 bytes)\n; \n; 12 xrefs:\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1a0e\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1a40\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1a68\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1abe\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1acc\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1ada\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1b40\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1b4a\n; > BoomScrollLayer::repositionPagesLooped @ 0x3c1b54\n; > LevelSelectLayer::onDeathTracker @ 0x513622\n; > LevelSelectLayer::onPlay @ 0x51408c\n; > LevelSelectLayer::onInfo @ 0x5150de\n; \n; This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:46:31 +0000\n; \nPUSH            {R3-R5,LR}                                             ; +0x0, 0x3c1440\nMOV             R5, R0                                                 ; +0x2, 0x3c1442\nLDRB.W          R3, [R0,#0x15C]                                        ; +0x4, 0x3c1444\nMOV             R4, R1                                                 ; +0x8, 0x3c1448\nLDR.W           R0, [R0,#0x16C]; this                                  ; +0xa, 0x3c144a\nCBZ             R3, loc_3C1472                                         ; +0xe, 0x3c144e\nBL              _ZNK7cocos2d7CCArray5countEv; cocos2d::CCArray::count(void) ; +0x10, 0x3c1450\nCMP             R4, #0                                                 ; +0x14, 0x3c1454\nMOV             R1, R0                                                 ; +0x16, 0x3c1456\nBLE             loc_3C1464                                             ; +0x18, 0x3c1458\nMOV             R0, R4                                                 ; +0x1a, 0x3c145a\nBLX             __aeabi_idivmod                                        ; +0x1c, 0x3c145c\nMOV             R4, R1                                                 ; +0x20, 0x3c1460\nB               loc_3C146C                                             ; +0x22, 0x3c1462\nCMP             R4, #0                                                 ; +0x24, 0x3c1464\nBGE             loc_3C146C                                             ; +0x26, 0x3c1466\nADD             R4, R1                                                 ; +0x28, 0x3c1468\nB               loc_3C1464                                             ; +0x2a, 0x3c146a\nLDR.W           R0, [R5,#0x16C]; this                                  ; +0x2c, 0x3c146c\nMOV             R1, R4; unsigned int                                   ; +0x30, 0x3c1470\nPOP.W           {R3-R5,LR}                                             ; +0x32, 0x3c1472\nB.W             _ZN7cocos2d7CCArray13objectAtIndexEj; cocos2d::CCArray::objectAtIndex(uint) ; +0x36, 0x3c1476", "xrefs": ["BoomScrollLayer::repositionPagesLooped @ 0x3c1a0e", "BoomScrollLayer::repositionPagesLooped @ 0x3c1a40", "BoomScrollLayer::repositionPagesLooped @ 0x3c1a68", "BoomScrollLayer::repositionPagesLooped @ 0x3c1abe", "BoomScrollLayer::repositionPagesLooped @ 0x3c1acc", "BoomScrollLayer::repositionPagesLooped @ 0x3c1ada", "BoomScrollLayer::repositionPagesLooped @ 0x3c1b40", "BoomScrollLayer::repositionPagesLooped @ 0x3c1b4a", "BoomScrollLayer::repositionPagesLooped @ 0x3c1b54", "LevelSelectLayer::onDeathTracker @ 0x513622", "LevelSelectLayer::onPlay @ 0x51408c", "LevelSelectLayer::onInfo @ 0x5150de"], "is_objc": false, "is_32_bit": true, "is_64_bit": false, "idp_name": "arm", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}