{"type": "func", "start": 4300401264, "end": 4300401569, "name": "GameLevelManager::verifyLevelState", "pseudocode": "// \n// GameLevelManager::verifyLevelState from 0x10052ea70 to 0x10052eba1 (305 bytes)\n// \n// 1 xrefs:\n// > GameLevelManager::onGetLevelSaveDataCompleted @ 0x100526800\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\nvoid __fastcall GameLevelManager::verifyLevelState(GameLevelManager *a1, GJGameLevel *a2)\n{\n  GameStatsManager *v2; // rax\n  GameStatsManager *v3; // rax\n  int v4; // eax\n  int v5; // eax\n  int v6; // eax\n\n  v2 = GameStatsManager::sharedState();\n  if ( GameStatsManager::hasCompletedLevel(v2, a2)\n    && a2->m_stars.random - a2->m_stars.seed >= 8\n    && a2->m_jumps.random - a2->m_jumps.seed <= 49\n    && a2->m_clicks.random - a2->m_clicks.seed <= 49 )\n  {\n    v3 = GameStatsManager::sharedState();\n    GameStatsManager::uncompleteLevel(v3, a2);\n    a2->m_normalPercent.value = 0;\n    v4 = (int)(float)((float)((float)rand() * 4.6566129e-10) * 1000.0);\n    a2->m_normalPercent.seed = v4;\n    a2->m_normalPercent.random = v4;\n    a2->m_orbCompletion.value = 0;\n    v5 = (int)(float)((float)((float)rand() * 4.6566129e-10) * 1000.0);\n    a2->m_orbCompletion.seed = v5;\n    a2->m_orbCompletion.random = v5;\n    a2->m_newNormalPercent2.value = 0;\n    v6 = (int)(float)((float)((float)rand() * 4.6566129e-10) * 1000.0);\n    a2->m_newNormalPercent2.seed = v6;\n    a2->m_newNormalPercent2.random = v6;\n    a2->m_bestTime = 0;\n    a2->m_bestPoints = 0;\n    a2->m_isCompletionLegitimate = 1;\n  }\n}", "assembly": "; \n; GameLevelManager::verifyLevelState from 0x10052ea70 to 0x10052eba1 (305 bytes)\n; \n; 1 xrefs:\n; > GameLevelManager::onGetLevelSaveDataCompleted @ 0x100526800\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    rbp                                                            ; +0x0, 0x10052ea70\nmov     rbp, rsp                                                       ; +0x1, 0x10052ea71\npush    rbx                                                            ; +0x4, 0x10052ea74\npush    rax                                                            ; +0x5, 0x10052ea75\nmov     rbx, rsi                                                       ; +0x6, 0x10052ea76\ncall    GameStatsManager__sharedState                                  ; +0x9, 0x10052ea79\nmov     rdi, rax                                                       ; +0xe, 0x10052ea7e\nmov     rsi, rbx                                                       ; +0x11, 0x10052ea81\ncall    GameStatsManager__hasCompletedLevel                            ; +0x14, 0x10052ea84\ntest    al, al                                                         ; +0x19, 0x10052ea89\njz      loc_10052EB9A                                                  ; +0x1b, 0x10052ea8b\nmov     eax, [rbx+340h]                                                ; +0x21, 0x10052ea91\nsub     eax, [rbx+344h]                                                ; +0x27, 0x10052ea97\ncmp     eax, 8                                                         ; +0x2d, 0x10052ea9d\njl      loc_10052EB9A                                                  ; +0x30, 0x10052eaa0\nmov     eax, [rbx+2B4h]                                                ; +0x36, 0x10052eaa6\nsub     eax, [rbx+2B8h]                                                ; +0x3c, 0x10052eaac\ncmp     eax, 31h ; '1'                                                 ; +0x42, 0x10052eab2\njg      loc_10052EB9A                                                  ; +0x45, 0x10052eab5\nmov     eax, [rbx+2C0h]                                                ; +0x4b, 0x10052eabb\nsub     eax, [rbx+2C4h]                                                ; +0x51, 0x10052eac1\ncmp     eax, 31h ; '1'                                                 ; +0x57, 0x10052eac7\njg      loc_10052EB9A                                                  ; +0x5a, 0x10052eaca\ncall    GameStatsManager__sharedState                                  ; +0x60, 0x10052ead0\nmov     rdi, rax                                                       ; +0x65, 0x10052ead5\nmov     rsi, rbx                                                       ; +0x68, 0x10052ead8\ncall    GameStatsManager__uncompleteLevel                              ; +0x6b, 0x10052eadb\nmov     dword ptr [rbx+2E0h], 0                                        ; +0x70, 0x10052eae0\ncall    _rand                                                          ; +0x7a, 0x10052eaea\ncvtsi2ss xmm0, eax                                                     ; +0x7f, 0x10052eaef\nmulss   xmm0, cs:dword_100815710                                       ; +0x83, 0x10052eaf3\nmulss   xmm0, cs:dword_1008152B8                                       ; +0x8b, 0x10052eafb\ncvttss2si eax, xmm0                                                    ; +0x93, 0x10052eb03\nmov     [rbx+2E4h], eax                                                ; +0x97, 0x10052eb07\nmov     [rbx+2E8h], eax                                                ; +0x9d, 0x10052eb0d\nmov     dword ptr [rbx+2F4h], 0                                        ; +0xa3, 0x10052eb13\ncall    _rand                                                          ; +0xad, 0x10052eb1d\nxorps   xmm0, xmm0                                                     ; +0xb2, 0x10052eb22\ncvtsi2ss xmm0, eax                                                     ; +0xb5, 0x10052eb25\nmulss   xmm0, cs:dword_100815710                                       ; +0xb9, 0x10052eb29\nmulss   xmm0, cs:dword_1008152B8                                       ; +0xc1, 0x10052eb31\ncvttss2si eax, xmm0                                                    ; +0xc9, 0x10052eb39\nmov     [rbx+2F0h], eax                                                ; +0xcd, 0x10052eb3d\nmov     [rbx+2ECh], eax                                                ; +0xd3, 0x10052eb43\nmov     dword ptr [rbx+300h], 0                                        ; +0xd9, 0x10052eb49\ncall    _rand                                                          ; +0xe3, 0x10052eb53\nxorps   xmm0, xmm0                                                     ; +0xe8, 0x10052eb58\ncvtsi2ss xmm0, eax                                                     ; +0xeb, 0x10052eb5b\nmulss   xmm0, cs:dword_100815710                                       ; +0xef, 0x10052eb5f\nmulss   xmm0, cs:dword_1008152B8                                       ; +0xf7, 0x10052eb67\ncvttss2si eax, xmm0                                                    ; +0xff, 0x10052eb6f\nmov     [rbx+2FCh], eax                                                ; +0x103, 0x10052eb73\nmov     [rbx+2F8h], eax                                                ; +0x109, 0x10052eb79\nmov     dword ptr [rbx+49Ch], 0                                        ; +0x10f, 0x10052eb7f\nmov     dword ptr [rbx+4C8h], 0                                        ; +0x119, 0x10052eb89\nmov     byte ptr [rbx+2DDh], 1                                         ; +0x123, 0x10052eb93\nadd     rsp, 8                                                         ; +0x12a, 0x10052eb9a\npop     rbx                                                            ; +0x12e, 0x10052eb9e\npop     rbp                                                            ; +0x12f, 0x10052eb9f\nretn                                                                   ; +0x130, 0x10052eba0", "xrefs": ["GameLevelManager::onGetLevelSaveDataCompleted @ 0x100526800"], "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"}