{"type": "func", "start": 4298701200, "end": 4298701291, "name": "BoomScrollLayer::getRelativePageForNum", "pseudocode": "// \n// BoomScrollLayer::getRelativePageForNum from 0x10038f990 to 0x10038f9eb (91 bytes)\n// \n// 4 xrefs:\n// > ListButtonBar::getPage @ 0x1003dd902\n// > EditButtonBar::onDotClicked @ 0x1006b4ae9\n// > EditButtonBar::updateDotState @ 0x1006b4ba5\n// > EditButtonBar::getPage @ 0x1006b4cc2\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\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 12:29:13 +0000\n// \n\nunsigned __int64 __fastcall BoomScrollLayer::getRelativePageForNum(__int64 a1, int a2)\n{\n  int v2; // ecx\n\n  v2 = sub_1007FEF90(*(_QWORD *)(a1 + 32 * (*(unsigned __int8 *)(a1 + 456) ^ 1u) + 448));\n  if ( a2 <= 0 )\n    return a2 + v2 * ((a2 != 0) + ((unsigned __int64)-__SPAIR64__(a2, a2) >> 32) / ((unsigned int)(v2 == 0) + v2));\n  else\n    return (unsigned int)(a2 % v2);\n}", "assembly": "; \n; BoomScrollLayer::getRelativePageForNum from 0x10038f990 to 0x10038f9eb (91 bytes)\n; \n; 4 xrefs:\n; > ListButtonBar::getPage @ 0x1003dd902\n; > EditButtonBar::onDotClicked @ 0x1006b4ae9\n; > EditButtonBar::updateDotState @ 0x1006b4ba5\n; > EditButtonBar::getPage @ 0x1006b4cc2\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\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 12:29:13 +0000\n; \npush    rbp                                                            ; +0x0, 0x10038f990\nmov     rbp, rsp                                                       ; +0x1, 0x10038f991\npush    rbx                                                            ; +0x4, 0x10038f994\npush    rax                                                            ; +0x5, 0x10038f995\nmov     ebx, esi                                                       ; +0x6, 0x10038f996\nmovzx   eax, byte ptr [rdi+1C8h]                                       ; +0x8, 0x10038f998\nxor     eax, 1                                                         ; +0xf, 0x10038f99f\nshl     eax, 5                                                         ; +0x12, 0x10038f9a2\nmov     rdi, [rdi+rax+1C0h]                                            ; +0x15, 0x10038f9a5\ncall    sub_1007FEF90                                                  ; +0x1d, 0x10038f9ad\nmov     ecx, eax                                                       ; +0x22, 0x10038f9b2\ntest    ebx, ebx                                                       ; +0x24, 0x10038f9b4\njle     short loc_10038F9C6                                            ; +0x26, 0x10038f9b6\nmov     eax, ebx                                                       ; +0x28, 0x10038f9b8\ncdq                                                                    ; +0x2a, 0x10038f9ba\nidiv    ecx                                                            ; +0x2b, 0x10038f9bb\nmov     eax, edx                                                       ; +0x2d, 0x10038f9bd\nadd     rsp, 8                                                         ; +0x2f, 0x10038f9bf\npop     rbx                                                            ; +0x33, 0x10038f9c3\npop     rbp                                                            ; +0x34, 0x10038f9c4\nretn                                                                   ; +0x35, 0x10038f9c5\nsetnz   al                                                             ; +0x36, 0x10038f9c6\nmovzx   esi, al                                                        ; +0x39, 0x10038f9c9\nlea     eax, [rsi+rbx]                                                 ; +0x3c, 0x10038f9cc\nneg     eax                                                            ; +0x3f, 0x10038f9cf\ncmp     ecx, 1                                                         ; +0x41, 0x10038f9d1\nmov     edi, ecx                                                       ; +0x44, 0x10038f9d4\nadc     edi, 0                                                         ; +0x46, 0x10038f9d6\nxor     edx, edx                                                       ; +0x49, 0x10038f9d9\ndiv     edi                                                            ; +0x4b, 0x10038f9db\nadd     eax, esi                                                       ; +0x4d, 0x10038f9dd\nimul    eax, ecx                                                       ; +0x4f, 0x10038f9df\nadd     eax, ebx                                                       ; +0x52, 0x10038f9e2\nadd     rsp, 8                                                         ; +0x54, 0x10038f9e4\npop     rbx                                                            ; +0x58, 0x10038f9e8\npop     rbp                                                            ; +0x59, 0x10038f9e9\nretn                                                                   ; +0x5a, 0x10038f9ea", "xrefs": ["ListButtonBar::getPage @ 0x1003dd902", "EditButtonBar::onDotClicked @ 0x1006b4ae9", "EditButtonBar::updateDotState @ 0x1006b4ba5", "EditButtonBar::getPage @ 0x1006b4cc2"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "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"}