{"type": "func", "start": 838160, "end": 838340, "name": "sub_CCA10", "pseudocode": "// \n// sub_CCA10 from 0xcca10 to 0xccac4 (180 bytes)\n// \n// 2 xrefs:\n// > sub_7C9F8 @ 0x7ca5c\n// > sub_7C9F8 @ 0x7ca70\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\n__int64 sub_CCA10()\n{\n  __int64 v0; // x19\n  int v1; // w8\n  int v2; // w1\n  int v3; // w20\n  __int64 v4; // x8\n  __int64 v5; // x9\n  float v6; // s2\n  int v7; // w10\n  float v8; // s2\n  float v9; // s3\n  float v10; // s2\n\n  sub_CD4C4();\n  if ( v1 + 2 >= v2 )\n  {\n    v3 = *(_DWORD *)(v0 + 524);\n    if ( v3 >= 1 )\n    {\n      sub_CD29C(v0 + 260);\n      v4 = 0;\n      *(_DWORD *)(v0 + 524) = 0;\n      *(_DWORD *)(v0 + 256) = v3;\n      while ( v4 != 128 )\n      {\n        v5 = v0 + v4;\n        v6 = *(float *)(v0 + v4);\n        v7 = *(_DWORD *)(v0 + v4 + 128);\n        v4 += 4;\n        v8 = v6 * (float)(1.0 / (float)v3);\n        v9 = sqrtf(v8);\n        if ( v8 <= 0.0 )\n          v10 = 0.0;\n        else\n          v10 = v9;\n        *(_DWORD *)(v5 + 260) = v7;\n        *(float *)(v5 + 388) = v10;\n      }\n      sub_CD29C(v0);\n      *(_WORD *)(v0 + 516) = *(_WORD *)(v0 + 528);\n    }\n  }\n  else\n  {\n    sub_CD29C(v0 + 256);\n  }\n  return 0;\n}", "assembly": "; \n; sub_CCA10 from 0xcca10 to 0xccac4 (180 bytes)\n; \n; 2 xrefs:\n; > sub_7C9F8 @ 0x7ca5c\n; > sub_7C9F8 @ 0x7ca70\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\nSTP             X20, X19, [SP,#var_20]!                                ; +0x0, 0xcca10\nSTP             X29, X30, [SP,#0x20+var_10]                            ; +0x4, 0xcca14\nLDR             W8, [X0,#0x208]                                        ; +0x8, 0xcca18\nBL              sub_CD4C4                                              ; +0xc, 0xcca1c\nADD             W8, W8, #2                                             ; +0x10, 0xcca20\nCMP             W8, W1                                                 ; +0x14, 0xcca24\nB.GE            loc_CCA3C                                              ; +0x18, 0xcca28\nADD             X0, X19, #0x100                                        ; +0x1c, 0xcca2c\nMOV             W2, #0x108                                             ; +0x20, 0xcca30\nBL              sub_CD29C                                              ; +0x24, 0xcca34\nB               loc_CCAB8                                              ; +0x28, 0xcca38\nLDR             W20, [X19,#0x20C]                                      ; +0x2c, 0xcca3c\nCMP             W20, #1                                                ; +0x30, 0xcca40\nB.LT            loc_CCAB8                                              ; +0x34, 0xcca44\nADD             X0, X19, #0x104                                        ; +0x38, 0xcca48\nMOV             W2, #0x104                                             ; +0x3c, 0xcca4c\nBL              sub_CD29C                                              ; +0x40, 0xcca50\nSCVTF           S0, W20                                                ; +0x44, 0xcca54\nFMOV            S1, #1.0                                               ; +0x48, 0xcca58\nMOV             X8, XZR                                                ; +0x4c, 0xcca5c\nFDIV            S0, S1, S0                                             ; +0x50, 0xcca60\nFMOV            S1, WZR                                                ; +0x54, 0xcca64\nSTR             WZR, [X19,#0x20C]                                      ; +0x58, 0xcca68\nSTR             W20, [X19,#0x100]                                      ; +0x5c, 0xcca6c\nCMP             X8, #0x80                                              ; +0x60, 0xcca70\nB.EQ            loc_CCAA4                                              ; +0x64, 0xcca74\nADD             X9, X19, X8                                            ; +0x68, 0xcca78\nLDR             S2, [X9]                                               ; +0x6c, 0xcca7c\nLDR             W10, [X9,#0x80]                                        ; +0x70, 0xcca80\nADD             X8, X8, #4                                             ; +0x74, 0xcca84\nFMUL            S2, S2, S0                                             ; +0x78, 0xcca88\nFSQRT           S3, S2                                                 ; +0x7c, 0xcca8c\nFCMP            S2, #0.0                                               ; +0x80, 0xcca90\nFCSEL           S2, S3, S1, GT                                         ; +0x84, 0xcca94\nSTR             W10, [X9,#0x104]                                       ; +0x88, 0xcca98\nSTR             S2, [X9,#0x184]                                        ; +0x8c, 0xcca9c\nB               loc_CCA70                                              ; +0x90, 0xccaa0\nMOV             W2, #0x100                                             ; +0x94, 0xccaa4\nMOV             X0, X19                                                ; +0x98, 0xccaa8\nBL              sub_CD29C                                              ; +0x9c, 0xccaac\nLDRH            W8, [X19,#0x210]                                       ; +0xa0, 0xccab0\nSTRH            W8, [X19,#0x204]                                       ; +0xa4, 0xccab4\nLDP             X29, X30, [SP,#0x20+var_10]                            ; +0xa8, 0xccab8\nMOV             W0, WZR                                                ; +0xac, 0xccabc\nB               loc_CD37C                                              ; +0xb0, 0xccac0", "xrefs": ["sub_7C9F8 @ 0x7ca5c", "sub_7C9F8 @ 0x7ca70"], "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"}