{"type": "func", "start": 4298004344, "end": 4298004448, "name": "GJDifficultySprite::init", "pseudocode": "// \n// GJDifficultySprite::init from 0x1002e5778 to 0x1002e57e0 (104 bytes)\n// \n// 1 xrefs:\n// > GJDifficultySprite::create @ 0x1002e5728\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\n// local variable allocation has failed, the output may be wrong!\nbool __fastcall GJDifficultySprite::init(GJDifficultySprite *a1, int a2, GJDifficultyName a3)\n{\n  void **v4; // x1\n  bool v5; // w19\n  void *__p[2]; // [xsp+8h] [xbp-28h] BYREF\n  char v8; // [xsp+1Fh] [xbp-11h]\n\n  GJDifficultySprite::getDifficultyFrame(__p, *(_QWORD *)&a2, *(_QWORD *)&a3);\n  if ( v8 >= 0 )\n    v4 = __p;\n  else\n    v4 = (void **)__p[0];\n  v5 = cocos2d::CCSprite::initWithSpriteFrameName(a1, (const char *)v4);\n  if ( v8 < 0 )\n    operator delete(__p[0]);\n  return v5;\n}", "assembly": "; \n; GJDifficultySprite::init from 0x1002e5778 to 0x1002e57e0 (104 bytes)\n; \n; 1 xrefs:\n; > GJDifficultySprite::create @ 0x1002e5728\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\nSUB             SP, SP, #0x40                                          ; +0x0, 0x1002e5778\nSTP             X20, X19, [SP,#0x30+var_10]                            ; +0x4, 0x1002e577c\nSTP             X29, X30, [SP,#0x30+var_s0]                            ; +0x8, 0x1002e5780\nADD             X29, SP, #0x30                                         ; +0xc, 0x1002e5784\nMOV             X19, X0                                                ; +0x10, 0x1002e5788\nADD             X20, SP, #0x30+__p                                     ; +0x14, 0x1002e578c\nADD             X8, SP, #0x30+__p                                      ; +0x18, 0x1002e5790\nMOV             X0, X1                                                 ; +0x1c, 0x1002e5794\nMOV             X1, X2                                                 ; +0x20, 0x1002e5798\nBL              GJDifficultySprite__getDifficultyFrame                 ; +0x24, 0x1002e579c\nLDRSB           W8, [SP,#0x30+var_11]                                  ; +0x28, 0x1002e57a0\nLDR             X9, [SP,#0x30+__p]                                     ; +0x2c, 0x1002e57a4\nCMP             W8, #0                                                 ; +0x30, 0x1002e57a8\nCSEL            X1, X9, X20, LT                                        ; +0x34, 0x1002e57ac\nMOV             X0, X19                                                ; +0x38, 0x1002e57b0\nBL              cocos2d__CCSprite__initWithSpriteFrameName             ; +0x3c, 0x1002e57b4\nMOV             X19, X0                                                ; +0x40, 0x1002e57b8\nLDRSB           W8, [SP,#0x30+var_11]                                  ; +0x44, 0x1002e57bc\nTBZ             W8, #0x1F, loc_1002E57CC                               ; +0x48, 0x1002e57c0\nLDR             X0, [SP,#0x30+__p]; __p                                ; +0x4c, 0x1002e57c4\nBL              __ZdlPv; operator delete(void *)                       ; +0x50, 0x1002e57c8\nMOV             X0, X19                                                ; +0x54, 0x1002e57cc\nLDP             X29, X30, [SP,#0x30+var_s0]                            ; +0x58, 0x1002e57d0\nLDP             X20, X19, [SP,#0x30+var_10]                            ; +0x5c, 0x1002e57d4\nADD             SP, SP, #0x40 ; '@'                                    ; +0x60, 0x1002e57d8\nRET                                                                    ; +0x64, 0x1002e57dc", "xrefs": ["GJDifficultySprite::create @ 0x1002e5728"], "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"}