{"type": "func", "start": 4298135796, "end": 4298135992, "name": "MenuLayer::keyDown", "pseudocode": "// \n// MenuLayer::keyDown from 0x1003058f4 to 0x1003059b8 (196 bytes)\n// \n// 2 xrefs:\n// > sub_1003059B8 @ 0x1003059bc\n// > <???> @ 0x10092a878\n// \n// This function is hookable on this platform (idp: arm, 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 11:03:07 +0000\n// \n\n__int64 __fastcall MenuLayer::keyDown(__int64 a1, int a2)\n{\n  char *v4; // x20\n\n  if ( a2 <= 1006 )\n  {\n    if ( a2 != 13 && a2 != 32 )\n    {\n      if ( a2 == 1005 )\n        return MenuLayer::onCreator(a1);\n      return cocos2d::CCLayer::keyDown(a1, a2);\n    }\n    return MenuLayer::onPlay(a1);\n  }\n  if ( a2 == 1007 )\n    return MenuLayer::onGarage(a1);\n  if ( a2 != 1023 )\n  {\n    if ( a2 != 1009 )\n      return cocos2d::CCLayer::keyDown(a1, a2);\n    return MenuLayer::onPlay(a1);\n  }\n  v4 = OptionsLayer::create();\n  (*(void (__fastcall **)(__int64, char *, __int64))(*(_QWORD *)a1 + 464LL))(a1, v4, 100);\n  return (*(__int64 (__fastcall **)(char *, _QWORD))(*(_QWORD *)v4 + 1328LL))(v4, 0);\n}", "assembly": "; \n; MenuLayer::keyDown from 0x1003058f4 to 0x1003059b8 (196 bytes)\n; \n; 2 xrefs:\n; > sub_1003059B8 @ 0x1003059bc\n; > <???> @ 0x10092a878\n; \n; This function is hookable on this platform (idp: arm, 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 11:03:07 +0000\n; \nSTP             X20, X19, [SP,#-0x10+var_10]!                          ; +0x0, 0x1003058f4\nSTP             X29, X30, [SP,#0x10+var_s0]                            ; +0x4, 0x1003058f8\nADD             X29, SP, #0x10                                         ; +0x8, 0x1003058fc\nMOV             X19, X0                                                ; +0xc, 0x100305900\nCMP             W1, #0x3EE                                             ; +0x10, 0x100305904\nB.GT            loc_100305934                                          ; +0x14, 0x100305908\nCMP             W1, #0xD                                               ; +0x18, 0x10030590c\nB.EQ            loc_10030594C                                          ; +0x1c, 0x100305910\nCMP             W1, #0x20 ; ' '                                        ; +0x20, 0x100305914\nB.EQ            loc_10030594C                                          ; +0x24, 0x100305918\nCMP             W1, #0x3ED                                             ; +0x28, 0x10030591c\nB.NE            loc_10030596C                                          ; +0x2c, 0x100305920\nMOV             X0, X19                                                ; +0x30, 0x100305924\nLDP             X29, X30, [SP,#0x10+var_s0]                            ; +0x34, 0x100305928\nLDP             X20, X19, [SP+0x10+var_10],#0x20                       ; +0x38, 0x10030592c\nB               MenuLayer__onCreator                                   ; +0x3c, 0x100305930\nCMP             W1, #0x3EF                                             ; +0x40, 0x100305934\nB.EQ            loc_10030595C                                          ; +0x44, 0x100305938\nCMP             W1, #0x3FF                                             ; +0x48, 0x10030593c\nB.EQ            loc_10030597C                                          ; +0x4c, 0x100305940\nCMP             W1, #0x3F1                                             ; +0x50, 0x100305944\nB.NE            loc_10030596C                                          ; +0x54, 0x100305948\nMOV             X0, X19                                                ; +0x58, 0x10030594c\nLDP             X29, X30, [SP,#0x10+var_s0]                            ; +0x5c, 0x100305950\nLDP             X20, X19, [SP+0x10+var_10],#0x20                       ; +0x60, 0x100305954\nB               MenuLayer__onPlay                                      ; +0x64, 0x100305958\nMOV             X0, X19                                                ; +0x68, 0x10030595c\nLDP             X29, X30, [SP,#0x10+var_s0]                            ; +0x6c, 0x100305960\nLDP             X20, X19, [SP+0x10+var_10],#0x20                       ; +0x70, 0x100305964\nB               MenuLayer__onGarage                                    ; +0x74, 0x100305968\nMOV             X0, X19                                                ; +0x78, 0x10030596c\nLDP             X29, X30, [SP,#0x10+var_s0]                            ; +0x7c, 0x100305970\nLDP             X20, X19, [SP+0x10+var_10],#0x20                       ; +0x80, 0x100305974\nB               cocos2d__CCLayer__keyDown                              ; +0x84, 0x100305978\nBL              OptionsLayer__create                                   ; +0x88, 0x10030597c\nMOV             X20, X0                                                ; +0x8c, 0x100305980\nLDR             X8, [X19]                                              ; +0x90, 0x100305984\nLDR             X8, [X8,#0x1D0]                                        ; +0x94, 0x100305988\nMOV             X0, X19                                                ; +0x98, 0x10030598c\nMOV             X1, X20                                                ; +0x9c, 0x100305990\nMOV             W2, #0x64 ; 'd'                                        ; +0xa0, 0x100305994\nBLR             X8                                                     ; +0xa4, 0x100305998\nLDR             X8, [X20]                                              ; +0xa8, 0x10030599c\nLDR             X2, [X8,#0x530]                                        ; +0xac, 0x1003059a0\nMOV             X0, X20                                                ; +0xb0, 0x1003059a4\nMOV             W1, #0                                                 ; +0xb4, 0x1003059a8\nLDP             X29, X30, [SP,#0x10+var_s0]                            ; +0xb8, 0x1003059ac\nLDP             X20, X19, [SP+0x10+var_10],#0x20                       ; +0xbc, 0x1003059b0\nBR              X2                                                     ; +0xc0, 0x1003059b4", "xrefs": ["sub_1003059B8 @ 0x1003059bc", "<???> @ 0x10092a878"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "arm", "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"}