{"type": "func", "start": 5372054720, "end": 5372055201, "name": "GJBaseGameLayer::getAreaObjectValue", "pseudocode": "// \n// GJBaseGameLayer::getAreaObjectValue from 0x140330cc0 to 0x140330ea1 (481 bytes)\n// \n// 7 xrefs:\n// > GJBaseGameLayer::processAreaEffects @ 0x140331908\n// > GJBaseGameLayer::processAreaTransformGroupAction @ 0x140332040\n// > GJBaseGameLayer::processAreaRotateGroupAction @ 0x140332b21\n// > GJBaseGameLayer::processAreaMoveGroupAction @ 0x1403332fa\n// > GJBaseGameLayer::processAreaTintGroupAction @ 0x140333951\n// > GJBaseGameLayer::processAreaTintGroupAction @ 0x140333c7d\n// > <???> @ 0x14091f5e0\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:30:32 +0000\n// \n\nfloat __fastcall GJBaseGameLayer::getAreaObjectValue(__int64 a1, __int64 a2, __int16 *a3, float *a4, bool *a5)\n{\n  float v9; // xmm6_4\n  int v10; // ecx\n  float v11; // xmm0_4\n  float v12; // xmm0_4\n  float v13; // xmm2_4\n  float v14; // xmm3_4\n  __int64 v15; // rax\n  float v16; // xmm1_4\n  float v17; // xmm1_4\n  bool v18; // cf\n  float v19; // xmm0_4\n  float v20; // xmm2_4\n  float v21; // xmm2_4\n  float v22; // xmm1_4\n  float v23; // xmm1_4\n  const struct cocos2d::CCPoint *v24; // rax\n  const struct cocos2d::CCPoint *v25; // r8\n  float v26; // xmm2_4\n  float v27; // xmm0_4\n  float result; // xmm0_4\n  float v29; // [rsp+58h] [rbp+10h] BYREF\n  float v30; // [rsp+5Ch] [rbp+14h]\n  char v31; // [rsp+60h] [rbp+18h] BYREF\n\n  (*(void (__fastcall **)(__int16 *, float *))(*(_QWORD *)a3 + 1208LL))(a3, &v29);\n  v9 = 0.0;\n  v10 = *(_DWORD *)(*(_QWORD *)(a2 + 160) + 1984LL);\n  if ( v10 == 1 )\n  {\n    v11 = *(float *)(a2 + 28);\n    if ( v11 == 0.0 )\n      v12 = 0.0;\n    else\n      v12 = v11 * *(float *)(a1 + 4LL * a3[506] + 4528);\n    v13 = *a4;\n    v14 = v29;\n  }\n  else\n  {\n    if ( v10 != 2 )\n    {\n      v20 = *(float *)(a2 + 36);\n      if ( v20 == 0.0 )\n        v21 = 0.0;\n      else\n        v21 = v20 * *(float *)(a1 + 4LL * a3[506] + 4532);\n      v22 = *(float *)(a2 + 28);\n      if ( v22 == 0.0 )\n        v23 = 0.0;\n      else\n        v23 = v22 * *(float *)(a1 + 4LL * a3[506] + 4528);\n      cocos2d::CCPoint::CCPoint((cocos2d::CCPoint *)&v31, v23 + *a4, v21 + a4[1]);\n      v17 = cocos2d::ccpDistance((cocos2d *)&v29, v24, v25);\n      v26 = *a4;\n      if ( *(_BYTE *)(a2 + 168) )\n        v18 = v26 < v29;\n      else\n        v18 = v30 < v26;\n      goto LABEL_24;\n    }\n    v19 = *(float *)(a2 + 28);\n    v13 = a4[1];\n    if ( v19 == 0.0 )\n    {\n      v12 = 0.0;\n      v14 = v30;\n    }\n    else\n    {\n      v14 = v30;\n      v12 = v19 * *(float *)(a1 + 4LL * a3[506] + 4528);\n    }\n  }\n  v15 = 44;\n  v16 = (float)(v14 - v13) + v12;\n  if ( v16 < 0.0 )\n    v15 = 40;\n  v17 = v16 * *(float *)(v15 + a2);\n  if ( *(_BYTE *)(a2 + 168) )\n    v18 = v13 < v14;\n  else\n    v18 = v14 < v13;\nLABEL_24:\n  *a5 = !v18;\n  v27 = *(float *)(a2 + 20);\n  if ( v27 != 0.0 )\n    v9 = v27 * *(float *)(a1 + 4LL * a3[506] + 4524);\n  result = sub_1403307E0(v17, (int)(float)(v9 + *(float *)(a2 + 16)), *(float *)(a2 + 48));\n  if ( *(_BYTE *)(*(_QWORD *)(a2 + 160) + 2028LL) )\n    return 1.0 - result;\n  return result;\n}", "assembly": "; \n; GJBaseGameLayer::getAreaObjectValue from 0x140330cc0 to 0x140330ea1 (481 bytes)\n; \n; 7 xrefs:\n; > GJBaseGameLayer::processAreaEffects @ 0x140331908\n; > GJBaseGameLayer::processAreaTransformGroupAction @ 0x140332040\n; > GJBaseGameLayer::processAreaRotateGroupAction @ 0x140332b21\n; > GJBaseGameLayer::processAreaMoveGroupAction @ 0x1403332fa\n; > GJBaseGameLayer::processAreaTintGroupAction @ 0x140333951\n; > GJBaseGameLayer::processAreaTintGroupAction @ 0x140333c7d\n; > <???> @ 0x14091f5e0\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:30:32 +0000\n; \nmov     [rsp+arg_0], rbx                                               ; +0x0, 0x140330cc0\npush    rbp                                                            ; +0x5, 0x140330cc5\npush    rsi                                                            ; +0x6, 0x140330cc6\npush    rdi                                                            ; +0x7, 0x140330cc7\nsub     rsp, 30h                                                       ; +0x8, 0x140330cc8\nmov     rax, [r8]                                                      ; +0xc, 0x140330ccc\nmov     rbx, rdx                                                       ; +0xf, 0x140330ccf\nmov     rsi, rcx                                                       ; +0x12, 0x140330cd2\nmovaps  [rsp+48h+var_28], xmm6                                         ; +0x15, 0x140330cd5\nlea     rdx, [rsp+48h+arg_8]                                           ; +0x1a, 0x140330cda\nmov     rcx, r8                                                        ; +0x1f, 0x140330cdf\nmov     rbp, r9                                                        ; +0x22, 0x140330ce2\nmov     rdi, r8                                                        ; +0x25, 0x140330ce5\ncall    qword ptr [rax+4B8h]                                           ; +0x28, 0x140330ce8\nmov     rax, [rbx+0A0h]                                                ; +0x2e, 0x140330cee\nxorps   xmm6, xmm6                                                     ; +0x35, 0x140330cf5\nmov     ecx, [rax+7C0h]                                                ; +0x38, 0x140330cf8\ncmp     ecx, 1                                                         ; +0x3e, 0x140330cfe\njnz     short loc_140330D69                                            ; +0x41, 0x140330d01\nmovss   xmm0, dword ptr [rbx+1Ch]                                      ; +0x43, 0x140330d03\nucomiss xmm0, xmm6                                                     ; +0x48, 0x140330d08\njp      short loc_140330D14                                            ; +0x4b, 0x140330d0b\njnz     short loc_140330D14                                            ; +0x4d, 0x140330d0d\nxorps   xmm0, xmm0                                                     ; +0x4f, 0x140330d0f\njmp     short loc_140330D25                                            ; +0x52, 0x140330d12\nmovsx   rax, word ptr [rdi+3F4h]                                       ; +0x54, 0x140330d14\nmulss   xmm0, dword ptr [rsi+rax*4+11B0h]                              ; +0x5c, 0x140330d1c\nmovss   xmm2, dword ptr [rbp+0]                                        ; +0x65, 0x140330d25\nmovss   xmm3, [rsp+48h+arg_8]                                          ; +0x6a, 0x140330d2a\nmovaps  xmm1, xmm3                                                     ; +0x70, 0x140330d30\nmov     eax, 2Ch ; ','                                                 ; +0x73, 0x140330d33\nsubss   xmm1, xmm2                                                     ; +0x78, 0x140330d38\nmov     ecx, 28h ; '('                                                 ; +0x7c, 0x140330d3c\naddss   xmm1, xmm0                                                     ; +0x81, 0x140330d41\ncomiss  xmm6, xmm1                                                     ; +0x85, 0x140330d45\ncmova   eax, ecx                                                       ; +0x88, 0x140330d48\ncmp     byte ptr [rbx+0A8h], 0                                         ; +0x8b, 0x140330d4b\nmulss   xmm1, dword ptr [rax+rbx]                                      ; +0x92, 0x140330d52\njz      short loc_140330D61                                            ; +0x97, 0x140330d57\ncomiss  xmm2, xmm3                                                     ; +0x99, 0x140330d59\njmp     loc_140330E30                                                  ; +0x9c, 0x140330d5c\ncomiss  xmm3, xmm2                                                     ; +0xa1, 0x140330d61\njmp     loc_140330E30                                                  ; +0xa4, 0x140330d64\ncmp     ecx, 2                                                         ; +0xa9, 0x140330d69\njnz     short loc_140330DA8                                            ; +0xac, 0x140330d6c\nmovss   xmm0, dword ptr [rbx+1Ch]                                      ; +0xae, 0x140330d6e\nucomiss xmm0, xmm6                                                     ; +0xb3, 0x140330d73\njp      short loc_140330D8A                                            ; +0xb6, 0x140330d76\njnz     short loc_140330D8A                                            ; +0xb8, 0x140330d78\nmovss   xmm2, dword ptr [rbp+4]                                        ; +0xba, 0x140330d7a\nxorps   xmm0, xmm0                                                     ; +0xbf, 0x140330d7f\nmovss   xmm3, [rsp+48h+arg_C]                                          ; +0xc2, 0x140330d82\njmp     short loc_140330D30                                            ; +0xc8, 0x140330d88\nmovsx   rax, word ptr [rdi+3F4h]                                       ; +0xca, 0x140330d8a\nmovss   xmm2, dword ptr [rbp+4]                                        ; +0xd2, 0x140330d92\nmovss   xmm3, [rsp+48h+arg_C]                                          ; +0xd7, 0x140330d97\nmulss   xmm0, dword ptr [rsi+rax*4+11B0h]                              ; +0xdd, 0x140330d9d\njmp     short loc_140330D30                                            ; +0xe6, 0x140330da6\nmovss   xmm2, dword ptr [rbx+24h]                                      ; +0xe8, 0x140330da8\nucomiss xmm2, xmm6                                                     ; +0xed, 0x140330dad\njp      short loc_140330DB9                                            ; +0xf0, 0x140330db0\njnz     short loc_140330DB9                                            ; +0xf2, 0x140330db2\nxorps   xmm2, xmm2                                                     ; +0xf4, 0x140330db4\njmp     short loc_140330DCA                                            ; +0xf7, 0x140330db7\nmovsx   rax, word ptr [rdi+3F4h]                                       ; +0xf9, 0x140330db9\nmulss   xmm2, dword ptr [rsi+rax*4+11B4h]                              ; +0x101, 0x140330dc1\nmovss   xmm1, dword ptr [rbx+1Ch]                                      ; +0x10a, 0x140330dca\nucomiss xmm1, xmm6                                                     ; +0x10f, 0x140330dcf\njp      short loc_140330DDB                                            ; +0x112, 0x140330dd2\njnz     short loc_140330DDB                                            ; +0x114, 0x140330dd4\nxorps   xmm1, xmm1                                                     ; +0x116, 0x140330dd6\njmp     short loc_140330DEC                                            ; +0x119, 0x140330dd9\nmovsx   rax, word ptr [rdi+3F4h]                                       ; +0x11b, 0x140330ddb\nmulss   xmm1, dword ptr [rsi+rax*4+11B0h]                              ; +0x123, 0x140330de3\naddss   xmm2, dword ptr [rbp+4]                                        ; +0x12c, 0x140330dec\naddss   xmm1, dword ptr [rbp+0]                                        ; +0x131, 0x140330df1\nlea     rcx, [rsp+48h+arg_10]                                          ; +0x136, 0x140330df6\ncall    cs:??0CCPoint@cocos2d@@QEAA@MM@Z; cocos2d::CCPoint::CCPoint(float,float) ; +0x13b, 0x140330dfb\nmov     rdx, rax                                                       ; +0x141, 0x140330e01\nlea     rcx, [rsp+48h+arg_8]                                           ; +0x144, 0x140330e04\ncall    cs:?ccpDistance@cocos2d@@YAMAEBVCCPoint@1@0@Z; cocos2d::ccpDistance(cocos2d::CCPoint const &,cocos2d::CCPoint const &) ; +0x149, 0x140330e09\ncmp     byte ptr [rbx+0A8h], 0                                         ; +0x14f, 0x140330e0f\nmovaps  xmm1, xmm0                                                     ; +0x156, 0x140330e16\nmovss   xmm2, dword ptr [rbp+0]                                        ; +0x159, 0x140330e19\njz      short loc_140330E27                                            ; +0x15e, 0x140330e1e\ncomiss  xmm2, [rsp+48h+arg_8]                                          ; +0x160, 0x140330e20\njmp     short loc_140330E30                                            ; +0x165, 0x140330e25\nmovss   xmm0, [rsp+48h+arg_C]                                          ; +0x167, 0x140330e27\ncomiss  xmm0, xmm2                                                     ; +0x16d, 0x140330e2d\nmov     rax, [rsp+48h+arg_20]                                          ; +0x170, 0x140330e30\nsetnb   cl                                                             ; +0x175, 0x140330e35\nmov     [rax], cl                                                      ; +0x178, 0x140330e38\nmovss   xmm0, dword ptr [rbx+14h]                                      ; +0x17a, 0x140330e3a\nucomiss xmm0, xmm6                                                     ; +0x17f, 0x140330e3f\njp      short loc_140330E46                                            ; +0x182, 0x140330e42\njz      short loc_140330E5A                                            ; +0x184, 0x140330e44\nmovsx   rax, word ptr [rdi+3F4h]                                       ; +0x186, 0x140330e46\nmulss   xmm0, dword ptr [rsi+rax*4+11ACh]                              ; +0x18e, 0x140330e4e\nmovaps  xmm6, xmm0                                                     ; +0x197, 0x140330e57\naddss   xmm6, dword ptr [rbx+10h]                                      ; +0x19a, 0x140330e5a\nmovss   xmm2, dword ptr [rbx+30h]                                      ; +0x19f, 0x140330e5f\nmovaps  xmm0, xmm1                                                     ; +0x1a4, 0x140330e64\ncvttss2si edx, xmm6                                                    ; +0x1a7, 0x140330e67\ncall    sub_1403307E0                                                  ; +0x1ab, 0x140330e6b\nmov     rax, [rbx+0A0h]                                                ; +0x1b0, 0x140330e70\nmovaps  xmm2, xmm0                                                     ; +0x1b7, 0x140330e77\ncmp     byte ptr [rax+7ECh], 0                                         ; +0x1ba, 0x140330e7a\njz      short loc_140330E8F                                            ; +0x1c1, 0x140330e81\nmovss   xmm0, cs:flt_140835080                                         ; +0x1c3, 0x140330e83\nsubss   xmm0, xmm2                                                     ; +0x1cb, 0x140330e8b\nmov     rbx, [rsp+48h+arg_0]                                           ; +0x1cf, 0x140330e8f\nmovaps  xmm6, [rsp+48h+var_28]                                         ; +0x1d4, 0x140330e94\nadd     rsp, 30h                                                       ; +0x1d9, 0x140330e99\npop     rdi                                                            ; +0x1dd, 0x140330e9d\npop     rsi                                                            ; +0x1de, 0x140330e9e\npop     rbp                                                            ; +0x1df, 0x140330e9f\nretn                                                                   ; +0x1e0, 0x140330ea0", "xrefs": ["GJBaseGameLayer::processAreaEffects @ 0x140331908", "GJBaseGameLayer::processAreaTransformGroupAction @ 0x140332040", "GJBaseGameLayer::processAreaRotateGroupAction @ 0x140332b21", "GJBaseGameLayer::processAreaMoveGroupAction @ 0x1403332fa", "GJBaseGameLayer::processAreaTintGroupAction @ 0x140333951", "GJBaseGameLayer::processAreaTintGroupAction @ 0x140333c7d", "<???> @ 0x14091f5e0"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}