{"type": "func", "start": 4296322464, "end": 4296322672, "name": "GJBaseGameLayer::shouldUseSubstepForButton", "pseudocode": "// \n// GJBaseGameLayer::shouldUseSubstepForButton from 0x10014ada0 to 0x10014ae70 (208 bytes)\n// \n// 0 xrefs:\n// \n// This function is hookable on this platform!\n// \n// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings\n// \n\nbool __fastcall GJBaseGameLayer::shouldUseSubstepForButton(GJBaseGameLayer *a1, float a2)\n{\n  std::__vector_base<PlayerButtonCommand>::pointer begin; // r15\n  std::__vector_base<PlayerButtonCommand>::pointer end; // r14\n  double v4; // xmm2_8\n  double v5; // xmm1_8\n  std::__vector_base<PlayerButtonCommand>::pointer v6; // r15\n  double m_timestamp; // xmm0_8\n  bool result; // al\n  double v10; // [rsp-30h] [rbp-30h]\n  double v11; // [rsp-28h] [rbp-28h]\n\n  if ( !a1->m_clickBetweenSteps )\n    return 0;\n  begin = a1->m_queuedButtons.__begin_;\n  end = a1->m_queuedButtons.__end_;\n  if ( begin == end )\n    return 0;\n  v4 = a1->m_timestamp + a2;\n  v5 = a2 * 0.5 + a1->m_timestamp;\n  v6 = begin + 1;\n  v10 = v5;\n  v11 = v4;\n  while ( 1 )\n  {\n    m_timestamp = v6[-1].m_timestamp;\n    if ( m_timestamp >= v5 && v4 > m_timestamp )\n    {\n      v4 = v11;\n      v5 = v10;\n      if ( GJBaseGameLayer::buttonIsRelevant(a1, v6 - 1) )\n        break;\n    }\n    result = 0;\n    if ( m_timestamp < v4 && v6++ != end )\n      continue;\n    return result;\n  }\n  return 1;\n}", "assembly": "; \n; GJBaseGameLayer::shouldUseSubstepForButton from 0x10014ada0 to 0x10014ae70 (208 bytes)\n; \n; 0 xrefs:\n; \n; This function is hookable on this platform!\n; \n; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA\n; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings\n; \n\ncmp     byte ptr [rdi+3569h], 1                                        ; +0x0, 0x10014ada0\njnz     loc_10014AE5C                                                  ; +0x7, 0x10014ada7\npush    rbp                                                            ; +0xd, 0x10014adad\nmov     rbp, rsp                                                       ; +0xe, 0x10014adae\npush    r15                                                            ; +0x11, 0x10014adb1\npush    r14                                                            ; +0x13, 0x10014adb3\npush    rbx                                                            ; +0x15, 0x10014adb5\nsub     rsp, 18h                                                       ; +0x16, 0x10014adb6\nmov     rbx, rdi                                                       ; +0x1a, 0x10014adba\nmov     r15, [rdi+3160h]                                               ; +0x1d, 0x10014adbd\nmov     r14, [rdi+3168h]                                               ; +0x24, 0x10014adc4\ncmp     r15, r14                                                       ; +0x2b, 0x10014adcb\njz      loc_10014AE5F                                                  ; +0x2e, 0x10014adce\ncvtss2sd xmm1, xmm0                                                    ; +0x34, 0x10014add4\nmovsd   xmm0, qword ptr [rbx+3560h]                                    ; +0x38, 0x10014add8\nmovapd  xmm2, xmm0                                                     ; +0x40, 0x10014ade0\naddsd   xmm2, xmm1                                                     ; +0x44, 0x10014ade4\nmulsd   xmm1, cs:qword_100816490                                       ; +0x48, 0x10014ade8\naddsd   xmm1, xmm0                                                     ; +0x50, 0x10014adf0\nadd     r15, 18h                                                       ; +0x54, 0x10014adf4\nmovsd   qword ptr [rbp-28h], xmm1                                      ; +0x58, 0x10014adf8\nmovsd   qword ptr [rbp-20h], xmm2                                      ; +0x5d, 0x10014adfd\nnop     word ptr [rax+rax+00000000h]                                   ; +0x62, 0x10014ae02\nmovsd   xmm0, qword ptr [r15-8]                                        ; +0x70, 0x10014ae10\nucomisd xmm0, xmm1                                                     ; +0x76, 0x10014ae16\njb      short loc_10014AE46                                            ; +0x7a, 0x10014ae1a\nucomisd xmm2, xmm0                                                     ; +0x7c, 0x10014ae1c\njbe     short loc_10014AE46                                            ; +0x80, 0x10014ae20\nlea     rsi, [r15-18h]                                                 ; +0x82, 0x10014ae22\nmov     rdi, rbx                                                       ; +0x86, 0x10014ae26\nmovsd   qword ptr [rbp-30h], xmm0                                      ; +0x89, 0x10014ae29\ncall    GJBaseGameLayer__buttonIsRelevant                              ; +0x8e, 0x10014ae2e\nmovsd   xmm0, qword ptr [rbp-30h]                                      ; +0x93, 0x10014ae33\nmovsd   xmm2, qword ptr [rbp-20h]                                      ; +0x98, 0x10014ae38\nmovsd   xmm1, qword ptr [rbp-28h]                                      ; +0x9d, 0x10014ae3d\ntest    al, al                                                         ; +0xa2, 0x10014ae42\njnz     short loc_10014AE63                                            ; +0xa4, 0x10014ae44\nxor     eax, eax                                                       ; +0xa6, 0x10014ae46\nucomisd xmm0, xmm2                                                     ; +0xa8, 0x10014ae48\njnb     short loc_10014AE65                                            ; +0xac, 0x10014ae4c\nlea     rcx, [r15+18h]                                                 ; +0xae, 0x10014ae4e\ncmp     r15, r14                                                       ; +0xb2, 0x10014ae52\nmov     r15, rcx                                                       ; +0xb5, 0x10014ae55\njnz     short loc_10014AE10                                            ; +0xb8, 0x10014ae58\njmp     short loc_10014AE65                                            ; +0xba, 0x10014ae5a\nxor     eax, eax                                                       ; +0xbc, 0x10014ae5c\nretn                                                                   ; +0xbe, 0x10014ae5e\nxor     eax, eax                                                       ; +0xbf, 0x10014ae5f\njmp     short loc_10014AE65                                            ; +0xc1, 0x10014ae61\nmov     al, 1                                                          ; +0xc3, 0x10014ae63\nadd     rsp, 18h                                                       ; +0xc5, 0x10014ae65\npop     rbx                                                            ; +0xc9, 0x10014ae69\npop     r14                                                            ; +0xca, 0x10014ae6a\npop     r15                                                            ; +0xcc, 0x10014ae6c\npop     rbp                                                            ; +0xce, 0x10014ae6e\nretn                                                                   ; +0xcf, 0x10014ae6f", "xrefs": [], "is_objc": false, "is_arm32": false, "is_arm64": false, "bida_info": "8.0.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings"}