{"type": "func", "start": 3926888, "end": 3927064, "name": "GJGameLevel::init", "pseudocode": "// \n// GJGameLevel::init from 0x3beb68 to 0x3bec18 (176 bytes)\n// \n// 0 xrefs:\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\nbool GJGameLevel::init(GJGameLevel *a1)\n{\n  int v2; // r3\n  cocos2d::CCDictionary *v3; // r0\n  cocos2d::CCDictionary *v4; // r5\n  cocos2d::CCDictionary *m_lastBuildSave; // r0\n\n  sub_7753D4((int)&a1->m_levelName, (char *)&unk_939830);\n  sub_7753D4((int)&a1->m_levelDesc, (char *)&unk_939830);\n  sub_7753D4((int)&a1->m_levelString, (char *)&unk_939830);\n  sub_7753D4((int)&a1->m_personalBests, (char *)&unk_939830);\n  a1->m_levelVersion = 1;\n  a1->m_levelType = 0;\n  v2 = dword_AC5F54;\n  a1->m_M_ID = dword_AC5F54;\n  dword_AC5F54 = v2 + 1;\n  GJGameLevel::setAttempts(a1, 0);\n  GJGameLevel::setJumps(a1, 0);\n  GJGameLevel::setClicks(a1, 0);\n  GJGameLevel::setAttemptTime(a1, 0);\n  a1->m_chk = 0;\n  a1->m_coins = 0;\n  GJGameLevel::setStars(a1, 0);\n  GJGameLevel::setDemon(a1, 0);\n  a1->m_dontSave = 0;\n  a1->m_levelNotDownloaded = 0;\n  v3 = cocos2d::CCDictionary::create();\n  v4 = v3;\n  if ( a1->m_lastBuildSave != v3 )\n  {\n    if ( v3 )\n      cocos2d::CCObject::retain(v3);\n    m_lastBuildSave = a1->m_lastBuildSave;\n    if ( m_lastBuildSave )\n      cocos2d::CCObject::release(m_lastBuildSave);\n    a1->m_lastBuildSave = v4;\n  }\n  return 1;\n}", "assembly": "; \n; GJGameLevel::init from 0x3beb68 to 0x3bec18 (176 bytes)\n; \n; 0 xrefs:\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            {R3-R5,LR}                                             ; +0x0, 0x3beb68\nMOV             R4, R0                                                 ; +0x2, 0x3beb6a\nLDR             R5, =(unk_939830 - 0x3BEB76)                           ; +0x4, 0x3beb6c\nADD.W           R0, R0, #0x118; int                                    ; +0x6, 0x3beb6e\nADD             R5, PC; unk_939830                                     ; +0xa, 0x3beb72\nMOV             R1, R5; char *                                         ; +0xc, 0x3beb74\nBL              sub_7753D4                                             ; +0xe, 0x3beb76\nMOV             R1, R5; char *                                         ; +0x12, 0x3beb7a\nADD.W           R0, R4, #0x11C; int                                    ; +0x14, 0x3beb7c\nBL              sub_7753D4                                             ; +0x18, 0x3beb80\nMOV             R1, R5; char *                                         ; +0x1c, 0x3beb84\nADD.W           R0, R4, #0x120; int                                    ; +0x1e, 0x3beb86\nBL              sub_7753D4                                             ; +0x22, 0x3beb8a\nMOV             R1, R5; char *                                         ; +0x26, 0x3beb8e\nADD.W           R0, R4, #0x30C; int                                    ; +0x28, 0x3beb90\nMOVS            R5, #0                                                 ; +0x2c, 0x3beb94\nBL              sub_7753D4                                             ; +0x2e, 0x3beb96\nLDR             R2, =(dword_AC5F4C - 0x3BEBA6)                         ; +0x32, 0x3beb9a\nMOVS            R3, #1                                                 ; +0x34, 0x3beb9c\nSTR.W           R3, [R4,#0x1AC]                                        ; +0x36, 0x3beb9e\nADD             R2, PC; dword_AC5F4C                                   ; +0x3a, 0x3beba2\nMOV             R1, R5; int                                            ; +0x3c, 0x3beba4\nSTR.W           R5, [R4,#0x2F8]                                        ; +0x3e, 0x3beba6\nMOV             R0, R4; this                                           ; +0x42, 0x3bebaa\nLDR             R3, [R2,#(dword_AC5F54 - 0xAC5F4C)]                    ; +0x44, 0x3bebac\nSTR.W           R3, [R4,#0x2FC]                                        ; +0x46, 0x3bebae\nADDS            R3, #1                                                 ; +0x4a, 0x3bebb2\nSTR             R3, [R2,#(dword_AC5F54 - 0xAC5F4C)]                    ; +0x4c, 0x3bebb4\nBL              _ZN11GJGameLevel11setAttemptsEi; GJGameLevel::setAttempts(int) ; +0x4e, 0x3bebb6\nMOV             R1, R5; int                                            ; +0x52, 0x3bebba\nMOV             R0, R4; this                                           ; +0x54, 0x3bebbc\nBL              _ZN11GJGameLevel8setJumpsEi; GJGameLevel::setJumps(int) ; +0x56, 0x3bebbe\nMOV             R1, R5; int                                            ; +0x5a, 0x3bebc2\nMOV             R0, R4; this                                           ; +0x5c, 0x3bebc4\nBL              _ZN11GJGameLevel9setClicksEi; GJGameLevel::setClicks(int) ; +0x5e, 0x3bebc6\nMOV             R1, R5; int                                            ; +0x62, 0x3bebca\nMOV             R0, R4; this                                           ; +0x64, 0x3bebcc\nBL              _ZN11GJGameLevel14setAttemptTimeEi; GJGameLevel::setAttemptTime(int) ; +0x66, 0x3bebce\nMOV             R1, R5; int                                            ; +0x6a, 0x3bebd2\nSTR.W           R5, [R4,#0x1E4]                                        ; +0x6c, 0x3bebd4\nMOV             R0, R4; this                                           ; +0x70, 0x3bebd8\nSTR.W           R5, [R4,#0x25C]                                        ; +0x72, 0x3bebda\nBL              _ZN11GJGameLevel8setStarsEi; GJGameLevel::setStars(int) ; +0x76, 0x3bebde\nMOV             R1, R5; int                                            ; +0x7a, 0x3bebe2\nMOV             R0, R4; this                                           ; +0x7c, 0x3bebe4\nBL              _ZN11GJGameLevel8setDemonEi; GJGameLevel::setDemon(int) ; +0x7e, 0x3bebe6\nSTRB.W          R5, [R4,#0x2D4]                                        ; +0x82, 0x3bebea\nSTRB.W          R5, [R4,#0x2D5]                                        ; +0x86, 0x3bebee\nBL              _ZN7cocos2d12CCDictionary6createEv; cocos2d::CCDictionary::create(void) ; +0x8a, 0x3bebf2\nLDR.W           R3, [R4,#0x108]                                        ; +0x8e, 0x3bebf6\nCMP             R3, R0                                                 ; +0x92, 0x3bebfa\nMOV             R5, R0                                                 ; +0x94, 0x3bebfc\nBEQ             loc_3BEC14                                             ; +0x96, 0x3bebfe\nCBZ             R0, loc_3BEC06                                         ; +0x98, 0x3bec00\nBL              _ZN7cocos2d8CCObject6retainEv; cocos2d::CCObject::retain(void) ; +0x9a, 0x3bec02\nLDR.W           R0, [R4,#0x108]; this                                  ; +0x9e, 0x3bec06\nCBZ             R0, loc_3BEC10                                         ; +0xa2, 0x3bec0a\nBL              _ZN7cocos2d8CCObject7releaseEv; cocos2d::CCObject::release(void) ; +0xa4, 0x3bec0c\nSTR.W           R5, [R4,#0x108]                                        ; +0xa8, 0x3bec10\nMOVS            R0, #1                                                 ; +0xac, 0x3bec14\nPOP             {R3-R5,PC}                                             ; +0xae, 0x3bec16", "xrefs": [], "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"}