{"type": "func", "start": 4298931648, "end": 4298931965, "name": "DialogLayer::handleDialogTap", "pseudocode": "// \n// DialogLayer::handleDialogTap from 0x1003c7dc0 to 0x1003c7efd (317 bytes)\n// \n// 4 xrefs:\n// > DialogLayer::ccTouchBegan @ 0x1003c81e9\n// > sub_1003C8200 @ 0x1003c8220\n// > DialogLayer::keyDown @ 0x1003c86d3\n// > sub_1003C86E0 @ 0x1003c871a\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\nvoid __fastcall DialogLayer::handleDialogTap(DialogLayer *a1)\n{\n  float m_animateTime; // xmm0_4\n  float v3; // xmm0_4\n  cocos2d::CCArray *m_dialogObjects; // rdi\n  DialogDelegate *m_delegate; // rdi\n  TextArea *m_textArea; // rax\n  timeb v7; // [rsp+8h] [rbp-18h] BYREF\n\n  ftime(&v7);\n  m_animateTime = a1->m_animateTime;\n  if ( m_animateTime <= 0.0\n    || (v3 = (double)(v7.millitm + 1000 * (v7.time & 0xFFFFF)) / 1000.0 - m_animateTime, v3 >= 0.2)\n    || a1->m_handleTap\n    || v3 < 0.0 )\n  {\n    if ( a1->m_animating )\n    {\n      if ( !a1->m_skippable )\n        DialogLayer::finishCurrentAnimation(a1);\n    }\n    else\n    {\n      m_dialogObjects = a1->m_dialogObjects;\n      if ( m_dialogObjects && (unsigned int)sub_100720070(m_dialogObjects) )\n      {\n        DialogLayer::displayNextObject(a1);\n      }\n      else\n      {\n        m_delegate = a1->m_delegate;\n        if ( m_delegate )\n          ((void (__fastcall *)(DialogDelegate *, DialogLayer *))m_delegate->dialogClosed)(m_delegate, a1);\n        a1->m_delegate = nullptr;\n        m_textArea = a1->m_textArea;\n        if ( m_textArea )\n          m_textArea->m_delegate = nullptr;\n        ((void (__fastcall *)(DialogLayer *, _QWORD))a1->setKeypadEnabled)(a1, 0);\n        ((void (__fastcall *)(DialogLayer *, _QWORD))a1->setKeyboardEnabled)(a1, 0);\n        if ( !a1->m_noRemove )\n          ((void (__fastcall *)(DialogLayer *, __int64))a1->removeFromParentAndCleanup)(a1, 1);\n      }\n    }\n  }\n}", "assembly": "; \n; DialogLayer::handleDialogTap from 0x1003c7dc0 to 0x1003c7efd (317 bytes)\n; \n; 4 xrefs:\n; > DialogLayer::ccTouchBegan @ 0x1003c81e9\n; > sub_1003C8200 @ 0x1003c8220\n; > DialogLayer::keyDown @ 0x1003c86d3\n; > sub_1003C86E0 @ 0x1003c871a\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\npush    rbp                                                            ; +0x0, 0x1003c7dc0\nmov     rbp, rsp                                                       ; +0x1, 0x1003c7dc1\npush    rbx                                                            ; +0x4, 0x1003c7dc4\nsub     rsp, 18h                                                       ; +0x5, 0x1003c7dc5\nmov     rbx, rdi                                                       ; +0x9, 0x1003c7dc9\nlea     rdi, [rbp+var_18]; timeb *                                     ; +0xc, 0x1003c7dcc\ncall    _ftime                                                         ; +0x10, 0x1003c7dd0\nmovss   xmm0, dword ptr [rbx+228h]                                     ; +0x15, 0x1003c7dd5\nxorps   xmm1, xmm1                                                     ; +0x1d, 0x1003c7ddd\nucomiss xmm0, xmm1                                                     ; +0x20, 0x1003c7de0\njbe     short loc_1003C7E41                                            ; +0x23, 0x1003c7de3\nmovzx   eax, [rbp+var_18.millitm]                                      ; +0x25, 0x1003c7de5\nmov     rcx, [rbp+var_18.time]                                         ; +0x29, 0x1003c7de9\nand     ecx, 0FFFFFh                                                   ; +0x2d, 0x1003c7ded\nimul    rcx, 3E8h                                                      ; +0x33, 0x1003c7df3\nadd     rcx, rax                                                       ; +0x3a, 0x1003c7dfa\nxorps   xmm1, xmm1                                                     ; +0x3d, 0x1003c7dfd\ncvtsi2sd xmm1, rcx                                                     ; +0x40, 0x1003c7e00\ndivsd   xmm1, cs:qword_100815208                                       ; +0x45, 0x1003c7e05\ncvtss2sd xmm0, xmm0                                                    ; +0x4d, 0x1003c7e0d\nsubsd   xmm1, xmm0                                                     ; +0x51, 0x1003c7e11\nxorps   xmm0, xmm0                                                     ; +0x55, 0x1003c7e15\ncvtsd2ss xmm0, xmm1                                                    ; +0x58, 0x1003c7e18\nmovss   xmm1, cs:dword_10081541C                                       ; +0x5c, 0x1003c7e1c\nucomiss xmm1, xmm0                                                     ; +0x64, 0x1003c7e24\njbe     short loc_1003C7E41                                            ; +0x67, 0x1003c7e27\ncmp     byte ptr [rbx+278h], 0                                         ; +0x69, 0x1003c7e29\njnz     short loc_1003C7E41                                            ; +0x70, 0x1003c7e30\nxorps   xmm1, xmm1                                                     ; +0x72, 0x1003c7e32\nucomiss xmm0, xmm1                                                     ; +0x75, 0x1003c7e35\njb      short loc_1003C7E41                                            ; +0x78, 0x1003c7e38\nadd     rsp, 18h                                                       ; +0x7a, 0x1003c7e3a\npop     rbx                                                            ; +0x7e, 0x1003c7e3e\npop     rbp                                                            ; +0x7f, 0x1003c7e3f\nretn                                                                   ; +0x80, 0x1003c7e40\ncmp     byte ptr [rbx+268h], 1                                         ; +0x81, 0x1003c7e41\njnz     short loc_1003C7E62                                            ; +0x88, 0x1003c7e48\ncmp     byte ptr [rbx+269h], 0                                         ; +0x8a, 0x1003c7e4a\njnz     short loc_1003C7E3A                                            ; +0x91, 0x1003c7e51\nmov     rdi, rbx                                                       ; +0x93, 0x1003c7e53\ncall    DialogLayer__finishCurrentAnimation                            ; +0x96, 0x1003c7e56\nadd     rsp, 18h                                                       ; +0x9b, 0x1003c7e5b\npop     rbx                                                            ; +0x9f, 0x1003c7e5f\npop     rbp                                                            ; +0xa0, 0x1003c7e60\nretn                                                                   ; +0xa1, 0x1003c7e61\nmov     rdi, [rbx+250h]                                                ; +0xa2, 0x1003c7e62\ntest    rdi, rdi                                                       ; +0xa9, 0x1003c7e69\njz      short loc_1003C7E86                                            ; +0xac, 0x1003c7e6c\ncall    sub_100720070                                                  ; +0xae, 0x1003c7e6e\ntest    eax, eax                                                       ; +0xb3, 0x1003c7e73\njz      short loc_1003C7E86                                            ; +0xb5, 0x1003c7e75\nmov     rdi, rbx                                                       ; +0xb7, 0x1003c7e77\ncall    DialogLayer__displayNextObject                                 ; +0xba, 0x1003c7e7a\nadd     rsp, 18h                                                       ; +0xbf, 0x1003c7e7f\npop     rbx                                                            ; +0xc3, 0x1003c7e83\npop     rbp                                                            ; +0xc4, 0x1003c7e84\nretn                                                                   ; +0xc5, 0x1003c7e85\nmov     rdi, [rbx+270h]                                                ; +0xc6, 0x1003c7e86\ntest    rdi, rdi                                                       ; +0xcd, 0x1003c7e8d\njz      short loc_1003C7E9A                                            ; +0xd0, 0x1003c7e90\nmov     rax, [rdi]                                                     ; +0xd2, 0x1003c7e92\nmov     rsi, rbx                                                       ; +0xd5, 0x1003c7e95\ncall    qword ptr [rax]                                                ; +0xd8, 0x1003c7e98\nmov     qword ptr [rbx+270h], 0                                        ; +0xda, 0x1003c7e9a\nmov     rax, [rbx+240h]                                                ; +0xe5, 0x1003c7ea5\ntest    rax, rax                                                       ; +0xec, 0x1003c7eac\njz      short loc_1003C7EBC                                            ; +0xef, 0x1003c7eaf\nmov     qword ptr [rax+2B0h], 0                                        ; +0xf1, 0x1003c7eb1\nmov     rax, [rbx]                                                     ; +0xfc, 0x1003c7ebc\nmov     rdi, rbx                                                       ; +0xff, 0x1003c7ebf\nxor     esi, esi                                                       ; +0x102, 0x1003c7ec2\ncall    qword ptr [rax+420h]                                           ; +0x104, 0x1003c7ec4\nmov     rax, [rbx]                                                     ; +0x10a, 0x1003c7eca\nmov     rdi, rbx                                                       ; +0x10d, 0x1003c7ecd\nxor     esi, esi                                                       ; +0x110, 0x1003c7ed0\ncall    qword ptr [rax+430h]                                           ; +0x112, 0x1003c7ed2\ncmp     byte ptr [rbx+280h], 0                                         ; +0x118, 0x1003c7ed8\njnz     loc_1003C7E3A                                                  ; +0x11f, 0x1003c7edf\nmov     rax, [rbx]                                                     ; +0x125, 0x1003c7ee5\nmov     rdi, rbx                                                       ; +0x128, 0x1003c7ee8\nmov     esi, 1                                                         ; +0x12b, 0x1003c7eeb\ncall    qword ptr [rax+200h]                                           ; +0x130, 0x1003c7ef0\nadd     rsp, 18h                                                       ; +0x136, 0x1003c7ef6\npop     rbx                                                            ; +0x13a, 0x1003c7efa\npop     rbp                                                            ; +0x13b, 0x1003c7efb\nretn                                                                   ; +0x13c, 0x1003c7efc", "xrefs": ["DialogLayer::ccTouchBegan @ 0x1003c81e9", "sub_1003C8200 @ 0x1003c8220", "DialogLayer::keyDown @ 0x1003c86d3", "sub_1003C86E0 @ 0x1003c871a"], "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"}