{"type": "func", "start": 6442694416, "end": 6442694591, "name": "cocos2d::CCTurnOffTiles::startWithTarget", "pseudocode": "// \n// cocos2d::CCTurnOffTiles::startWithTarget from 0x18003b710 to 0x18003b7bf (175 bytes)\n// \n// 3 xrefs:\n// > <???> @ 0x1800ea690\n// > <???> @ 0x1801438a8\n// > <???> @ 0x1801b0f24\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 cocos2d::CCTurnOffTiles::startWithTarget(cocos2d::CCTurnOffTiles *this, struct cocos2d::CCNode *a2)\n{\n  unsigned int v3; // ecx\n  float v4; // xmm0_4\n  void *v5; // rax\n  unsigned int v6; // ebx\n  __int64 v7; // rdx\n  __int64 v8; // rsi\n  __int64 i; // rdi\n  int v10; // eax\n  int v11; // r8d\n  __int64 v12; // rdx\n\n  cocos2d::CCGridAction::startWithTarget(this, a2);\n  v3 = *((_DWORD *)this + 26);\n  if ( v3 != -1 )\n    srand(v3);\n  v4 = *((float *)this + 25) * *((float *)this + 24);\n  *((_DWORD *)this + 27) = (int)v4;\n  v5 = operator new(saturated_mul((unsigned int)(int)v4, 4u));\n  v6 = *((_DWORD *)this + 27);\n  v7 = 0;\n  for ( *((_QWORD *)this + 14) = v5; (unsigned int)v7 < v6; v6 = *((_DWORD *)this + 27) )\n  {\n    *(_DWORD *)(*((_QWORD *)this + 14) + 4 * v7) = v7;\n    v7 = (unsigned int)(v7 + 1);\n  }\n  v8 = *((_QWORD *)this + 14);\n  for ( i = (int)(v6 - 1); i >= 0; *(_DWORD *)(v8 + 4 * v12) = v11 )\n  {\n    v10 = rand();\n    v11 = *(_DWORD *)(v8 + 4 * i);\n    v12 = (unsigned int)(v10 >> 31);\n    LODWORD(v12) = v10 % (int)v6--;\n    *(_DWORD *)(v8 + 4 * i--) = *(_DWORD *)(v8 + 4 * v12);\n  }\n}", "assembly": "; \n; cocos2d::CCTurnOffTiles::startWithTarget from 0x18003b710 to 0x18003b7bf (175 bytes)\n; \n; 3 xrefs:\n; > <???> @ 0x1800ea690\n; > <???> @ 0x1801438a8\n; > <???> @ 0x1801b0f24\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\nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x18003b710\nmov     [rsp+arg_8], rsi                                               ; +0x5, 0x18003b715\npush    rdi                                                            ; +0xa, 0x18003b71a\nsub     rsp, 20h                                                       ; +0xb, 0x18003b71b\nmov     rdi, rcx                                                       ; +0xf, 0x18003b71f\ncall    ?startWithTarget@CCGridAction@cocos2d@@UEAAXPEAVCCNode@2@@Z; cocos2d::CCGridAction::startWithTarget(cocos2d::CCNode *) ; +0x12, 0x18003b722\nmov     ecx, [rdi+68h]; Seed                                           ; +0x17, 0x18003b727\ncmp     ecx, 0FFFFFFFFh                                                ; +0x1a, 0x18003b72a\njz      short loc_18003B735                                            ; +0x1d, 0x18003b72d\ncall    cs:srand                                                       ; +0x1f, 0x18003b72f\nmovss   xmm0, dword ptr [rdi+64h]                                      ; +0x25, 0x18003b735\nmulss   xmm0, dword ptr [rdi+60h]                                      ; +0x2a, 0x18003b73a\ncvttss2si rax, xmm0                                                    ; +0x2f, 0x18003b73f\nmov     ecx, eax                                                       ; +0x34, 0x18003b744\nmov     [rdi+6Ch], eax                                                 ; +0x36, 0x18003b746\nmov     eax, 4                                                         ; +0x39, 0x18003b749\nmul     rcx                                                            ; +0x3e, 0x18003b74e\nmov     rcx, 0FFFFFFFFFFFFFFFFh                                        ; +0x41, 0x18003b751\ncmovo   rax, rcx                                                       ; +0x48, 0x18003b758\nmov     rcx, rax; Size                                                 ; +0x4c, 0x18003b75c\ncall    j_??2@YAPEAX_K@Z; operator new(unsigned __int64)               ; +0x4f, 0x18003b75f\nmov     ebx, [rdi+6Ch]                                                 ; +0x54, 0x18003b764\nxor     edx, edx                                                       ; +0x57, 0x18003b767\nmov     [rdi+70h], rax                                                 ; +0x59, 0x18003b769\ntest    ebx, ebx                                                       ; +0x5d, 0x18003b76d\njz      short loc_18003B781                                            ; +0x5f, 0x18003b76f\nmov     rax, [rdi+70h]                                                 ; +0x61, 0x18003b771\nmov     [rax+rdx*4], edx                                               ; +0x65, 0x18003b775\ninc     edx                                                            ; +0x68, 0x18003b778\nmov     ebx, [rdi+6Ch]                                                 ; +0x6a, 0x18003b77a\ncmp     edx, ebx                                                       ; +0x6d, 0x18003b77d\njb      short loc_18003B771                                            ; +0x6f, 0x18003b77f\nmov     rsi, [rdi+70h]                                                 ; +0x71, 0x18003b781\nlea     eax, [rbx-1]                                                   ; +0x75, 0x18003b785\nmovsxd  rdi, eax                                                       ; +0x78, 0x18003b788\ntest    eax, eax                                                       ; +0x7b, 0x18003b78b\njs      short loc_18003B7AF                                            ; +0x7d, 0x18003b78d\nnop                                                                    ; +0x7f, 0x18003b78f\ncall    cs:rand                                                        ; +0x80, 0x18003b790\nmov     r8d, [rsi+rdi*4]                                               ; +0x86, 0x18003b796\ncdq                                                                    ; +0x8a, 0x18003b79a\nidiv    ebx                                                            ; +0x8b, 0x18003b79b\ndec     ebx                                                            ; +0x8d, 0x18003b79d\nmov     eax, [rsi+rdx*4]                                               ; +0x8f, 0x18003b79f\nmov     [rsi+rdi*4], eax                                               ; +0x92, 0x18003b7a2\nsub     rdi, 1                                                         ; +0x95, 0x18003b7a5\nmov     [rsi+rdx*4], r8d                                               ; +0x99, 0x18003b7a9\njns     short loc_18003B790                                            ; +0x9d, 0x18003b7ad\nmov     rbx, [rsp+28h+arg_0]                                           ; +0x9f, 0x18003b7af\nmov     rsi, [rsp+28h+arg_8]                                           ; +0xa4, 0x18003b7b4\nadd     rsp, 20h                                                       ; +0xa9, 0x18003b7b9\npop     rdi                                                            ; +0xad, 0x18003b7bd\nretn                                                                   ; +0xae, 0x18003b7be", "xrefs": ["<???> @ 0x1800ea690", "<???> @ 0x1801438a8", "<???> @ 0x1801b0f24"], "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"}