{"type": "func", "start": 4298142096, "end": 4298142320, "name": "AppDelegate::applicationDidEnterBackground", "pseudocode": "// \n// AppDelegate::applicationDidEnterBackground from 0x100307190 to 0x100307270 (224 bytes)\n// \n// 1 xrefs:\n// > <???> @ 0x10092b488\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:08 +0000\n// \n\nvoid __fastcall AppDelegate::applicationDidEnterBackground(_BYTE *a1)\n{\n  __int64 v2; // x0\n  std::__thread_struct *v3; // x20\n  _QWORD *v4; // x0\n  int v5; // w0\n  __int64 v6; // x0\n  __int64 v7; // x0\n  __int64 v8; // x0\n  __int64 v9; // x0\n  std::thread v10; // [xsp+0h] [xbp-20h] BYREF\n  void *v11; // [xsp+8h] [xbp-18h] BYREF\n\n  v2 = FMODAudioEngine::sharedEngine();\n  sub_1001B56B0(v2);\n  sub_1001F9B74();\n  sub_1001FA180();\n  (*(void (__fastcall **)(_BYTE *, _QWORD))(*(_QWORD *)a1 + 64LL))(a1, 0);\n  v3 = (std::__thread_struct *)operator new(8u);\n  std::__thread_struct::__thread_struct(v3);\n  v4 = operator new(8u);\n  *v4 = v3;\n  v11 = v4;\n  v5 = pthread_create(&v10.__t_, nullptr, (void *(__cdecl *)(void *))sub_1003074F8, v4);\n  if ( v5 )\n  {\n    std::__throw_system_error(v5, \"thread constructor failed\");\n    __break(1u);\n  }\n  else\n  {\n    v11 = nullptr;\n    sub_1002DE574(&v11);\n    std::thread::detach(&v10);\n    std::thread::~thread(&v10);\n    v6 = cocos2d::CCDirector::sharedDirector();\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)v6 + 104LL))(v6);\n    v7 = cocos2d::CCDirector::sharedDirector();\n    cocos2d::CCDirector::pause(v7);\n    if ( a1[32] == 1 )\n    {\n      nullsub_72();\n      v9 = GameManager::sharedState(v8);\n      nullsub_178(v9);\n    }\n  }\n}", "assembly": "; \n; AppDelegate::applicationDidEnterBackground from 0x100307190 to 0x100307270 (224 bytes)\n; \n; 1 xrefs:\n; > <???> @ 0x10092b488\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:08 +0000\n; \nSUB             SP, SP, #0x30                                          ; +0x0, 0x100307190\nSTP             X20, X19, [SP,#0x20+var_10]                            ; +0x4, 0x100307194\nSTP             X29, X30, [SP,#0x20+var_s0]                            ; +0x8, 0x100307198\nADD             X29, SP, #0x20                                         ; +0xc, 0x10030719c\nMOV             X19, X0                                                ; +0x10, 0x1003071a0\nBL              FMODAudioEngine__sharedEngine                          ; +0x14, 0x1003071a4\nBL              sub_1001B56B0                                          ; +0x18, 0x1003071a8\nBL              sub_1001F9B74                                          ; +0x1c, 0x1003071ac\nBL              sub_1001FA180                                          ; +0x20, 0x1003071b0\nLDR             X8, [X19]                                              ; +0x24, 0x1003071b4\nLDR             X8, [X8,#0x40]                                         ; +0x28, 0x1003071b8\nMOV             X0, X19                                                ; +0x2c, 0x1003071bc\nMOV             W1, #0                                                 ; +0x30, 0x1003071c0\nBLR             X8                                                     ; +0x34, 0x1003071c4\nMOV             W0, #8; __sz                                           ; +0x38, 0x1003071c8\nBL              __Znwm; operator new(ulong)                            ; +0x3c, 0x1003071cc\nMOV             X20, X0                                                ; +0x40, 0x1003071d0\nBL              __ZNSt3__115__thread_structC1Ev; std::__thread_struct::__thread_struct(void) ; +0x44, 0x1003071d4\nMOV             W0, #8; __sz                                           ; +0x48, 0x1003071d8\nBL              __Znwm; operator new(ulong)                            ; +0x4c, 0x1003071dc\nMOV             X3, X0; void *                                         ; +0x50, 0x1003071e0\nSTR             X20, [X0]                                              ; +0x54, 0x1003071e4\nSTR             X0, [SP,#0x20+var_18]                                  ; +0x58, 0x1003071e8\nADRL            X2, sub_1003074F8; void *(__cdecl *)(void *)           ; +0x5c, 0x1003071ec\nMOV             X0, SP; pthread_t *                                    ; +0x64, 0x1003071f4\nMOV             X1, #0; pthread_attr_t *                               ; +0x68, 0x1003071f8\nBL              _pthread_create                                        ; +0x6c, 0x1003071fc\nCBNZ            W0, loc_100307260                                      ; +0x70, 0x100307200\nSTR             XZR, [SP,#0x20+var_18]                                 ; +0x74, 0x100307204\nADD             X0, SP, #0x20+var_18                                   ; +0x78, 0x100307208\nBL              sub_1002DE574                                          ; +0x7c, 0x10030720c\nMOV             X0, SP; this                                           ; +0x80, 0x100307210\nBL              __ZNSt3__16thread6detachEv; std::thread::detach(void)  ; +0x84, 0x100307214\nMOV             X0, SP; this                                           ; +0x88, 0x100307218\nBL              __ZNSt3__16threadD1Ev; std::thread::~thread()          ; +0x8c, 0x10030721c\nBL              cocos2d__CCDirector__sharedDirector                    ; +0x90, 0x100307220\nLDR             X8, [X0]                                               ; +0x94, 0x100307224\nLDR             X8, [X8,#0x68]                                         ; +0x98, 0x100307228\nBLR             X8                                                     ; +0x9c, 0x10030722c\nBL              cocos2d__CCDirector__sharedDirector                    ; +0xa0, 0x100307230\nBL              cocos2d__CCDirector__pause                             ; +0xa4, 0x100307234\nLDRB            W8, [X19,#0x20]                                        ; +0xa8, 0x100307238\nCMP             W8, #1                                                 ; +0xac, 0x10030723c\nB.NE            loc_100307250                                          ; +0xb0, 0x100307240\nBL              nullsub_72                                             ; +0xb4, 0x100307244\nBL              GameManager__sharedState                               ; +0xb8, 0x100307248\nBL              nullsub_178                                            ; +0xbc, 0x10030724c\nLDP             X29, X30, [SP,#0x20+var_s0]                            ; +0xc0, 0x100307250\nLDP             X20, X19, [SP,#0x20+var_10]                            ; +0xc4, 0x100307254\nADD             SP, SP, #0x30 ; '0'                                    ; +0xc8, 0x100307258\nRET                                                                    ; +0xcc, 0x10030725c\nADRL            X1, aThreadConstruc; \"thread constructor failed\"       ; +0xd0, 0x100307260\nBL              __ZNSt3__120__throw_system_errorEiPKc; std::__throw_system_error(int,char const*) ; +0xd8, 0x100307268\nBRK             #1                                                     ; +0xdc, 0x10030726c", "xrefs": ["<???> @ 0x10092b488"], "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"}