; ; GJShopLayer::onSelectItem from 0x1402abcb0 to 0x1402abebb (523 bytes) ; ; 2 xrefs: ; > GJShopLayer::init @ 0x1402ab27d ; > @ 0x1406d2240 ; ; 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+arg_10], rbx ; +0x0, 0x1402abcb0 push rbp ; +0x5, 0x1402abcb5 push rsi ; +0x6, 0x1402abcb6 push rdi ; +0x7, 0x1402abcb7 sub rsp, 50h ; +0x8, 0x1402abcb8 mov rax, cs:__security_cookie ; +0xc, 0x1402abcbc xor rax, rsp ; +0x13, 0x1402abcc3 mov [rsp+68h+var_20], rax ; +0x16, 0x1402abcc6 mov rsi, rcx ; +0x1b, 0x1402abccb xor edi, edi ; +0x1e, 0x1402abcce cmp [rcx+1B0h], dil ; +0x20, 0x1402abcd0 jnz loc_1402ABE9E ; +0x27, 0x1402abcd7 mov rax, [rdx] ; +0x2d, 0x1402abcdd mov rcx, rdx ; +0x30, 0x1402abce0 call qword ptr [rax+38h] ; +0x33, 0x1402abce3 movsxd rbx, eax ; +0x36, 0x1402abce6 mov rcx, cs:qword_1406C2EE8 ; +0x39, 0x1402abce9 test rcx, rcx ; +0x40, 0x1402abcf0 jnz short loc_1402ABD24 ; +0x43, 0x1402abcf3 mov ecx, 3E0h; Size ; +0x45, 0x1402abcf5 call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x4a, 0x1402abcfa mov [rsp+68h+var_48], rax ; +0x4f, 0x1402abcff mov rcx, rax ; +0x54, 0x1402abd04 call sub_1401D0AE0 ; +0x57, 0x1402abd07 nop ; +0x5c, 0x1402abd0c mov cs:qword_1406C2EE8, rax ; +0x5d, 0x1402abd0d mov rdx, [rax] ; +0x64, 0x1402abd14 mov rcx, rax ; +0x67, 0x1402abd17 call qword ptr [rdx+48h] ; +0x6a, 0x1402abd1a mov rcx, cs:qword_1406C2EE8 ; +0x6d, 0x1402abd1d mov edx, ebx ; +0x74, 0x1402abd24 call GameStatsManager__isStoreItemUnlocked ; +0x76, 0x1402abd26 test al, al ; +0x7b, 0x1402abd2b jnz loc_1402ABE9E ; +0x7d, 0x1402abd2d mov rcx, cs:qword_1406C2EE8 ; +0x83, 0x1402abd33 test rcx, rcx ; +0x8a, 0x1402abd3a jnz short loc_1402ABD6E ; +0x8d, 0x1402abd3d mov ecx, 3E0h; Size ; +0x8f, 0x1402abd3f call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x94, 0x1402abd44 mov [rsp+68h+var_48], rax ; +0x99, 0x1402abd49 mov rcx, rax ; +0x9e, 0x1402abd4e call sub_1401D0AE0 ; +0xa1, 0x1402abd51 nop ; +0xa6, 0x1402abd56 mov cs:qword_1406C2EE8, rax ; +0xa7, 0x1402abd57 mov rdx, [rax] ; +0xae, 0x1402abd5e mov rcx, rax ; +0xb1, 0x1402abd61 call qword ptr [rdx+48h] ; +0xb4, 0x1402abd64 mov rcx, cs:qword_1406C2EE8 ; +0xb7, 0x1402abd67 mov rdx, rbx ; +0xbe, 0x1402abd6e mov rcx, [rcx+158h] ; +0xc1, 0x1402abd71 call cs:?objectForKey@CCDictionary@cocos2d@@QEAAPEAVCCObject@2@_J@Z; cocos2d::CCDictionary::objectForKey(__int64) ; +0xc8, 0x1402abd78 mov rbx, rax ; +0xce, 0x1402abd7e lea rax, word_14055A524 ; +0xd1, 0x1402abd81 lea rdx, a14; "14" ; +0xd8, 0x1402abd88 cmp dword ptr [rbx+170h], 4 ; +0xdf, 0x1402abd8f cmovz rdx, rax ; +0xe6, 0x1402abd96 xorps xmm0, xmm0 ; +0xea, 0x1402abd9a movups xmmword ptr [rsp+68h+Block], xmm0 ; +0xed, 0x1402abd9d mov [rsp+68h+var_30], rdi ; +0xf2, 0x1402abda2 mov [rsp+68h+var_28], rdi ; +0xf7, 0x1402abda7 mov r8, 0FFFFFFFFFFFFFFFFh ; +0xfc, 0x1402abdac inc r8 ; +0x103, 0x1402abdb3 cmp byte ptr [rdx+r8], 0 ; +0x106, 0x1402abdb6 jnz short loc_1402ABDB3 ; +0x10b, 0x1402abdbb lea rcx, [rsp+68h+Block] ; +0x10d, 0x1402abdbd call sub_14003A930 ; +0x112, 0x1402abdc2 nop ; +0x117, 0x1402abdc7 lea rbp, [rsp+68h+Block] ; +0x118, 0x1402abdc8 cmp [rsp+68h+var_28], 0Fh ; +0x11d, 0x1402abdcd cmova rbp, [rsp+68h+Block] ; +0x123, 0x1402abdd3 mov rcx, cs:qword_1406C2EE8 ; +0x129, 0x1402abdd9 test rcx, rcx ; +0x130, 0x1402abde0 jnz short loc_1402ABE15 ; +0x133, 0x1402abde3 mov ecx, 3E0h; Size ; +0x135, 0x1402abde5 call ??2@YAPEAX_K@Z; operator new(unsigned __int64) ; +0x13a, 0x1402abdea mov [rsp+68h+var_48], rax ; +0x13f, 0x1402abdef mov rcx, rax ; +0x144, 0x1402abdf4 call sub_1401D0AE0 ; +0x147, 0x1402abdf7 nop ; +0x14c, 0x1402abdfc mov cs:qword_1406C2EE8, rax ; +0x14d, 0x1402abdfd mov r8, [rax] ; +0x154, 0x1402abe04 mov rcx, rax ; +0x157, 0x1402abe07 call qword ptr [r8+48h] ; +0x15a, 0x1402abe0a mov rcx, cs:qword_1406C2EE8 ; +0x15e, 0x1402abe0e mov edi, [rbx+164h] ; +0x165, 0x1402abe15 sub edi, [rbx+168h] ; +0x16b, 0x1402abe1b mov rdx, rbp ; +0x171, 0x1402abe21 call GameStatsManager__getStat ; +0x174, 0x1402abe24 mov ebp, eax ; +0x179, 0x1402abe29 mov rdx, [rsp+68h+var_28] ; +0x17b, 0x1402abe2b cmp rdx, 0Fh ; +0x180, 0x1402abe30 jbe short loc_1402ABE6B ; +0x184, 0x1402abe34 inc rdx ; +0x186, 0x1402abe36 mov rcx, [rsp+68h+Block]; Block ; +0x189, 0x1402abe39 mov rax, rcx ; +0x18e, 0x1402abe3e cmp rdx, 1000h ; +0x191, 0x1402abe41 jb short loc_1402ABE66 ; +0x198, 0x1402abe48 add rdx, 27h ; ''' ; +0x19a, 0x1402abe4a mov rcx, [rcx-8] ; +0x19e, 0x1402abe4e sub rax, rcx ; +0x1a2, 0x1402abe52 add rax, 0FFFFFFFFFFFFFFF8h ; +0x1a5, 0x1402abe55 cmp rax, 1Fh ; +0x1a9, 0x1402abe59 jbe short loc_1402ABE66 ; +0x1ad, 0x1402abe5d call cs:_invalid_parameter_noinfo_noreturn ; +0x1af, 0x1402abe5f align 2 ; +0x1b5, 0x1402abe65 call j_j_free ; +0x1b6, 0x1402abe66 cmp edi, ebp ; +0x1bb, 0x1402abe6b jle short loc_1402ABE7C ; +0x1bd, 0x1402abe6d mov rdx, rbx ; +0x1bf, 0x1402abe6f mov rcx, rsi ; +0x1c2, 0x1402abe72 call GJShopLayer__showCantAffordMessage ; +0x1c5, 0x1402abe75 jmp short loc_1402ABE9E ; +0x1ca, 0x1402abe7a mov rcx, rbx ; +0x1cc, 0x1402abe7c call PurchaseItemPopup__create ; +0x1cf, 0x1402abe7f lea rcx, [rsi+198h] ; +0x1d4, 0x1402abe84 mov [rax+280h], rcx ; +0x1db, 0x1402abe8b mov rdx, [rax] ; +0x1e2, 0x1402abe92 mov rcx, rax ; +0x1e5, 0x1402abe95 call qword ptr [rdx+410h] ; +0x1e8, 0x1402abe98 mov rcx, [rsp+68h+var_20] ; +0x1ee, 0x1402abe9e xor rcx, rsp; StackCookie ; +0x1f3, 0x1402abea3 call __security_check_cookie ; +0x1f6, 0x1402abea6 mov rbx, [rsp+68h+arg_10] ; +0x1fb, 0x1402abeab add rsp, 50h ; +0x203, 0x1402abeb3 pop rdi ; +0x207, 0x1402abeb7 pop rsi ; +0x208, 0x1402abeb8 pop rbp ; +0x209, 0x1402abeb9 retn ; +0x20a, 0x1402abeba