{"type": "func", "start": 5369561472, "end": 5369561710, "name": "DailyLevelPage::createNodeIfLoaded", "pseudocode": "// \n// DailyLevelPage::createNodeIfLoaded from 0x1400d0180 to 0x1400d026e (238 bytes)\n// \n// 3 xrefs:\n// > DailyLevelPage::downloadAndCreateNode @ 0x1400d0130\n// > DailyLevelPage::skipDailyLevel @ 0x1400d1f8a\n// > <???> @ 0x1406c8568\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// Hidden C++ exception states: #wind=3\nvoid DailyLevelPage::createNodeIfLoaded(DailyLevelPage *a1)\n{\n  GameLevelManager *v2; // rcx\n  GJTimedLevelType m_type; // edx\n  int m_weeklyID; // eax\n  __int32 v5; // edx\n  int m_eventID; // edx\n  GJGameLevel *SavedDailyLevel; // rax\n  _BOOL8 v8; // rdx\n  void *v9; // [rsp+40h] [rbp+8h]\n\n  a1->m_downloadStarted = 0;\n  v2 = (GameLevelManager *)qword_1406C2EC0;\n  if ( !qword_1406C2EC0 )\n  {\n    v9 = operator new(0x3D0u);\n    qword_1406C2EC0 = sub_140141280(v9);\n    (*(void (__fastcall **)(__int64))(*(_QWORD *)qword_1406C2EC0 + 72LL))(qword_1406C2EC0);\n    v2 = (GameLevelManager *)qword_1406C2EC0;\n  }\n  m_type = a1->m_type;\n  if ( m_type )\n  {\n    if ( m_type == 1 )\n    {\n      m_weeklyID = v2->m_weeklyID;\n    }\n    else\n    {\n      if ( m_type != Event )\n        return;\n      m_weeklyID = v2->m_eventID;\n    }\n  }\n  else\n  {\n    m_weeklyID = v2->m_dailyID;\n  }\n  if ( m_weeklyID > 0 )\n  {\n    if ( m_type )\n    {\n      v5 = m_type - 1;\n      if ( v5 )\n      {\n        if ( v5 == 1 )\n          m_eventID = v2->m_eventID;\n        else\n          m_eventID = 0;\n      }\n      else\n      {\n        m_eventID = v2->m_weeklyID;\n      }\n    }\n    else\n    {\n      m_eventID = v2->m_dailyID;\n    }\n    SavedDailyLevel = GameLevelManager::getSavedDailyLevel(v2, m_eventID);\n    if ( SavedDailyLevel )\n    {\n      DailyLevelPage::createDailyNode(a1, SavedDailyLevel, 0, 0.0, 1);\n    }\n    else\n    {\n      LOBYTE(v8) = 1;\n      a1->m_nodeCircle->setVisible(a1->m_nodeCircle, v8);\n    }\n  }\n}", "assembly": "; \n; DailyLevelPage::createNodeIfLoaded from 0x1400d0180 to 0x1400d026e (238 bytes)\n; \n; 3 xrefs:\n; > DailyLevelPage::downloadAndCreateNode @ 0x1400d0130\n; > DailyLevelPage::skipDailyLevel @ 0x1400d1f8a\n; > <???> @ 0x1406c8568\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    rbx                                                            ; +0x0, 0x1400d0180\nsub     rsp, 30h                                                       ; +0x2, 0x1400d0182\nmov     rbx, rcx                                                       ; +0x6, 0x1400d0186\nmov     byte ptr [rcx+2B8h], 0                                         ; +0x9, 0x1400d0189\nmov     rcx, cs:qword_1406C2EC0                                        ; +0x10, 0x1400d0190\ntest    rcx, rcx                                                       ; +0x17, 0x1400d0197\njnz     short loc_1400D01CB                                            ; +0x1a, 0x1400d019a\nmov     ecx, 3D0h; Size                                                ; +0x1c, 0x1400d019c\ncall    ??2@YAPEAX_K@Z; operator new(unsigned __int64)                 ; +0x21, 0x1400d01a1\nmov     [rsp+38h+arg_0], rax                                           ; +0x26, 0x1400d01a6\nmov     rcx, rax                                                       ; +0x2b, 0x1400d01ab\ncall    sub_140141280                                                  ; +0x2e, 0x1400d01ae\nnop                                                                    ; +0x33, 0x1400d01b3\nmov     cs:qword_1406C2EC0, rax                                        ; +0x34, 0x1400d01b4\nmov     rdx, [rax]                                                     ; +0x3b, 0x1400d01bb\nmov     rcx, rax                                                       ; +0x3e, 0x1400d01be\ncall    qword ptr [rdx+48h]                                            ; +0x41, 0x1400d01c1\nmov     rcx, cs:qword_1406C2EC0                                        ; +0x44, 0x1400d01c4\nmov     edx, [rbx+2BCh]                                                ; +0x4b, 0x1400d01cb\nmov     r8d, edx                                                       ; +0x51, 0x1400d01d1\ntest    edx, edx                                                       ; +0x54, 0x1400d01d4\njz      short loc_1400D01F8                                            ; +0x56, 0x1400d01d6\nsub     r8d, 1                                                         ; +0x58, 0x1400d01d8\njz      short loc_1400D01F0                                            ; +0x5c, 0x1400d01dc\ncmp     r8d, 1                                                         ; +0x5e, 0x1400d01de\njnz     loc_1400D0268                                                  ; +0x62, 0x1400d01e2\nmov     eax, [rcx+1DCh]                                                ; +0x68, 0x1400d01e8\njmp     short loc_1400D01FE                                            ; +0x6e, 0x1400d01ee\nmov     eax, [rcx+1D0h]                                                ; +0x70, 0x1400d01f0\njmp     short loc_1400D01FE                                            ; +0x76, 0x1400d01f6\nmov     eax, [rcx+1C4h]                                                ; +0x78, 0x1400d01f8\ntest    eax, eax                                                       ; +0x7e, 0x1400d01fe\njle     short loc_1400D0268                                            ; +0x80, 0x1400d0200\ntest    edx, edx                                                       ; +0x82, 0x1400d0202\njz      short loc_1400D0224                                            ; +0x84, 0x1400d0204\nsub     edx, 1                                                         ; +0x86, 0x1400d0206\njz      short loc_1400D021C                                            ; +0x89, 0x1400d0209\ncmp     edx, 1                                                         ; +0x8b, 0x1400d020b\njz      short loc_1400D0214                                            ; +0x8e, 0x1400d020e\nxor     edx, edx                                                       ; +0x90, 0x1400d0210\njmp     short loc_1400D022A                                            ; +0x92, 0x1400d0212\nmov     edx, [rcx+1DCh]                                                ; +0x94, 0x1400d0214\njmp     short loc_1400D022A                                            ; +0x9a, 0x1400d021a\nmov     edx, [rcx+1D0h]                                                ; +0x9c, 0x1400d021c\njmp     short loc_1400D022A                                            ; +0xa2, 0x1400d0222\nmov     edx, [rcx+1C4h]                                                ; +0xa4, 0x1400d0224\ncall    GameLevelManager__getSavedDailyLevel                           ; +0xaa, 0x1400d022a\ntest    rax, rax                                                       ; +0xaf, 0x1400d022f\njz      short loc_1400D0250                                            ; +0xb2, 0x1400d0232\nmov     [rsp+38h+var_18], 1                                            ; +0xb4, 0x1400d0234\nxorps   xmm3, xmm3                                                     ; +0xb9, 0x1400d0239\nxor     r8d, r8d                                                       ; +0xbc, 0x1400d023c\nmov     rdx, rax                                                       ; +0xbf, 0x1400d023f\nmov     rcx, rbx                                                       ; +0xc2, 0x1400d0242\ncall    DailyLevelPage__createDailyNode                                ; +0xc5, 0x1400d0245\nadd     rsp, 30h                                                       ; +0xca, 0x1400d024a\npop     rbx                                                            ; +0xce, 0x1400d024e\nretn                                                                   ; +0xcf, 0x1400d024f\nmov     rcx, [rbx+2A0h]                                                ; +0xd0, 0x1400d0250\nmov     rax, [rcx]                                                     ; +0xd7, 0x1400d0257\nmov     dl, 1                                                          ; +0xda, 0x1400d025a\nadd     rsp, 30h                                                       ; +0xdc, 0x1400d025c\npop     rbx                                                            ; +0xe0, 0x1400d0260\njmp     qword ptr [rax+140h]                                           ; +0xe1, 0x1400d0261\nadd     rsp, 30h                                                       ; +0xe8, 0x1400d0268\npop     rbx                                                            ; +0xec, 0x1400d026c\nretn                                                                   ; +0xed, 0x1400d026d", "xrefs": ["DailyLevelPage::downloadAndCreateNode @ 0x1400d0130", "DailyLevelPage::skipDailyLevel @ 0x1400d1f8a", "<???> @ 0x1406c8568"], "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"}