{"type": "func", "start": 3105576, "end": 3105752, "name": "CCTextInputNode::keyboardWillShow", "pseudocode": "// \n// CCTextInputNode::keyboardWillShow from 0x2f6328 to 0x2f63d8 (176 bytes)\n// \n// 1 xrefs:\n// > `non-virtual thunk to'CCTextInputNode::keyboardWillShow @ 0x2f63e0\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 CCTextInputNode::keyboardWillShow(CCTextInputNode *a1, cocos2d::CCIMEKeyboardNotificationInfo *a2)\n{\n  cocos2d::CCTextFieldTTF *m_textField; // r0\n  cocos2d::CCRect *p_end; // r5\n  const cocos2d::CCPoint *v5; // r0\n  float v6; // s16\n  float v7; // s15\n  TextInputDelegate *m_delegate; // r0\n  float v9; // s16\n  cocos2d::CCPoint v10; // [sp+4h] [bp-1Ch] BYREF\n  cocos2d::CCRect v11; // [sp+Ch] [bp-14h] BYREF\n\n  if ( !a1->m_forceOffset )\n  {\n    m_textField = a1->m_textField;\n    if ( m_textField )\n    {\n      if ( a1->m_selected )\n      {\n        p_end = &a2->end;\n        v5 = (const cocos2d::CCPoint *)((int (__fastcall *)(cocos2d::CCTextFieldTTF *, cocos2d::CCIMEKeyboardNotificationInfo *))m_textField->getAnchorPoint)(\n                                         m_textField,\n                                         a2);\n        cocos2d::CCPoint::CCPoint(&v10, v5);\n        sub_2F62CC(&v11, (int)a1, &v10.x);\n        v11.origin.y = v11.origin.y - 4.0;\n        if ( cocos2d::CCRect::intersectsRect(&v11, p_end) )\n        {\n          a1->m_unknown2 = 1;\n          v6 = COERCE_FLOAT(cocos2d::CCRect::getMaxY(p_end));\n          v7 = COERCE_FLOAT(cocos2d::CCRect::getMinY(&v11));\n          m_delegate = a1->m_delegate;\n          v9 = v6 - v7;\n          if ( m_delegate )\n            m_delegate->textInputShouldOffset(m_delegate, a1, COERCE_FLOAT(LODWORD(v9)));\n        }\n      }\n    }\n  }\n}", "assembly": "; \n; CCTextInputNode::keyboardWillShow from 0x2f6328 to 0x2f63d8 (176 bytes)\n; \n; 1 xrefs:\n; > `non-virtual thunk to'CCTextInputNode::keyboardWillShow @ 0x2f63e0\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\nLDR             R3, =(__stack_chk_guard_ptr - 0x2F6332)                ; +0x0, 0x2f6328\nPUSH.W          {R4-R8,LR}                                             ; +0x2, 0x2f632a\nADD             R3, PC; __stack_chk_guard_ptr                          ; +0x6, 0x2f632e\nLDR             R3, [R3]; __stack_chk_guard                            ; +0x8, 0x2f6330\nVPUSH           {D8}                                                   ; +0xa, 0x2f6332\nMOV             R4, R0                                                 ; +0xe, 0x2f6336\nLDR             R2, [R3]                                               ; +0x10, 0x2f6338\nMOV             R5, R1                                                 ; +0x12, 0x2f633a\nMOV             R6, R3                                                 ; +0x14, 0x2f633c\nSUB             SP, SP, #0x20                                          ; +0x16, 0x2f633e\nSTR             R2, [SP,#0x20+var_4]                                   ; +0x18, 0x2f6340\nLDRB.W          R2, [R0,#0x18E]                                        ; +0x1a, 0x2f6342\nCMP             R2, #0                                                 ; +0x1e, 0x2f6346\nBNE             loc_2F63C2                                             ; +0x20, 0x2f6348\nLDR.W           R0, [R0,#0x17C]                                        ; +0x22, 0x2f634a\nCBZ             R0, loc_2F63C2                                         ; +0x26, 0x2f634e\nLDRB.W          R3, [R4,#0x150]                                        ; +0x28, 0x2f6350\nCBZ             R3, loc_2F63C2                                         ; +0x2c, 0x2f6354\nLDR             R3, [R0]                                               ; +0x2e, 0x2f6356\nADD.W           R8, SP, #0x20+var_1C                                   ; +0x30, 0x2f6358\nADD             R7, SP, #0x20+var_14                                   ; +0x34, 0x2f635c\nADDS            R5, #0x10                                              ; +0x36, 0x2f635e\nLDR.W           R3, [R3,#0x90]                                         ; +0x38, 0x2f6360\nBLX             R3                                                     ; +0x3c, 0x2f6364\nMOV             R1, R0; cocos2d::CCPoint *                             ; +0x3e, 0x2f6366\nMOV             R0, R8; this                                           ; +0x40, 0x2f6368\nBL              _ZN7cocos2d7CCPointC1ERKS0_; cocos2d::CCPoint::CCPoint(cocos2d::CCPoint const&) ; +0x42, 0x2f636a\nMOV             R0, R7                                                 ; +0x46, 0x2f636e\nMOV             R1, R4                                                 ; +0x48, 0x2f6370\nMOV             R2, R8                                                 ; +0x4a, 0x2f6372\nBL              sub_2F62CC                                             ; +0x4c, 0x2f6374\nVMOV.F32        S14, #4.0                                              ; +0x50, 0x2f6378\nVLDR            S15, [SP,#0x20+var_10]                                 ; +0x54, 0x2f637c\nMOV             R0, R7; this                                           ; +0x58, 0x2f6380\nMOV             R1, R5; cocos2d::CCRect *                              ; +0x5a, 0x2f6382\nVSUB.F32        S15, S15, S14                                          ; +0x5c, 0x2f6384\nVSTR            S15, [SP,#0x20+var_10]                                 ; +0x60, 0x2f6388\nBL              _ZNK7cocos2d6CCRect14intersectsRectERKS0_; cocos2d::CCRect::intersectsRect(cocos2d::CCRect const&) ; +0x64, 0x2f638c\nCBZ             R0, loc_2F63C2                                         ; +0x68, 0x2f6390\nMOVS            R3, #1                                                 ; +0x6a, 0x2f6392\nMOV             R0, R5; this                                           ; +0x6c, 0x2f6394\nSTRB.W          R3, [R4,#0x151]                                        ; +0x6e, 0x2f6396\nBL              _ZNK7cocos2d6CCRect7getMaxYEv; cocos2d::CCRect::getMaxY(void) ; +0x72, 0x2f639a\nVMOV            S16, R0                                                ; +0x76, 0x2f639e\nMOV             R0, R7; this                                           ; +0x7a, 0x2f63a2\nBL              _ZNK7cocos2d6CCRect7getMinYEv; cocos2d::CCRect::getMinY(void) ; +0x7c, 0x2f63a4\nVMOV            S15, R0                                                ; +0x80, 0x2f63a8\nLDR.W           R0, [R4,#0x180]                                        ; +0x84, 0x2f63ac\nVSUB.F32        S16, S16, S15                                          ; +0x88, 0x2f63b0\nCBZ             R0, loc_2F63C2                                         ; +0x8c, 0x2f63b4\nLDR             R3, [R0]                                               ; +0x8e, 0x2f63b6\nMOV             R1, R4                                                 ; +0x90, 0x2f63b8\nVMOV            R2, S16                                                ; +0x92, 0x2f63ba\nLDR             R3, [R3,#0xC]                                          ; +0x96, 0x2f63be\nBLX             R3                                                     ; +0x98, 0x2f63c0\nLDR             R2, [SP,#0x20+var_4]                                   ; +0x9a, 0x2f63c2\nLDR             R3, [R6]                                               ; +0x9c, 0x2f63c4\nCMP             R2, R3                                                 ; +0x9e, 0x2f63c6\nBEQ             loc_2F63CE                                             ; +0xa0, 0x2f63c8\nBLX             __stack_chk_fail                                       ; +0xa2, 0x2f63ca\nADD             SP, SP, #0x20 ; ' '                                    ; +0xa6, 0x2f63ce\nVPOP            {D8}                                                   ; +0xa8, 0x2f63d0\nPOP.W           {R4-R8,PC}                                             ; +0xac, 0x2f63d4", "xrefs": ["`non-virtual thunk to'CCTextInputNode::keyboardWillShow @ 0x2f63e0"], "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"}