; ; GameLevelManager::onUpdateUserScoreCompleted from 0x140157650 to 0x140157971 (801 bytes) ; ; 2 xrefs: ; > GameLevelManager::handleIt @ 0x14014334b ; > @ 0x1406ca968 ; ; This function is hookable on this platform! ; ; Using BromaIDA 8.0.0 @ https:;github.com/Stazzical/BromaIDA ; Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https:;github.com/geode-sdk/bindings ; mov [rsp-38h+arg_18], rbx ; +0x0, 0x140157650 push rbp ; +0x5, 0x140157655 push rsi ; +0x6, 0x140157656 push rdi ; +0x7, 0x140157657 push r12 ; +0x8, 0x140157658 push r13 ; +0xa, 0x14015765a push r14 ; +0xc, 0x14015765c push r15 ; +0xe, 0x14015765e mov rbp, rsp ; +0x10, 0x140157660 sub rsp, 80h ; +0x13, 0x140157663 mov rax, cs:__security_cookie ; +0x1a, 0x14015766a xor rax, rsp ; +0x21, 0x140157671 mov [rbp+var_8], rax ; +0x24, 0x140157674 mov r13, r8 ; +0x28, 0x140157678 mov rbx, rdx ; +0x2b, 0x14015767b mov r15, rcx ; +0x2e, 0x14015767e mov [rbp+var_58], rdx ; +0x31, 0x140157681 mov [rbp+var_50], r8 ; +0x35, 0x140157685 xorps xmm0, xmm0 ; +0x39, 0x140157689 movups xmmword ptr [rbp+Block], xmm0 ; +0x3c, 0x14015768c mov [rbp+var_18], 0Ah ; +0x40, 0x140157690 mov edi, 0Fh ; +0x48, 0x140157698 mov [rbp+var_10], rdi ; +0x4d, 0x14015769d movsd xmm0, qword ptr cs:aUserScore ; +0x51, 0x1401576a1 movsd [rbp+Block], xmm0 ; +0x59, 0x1401576a9 movzx eax, word ptr cs:aUserScore+8 ; +0x5e, 0x1401576ae mov word ptr [rbp+Block+8], ax ; +0x65, 0x1401576b5 mov byte ptr [rbp+Block+0Ah], 0 ; +0x69, 0x1401576b9 lea rdx, [rbp+Block] ; +0x6d, 0x1401576bd mov rcx, [rcx+248h] ; +0x71, 0x1401576c1 call cs:?removeObjectForKey@CCDictionary@cocos2d@@QEAAXAEBV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z ; +0x78, 0x1401576c8 nop ; +0x7e, 0x1401576ce mov rdx, [rbp+var_10] ; +0x7f, 0x1401576cf cmp rdx, rdi ; +0x83, 0x1401576d3 jbe short loc_14015770C ; +0x86, 0x1401576d6 inc rdx ; +0x88, 0x1401576d8 mov rcx, [rbp+Block]; Block ; +0x8b, 0x1401576db mov rax, rcx ; +0x8f, 0x1401576df cmp rdx, 1000h ; +0x92, 0x1401576e2 jb short loc_140157707 ; +0x99, 0x1401576e9 add rdx, 27h ; ''' ; +0x9b, 0x1401576eb mov rcx, [rcx-8] ; +0x9f, 0x1401576ef sub rax, rcx ; +0xa3, 0x1401576f3 add rax, 0FFFFFFFFFFFFFFF8h ; +0xa6, 0x1401576f6 cmp rax, 1Fh ; +0xaa, 0x1401576fa jbe short loc_140157707 ; +0xae, 0x1401576fe call cs:_invalid_parameter_noinfo_noreturn ; +0xb0, 0x140157700 db 0CCh ; +0xb6, 0x140157706 call j_j_free ; +0xb7, 0x140157707 mov [rbp+var_18], 0 ; +0xbc, 0x14015770c mov [rbp+var_10], rdi ; +0xc4, 0x140157714 mov byte ptr [rbp+Block], 0 ; +0xc8, 0x140157718 xorps xmm0, xmm0 ; +0xcc, 0x14015771c movups [rbp+Buf2], xmm0 ; +0xcf, 0x14015771f mov r9d, 2 ; +0xd3, 0x140157723 mov [rbp+var_38], r9 ; +0xd9, 0x140157729 mov [rbp+var_30], rdi ; +0xdd, 0x14015772d movzx eax, cs:word_1405334A0 ; +0xe1, 0x140157731 mov word ptr [rbp+Buf2], ax ; +0xe8, 0x140157738 mov byte ptr [rbp+Buf2+2], 0 ; +0xec, 0x14015773c lea rdx, [rbp+Buf2]; Buf2 ; +0xf0, 0x140157740 mov rcx, rbx ; +0xf4, 0x140157744 cmp qword ptr [rbx+18h], 0Fh ; +0xf7, 0x140157747 jbe short loc_140157751 ; +0xfc, 0x14015774c mov rcx, [rbx]; Buf1 ; +0xfe, 0x14015774e mov r14, [rbx+10h] ; +0x101, 0x140157751 mov r8, r14 ; +0x105, 0x140157755 cmp r9, r14 ; +0x108, 0x140157758 cmovb r8, r9; Size ; +0x10b, 0x14015775b call memcmp ; +0x10f, 0x14015775f mov edi, eax ; +0x114, 0x140157764 test eax, eax ; +0x116, 0x140157766 jnz short loc_14015777F ; +0x118, 0x140157768 cmp r14, 2 ; +0x11a, 0x14015776a jnb short loc_140157775 ; +0x11e, 0x14015776e lea edi, [rax-1] ; +0x120, 0x140157770 jmp short loc_14015777F ; +0x123, 0x140157773 xor edi, edi ; +0x125, 0x140157775 cmp r14, 2 ; +0x127, 0x140157777 setnbe dil ; +0x12b, 0x14015777b mov r14d, 0Fh ; +0x12f, 0x14015777f test edi, edi ; +0x135, 0x140157785 jnz short loc_1401577A4 ; +0x137, 0x140157787 mov rcx, [r15+308h] ; +0x139, 0x140157789 test rcx, rcx ; +0x140, 0x140157790 jz loc_140157939 ; +0x143, 0x140157793 mov rax, [rcx] ; +0x149, 0x140157799 call qword ptr [rax+8] ; +0x14c, 0x14015779c jmp loc_140157939 ; +0x14f, 0x14015779f xorps xmm0, xmm0 ; +0x154, 0x1401577a4 movups [rbp+Buf2], xmm0 ; +0x157, 0x1401577a7 mov r12d, 2 ; +0x15b, 0x1401577ab mov [rbp+var_38], r12 ; +0x161, 0x1401577b1 mov [rbp+var_30], r14 ; +0x165, 0x1401577b5 movzx eax, cs:word_1405593EC ; +0x169, 0x1401577b9 mov word ptr [rbp+Buf2], ax ; +0x170, 0x1401577c0 mov byte ptr [rbp+Buf2+2], 0 ; +0x174, 0x1401577c4 lea rdx, [rbp+Buf2]; Buf2 ; +0x178, 0x1401577c8 mov rcx, rbx ; +0x17c, 0x1401577cc cmp [rbx+18h], r14 ; +0x17f, 0x1401577cf jbe short loc_1401577D8 ; +0x183, 0x1401577d3 mov rcx, [rbx]; Buf1 ; +0x185, 0x1401577d5 mov r14, [rbx+10h] ; +0x188, 0x1401577d8 mov r8, r14 ; +0x18c, 0x1401577dc cmp r12, r14 ; +0x18f, 0x1401577df cmovb r8, r12; Size ; +0x192, 0x1401577e2 call memcmp ; +0x196, 0x1401577e6 mov edi, eax ; +0x19b, 0x1401577eb test eax, eax ; +0x19d, 0x1401577ed jnz short loc_140157804 ; +0x19f, 0x1401577ef cmp r14, r12 ; +0x1a1, 0x1401577f1 jnb short loc_1401577FB ; +0x1a4, 0x1401577f4 lea edi, [rax-1] ; +0x1a6, 0x1401577f6 jmp short loc_140157804 ; +0x1a9, 0x1401577f9 xor edi, edi ; +0x1ab, 0x1401577fb cmp r14, r12 ; +0x1ad, 0x1401577fd setnbe dil ; +0x1b0, 0x140157800 mov edx, 0Fh ; +0x1b4, 0x140157804 test edi, edi ; +0x1b9, 0x140157809 jnz short loc_140157851 ; +0x1bb, 0x14015780b mov rcx, cs:qword_1406C2EC0 ; +0x1bd, 0x14015780d test rcx, rcx ; +0x1c4, 0x140157814 jnz short loc_140157847 ; +0x1c7, 0x140157817 mov ecx, 3D0h; Size ; +0x1c9, 0x140157819 call ??2@YAPEAX_K@Z ; +0x1ce, 0x14015781e mov [rbp+var_60], rax ; +0x1d3, 0x140157823 mov rcx, rax ; +0x1d7, 0x140157827 call sub_140141280 ; +0x1da, 0x14015782a nop ; +0x1df, 0x14015782f mov cs:qword_1406C2EC0, rax ; +0x1e0, 0x140157830 mov rdx, [rax] ; +0x1e7, 0x140157837 mov rcx, rax ; +0x1ea, 0x14015783a call qword ptr [rdx+48h] ; +0x1ed, 0x14015783d mov rcx, cs:qword_1406C2EC0 ; +0x1f0, 0x140157840 call GameLevelManager__submitUserInfo ; +0x1f7, 0x140157847 jmp loc_1401578D4 ; +0x1fc, 0x14015784c mov rcx, rbx ; +0x201, 0x140157851 cmp [rbx+18h], rdx ; +0x204, 0x140157854 jbe short loc_14015785D ; +0x208, 0x140157858 mov rcx, [rbx]; String ; +0x20a, 0x14015785a call cs:atoi ; +0x20d, 0x14015785d mov esi, eax ; +0x213, 0x140157863 mov rdi, cs:qword_1406C2ED8 ; +0x215, 0x140157865 test rdi, rdi ; +0x21c, 0x14015786c jnz short loc_14015789F ; +0x21f, 0x14015786f mov ecx, 668h; Size ; +0x221, 0x140157871 call ??2@YAPEAX_K@Z ; +0x226, 0x140157876 mov [rbp+var_60], rax ; +0x22b, 0x14015787b mov rcx, rax ; +0x22f, 0x14015787f call sub_14017AB00 ; +0x232, 0x140157882 nop ; +0x237, 0x140157887 mov cs:qword_1406C2ED8, rax ; +0x238, 0x140157888 mov rdx, [rax] ; +0x23f, 0x14015788f mov rcx, rax ; +0x242, 0x140157892 call qword ptr [rdx+48h] ; +0x245, 0x140157895 mov rdi, cs:qword_1406C2ED8 ; +0x248, 0x140157898 mov [rdi+294h], esi ; +0x24f, 0x14015789f call cs:rand ; +0x255, 0x1401578a5 movd xmm0, eax ; +0x25b, 0x1401578ab cvtdq2ps xmm0, xmm0 ; +0x25f, 0x1401578af divss xmm0, cs:dword_140623644 ; +0x262, 0x1401578b2 mulss xmm0, cs:dword_14062350C ; +0x26a, 0x1401578ba cvttss2si eax, xmm0 ; +0x272, 0x1401578c2 mov [rdi+290h], eax ; +0x276, 0x1401578c6 add eax, esi ; +0x27c, 0x1401578cc mov [rdi+28Ch], eax ; +0x27e, 0x1401578ce mov rax, cs:qword_1406C2ED8 ; +0x284, 0x1401578d4 test rax, rax ; +0x28b, 0x1401578db jnz short loc_14015790E ; +0x28e, 0x1401578de mov ecx, 668h; Size ; +0x290, 0x1401578e0 call ??2@YAPEAX_K@Z ; +0x295, 0x1401578e5 mov [rbp+var_60], rax ; +0x29a, 0x1401578ea mov rcx, rax ; +0x29e, 0x1401578ee call sub_14017AB00 ; +0x2a1, 0x1401578f1 nop ; +0x2a6, 0x1401578f6 mov cs:qword_1406C2ED8, rax ; +0x2a7, 0x1401578f7 mov rdx, [rax] ; +0x2ae, 0x1401578fe mov rcx, rax ; +0x2b1, 0x140157901 call qword ptr [rdx+48h] ; +0x2b4, 0x140157904 mov rax, cs:qword_1406C2ED8 ; +0x2b7, 0x140157907 mov byte ptr [rax+288h], 1 ; +0x2be, 0x14015790e mov rcx, [r15+308h] ; +0x2c5, 0x140157915 test rcx, rcx ; +0x2cc, 0x14015791c jz short loc_140157926 ; +0x2cf, 0x14015791f mov rax, [rcx] ; +0x2d1, 0x140157921 call qword ptr [rax] ; +0x2d4, 0x140157924 mov rcx, [r15+2E0h] ; +0x2d6, 0x140157926 test rcx, rcx ; +0x2dd, 0x14015792d jz short loc_140157939 ; +0x2e0, 0x140157930 mov rax, [rcx] ; +0x2e2, 0x140157932 call qword ptr [rax+10h] ; +0x2e5, 0x140157935 nop ; +0x2e8, 0x140157938 mov rcx, rbx ; +0x2e9, 0x140157939 call sub_14003A830 ; +0x2ec, 0x14015793c nop ; +0x2f1, 0x140157941 mov rcx, r13 ; +0x2f2, 0x140157942 call sub_14003A830 ; +0x2f5, 0x140157945 mov rcx, [rbp+var_8] ; +0x2fa, 0x14015794a xor rcx, rsp; StackCookie ; +0x2fe, 0x14015794e call __security_check_cookie ; +0x301, 0x140157951 mov rbx, [rsp+80h+arg_18] ; +0x306, 0x140157956 add rsp, 80h ; +0x30e, 0x14015795e pop r15 ; +0x315, 0x140157965 pop r14 ; +0x317, 0x140157967 pop r13 ; +0x319, 0x140157969 pop r12 ; +0x31b, 0x14015796b pop rdi ; +0x31d, 0x14015796d pop rsi ; +0x31e, 0x14015796e pop rbp ; +0x31f, 0x14015796f retn ; +0x320, 0x140157970