{"type": "func", "start": 4296184016, "end": 4296184224, "name": "GJBaseGameLayer::shouldUseSubstepForButton", "pseudocode": "// \n// GJBaseGameLayer::shouldUseSubstepForButton from 0x1001290d0 to 0x1001291a0 (208 bytes)\n// \n// 0 xrefs:\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:24:43 +0000\n// \n\nchar __fastcall GJBaseGameLayer::shouldUseSubstepForButton(__int64 a1, float a2)\n{\n  __int64 v2; // r15\n  __int64 v3; // r14\n  double v4; // xmm2_8\n  double v5; // xmm1_8\n  __int64 v6; // r15\n  double v7; // xmm0_8\n  char result; // al\n  bool v9; // zf\n  double v10; // [rsp-30h] [rbp-30h]\n  double v11; // [rsp-28h] [rbp-28h]\n\n  if ( *(_BYTE *)(a1 + 13945) != 1 )\n    return 0;\n  v2 = *(_QWORD *)(a1 + 12824);\n  v3 = *(_QWORD *)(a1 + 12832);\n  if ( v2 == v3 )\n    return 0;\n  v4 = *(double *)(a1 + 13936) + a2;\n  v5 = a2 * 0.5 + *(double *)(a1 + 13936);\n  v6 = v2 + 24;\n  v10 = v5;\n  v11 = v4;\n  while ( 1 )\n  {\n    v7 = *(double *)(v6 - 8);\n    if ( v7 >= v5 && v4 > v7 )\n    {\n      v4 = v11;\n      v5 = v10;\n      if ( (unsigned __int8)GJBaseGameLayer::buttonIsRelevant(a1, v6 - 24) )\n        break;\n    }\n    result = 0;\n    if ( v7 < v4 )\n    {\n      v9 = v6 == v3;\n      v6 += 24;\n      if ( !v9 )\n        continue;\n    }\n    return result;\n  }\n  return 1;\n}", "assembly": "; \n; GJBaseGameLayer::shouldUseSubstepForButton from 0x1001290d0 to 0x1001291a0 (208 bytes)\n; \n; 0 xrefs:\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:24:43 +0000\n; \ncmp     byte ptr [rdi+3679h], 1                                        ; +0x0, 0x1001290d0\njnz     loc_10012918C                                                  ; +0x7, 0x1001290d7\npush    rbp                                                            ; +0xd, 0x1001290dd\nmov     rbp, rsp                                                       ; +0xe, 0x1001290de\npush    r15                                                            ; +0x11, 0x1001290e1\npush    r14                                                            ; +0x13, 0x1001290e3\npush    rbx                                                            ; +0x15, 0x1001290e5\nsub     rsp, 18h                                                       ; +0x16, 0x1001290e6\nmov     rbx, rdi                                                       ; +0x1a, 0x1001290ea\nmov     r15, [rdi+3218h]                                               ; +0x1d, 0x1001290ed\nmov     r14, [rdi+3220h]                                               ; +0x24, 0x1001290f4\ncmp     r15, r14                                                       ; +0x2b, 0x1001290fb\njz      loc_10012918F                                                  ; +0x2e, 0x1001290fe\ncvtss2sd xmm1, xmm0                                                    ; +0x34, 0x100129104\nmovsd   xmm0, qword ptr [rbx+3670h]                                    ; +0x38, 0x100129108\nmovapd  xmm2, xmm0                                                     ; +0x40, 0x100129110\naddsd   xmm2, xmm1                                                     ; +0x44, 0x100129114\nmulsd   xmm1, cs:qword_100A04880                                       ; +0x48, 0x100129118\naddsd   xmm1, xmm0                                                     ; +0x50, 0x100129120\nadd     r15, 18h                                                       ; +0x54, 0x100129124\nmovsd   qword ptr [rbp-28h], xmm1                                      ; +0x58, 0x100129128\nmovsd   qword ptr [rbp-20h], xmm2                                      ; +0x5d, 0x10012912d\nnop     word ptr [rax+rax+00000000h]                                   ; +0x62, 0x100129132\nmovsd   xmm0, qword ptr [r15-8]                                        ; +0x70, 0x100129140\nucomisd xmm0, xmm1                                                     ; +0x76, 0x100129146\njb      short loc_100129176                                            ; +0x7a, 0x10012914a\nucomisd xmm2, xmm0                                                     ; +0x7c, 0x10012914c\njbe     short loc_100129176                                            ; +0x80, 0x100129150\nlea     rsi, [r15-18h]                                                 ; +0x82, 0x100129152\nmov     rdi, rbx                                                       ; +0x86, 0x100129156\nmovsd   qword ptr [rbp-30h], xmm0                                      ; +0x89, 0x100129159\ncall    GJBaseGameLayer__buttonIsRelevant                              ; +0x8e, 0x10012915e\nmovsd   xmm0, qword ptr [rbp-30h]                                      ; +0x93, 0x100129163\nmovsd   xmm2, qword ptr [rbp-20h]                                      ; +0x98, 0x100129168\nmovsd   xmm1, qword ptr [rbp-28h]                                      ; +0x9d, 0x10012916d\ntest    al, al                                                         ; +0xa2, 0x100129172\njnz     short loc_100129193                                            ; +0xa4, 0x100129174\nxor     eax, eax                                                       ; +0xa6, 0x100129176\nucomisd xmm0, xmm2                                                     ; +0xa8, 0x100129178\njnb     short loc_100129195                                            ; +0xac, 0x10012917c\nlea     rcx, [r15+18h]                                                 ; +0xae, 0x10012917e\ncmp     r15, r14                                                       ; +0xb2, 0x100129182\nmov     r15, rcx                                                       ; +0xb5, 0x100129185\njnz     short loc_100129140                                            ; +0xb8, 0x100129188\njmp     short loc_100129195                                            ; +0xba, 0x10012918a\nxor     eax, eax                                                       ; +0xbc, 0x10012918c\nretn                                                                   ; +0xbe, 0x10012918e\nxor     eax, eax                                                       ; +0xbf, 0x10012918f\njmp     short loc_100129195                                            ; +0xc1, 0x100129191\nmov     al, 1                                                          ; +0xc3, 0x100129193\nadd     rsp, 18h                                                       ; +0xc5, 0x100129195\npop     rbx                                                            ; +0xc9, 0x100129199\npop     r14                                                            ; +0xca, 0x10012919a\npop     r15                                                            ; +0xcc, 0x10012919c\npop     rbp                                                            ; +0xce, 0x10012919e\nretn                                                                   ; +0xcf, 0x10012919f", "xrefs": [], "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"}