{"type": "func", "start": 339590, "end": 339628, "name": "sub_52E86", "pseudocode": "// \n// sub_52E86 from 0x52e86 to 0x52eac (38 bytes)\n// \n// 2 xrefs:\n// > sub_529EC @ 0x529f4\n// > sub_52A58 @ 0x52a9e\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\nint __fastcall sub_52E86(int a1, int a2)\n{\n  int v3; // r0\n  int result; // r0\n\n  v3 = *(_DWORD *)(a1 + 8);\n  if ( v3 < 0 )\n    v3 = -v3;\n  if ( v3 >= a2 || (result = sub_5336A(a1, a2)) == 0 )\n  {\n    *(_DWORD *)(a1 + 4) = a2;\n    return 0;\n  }\n  return result;\n}", "assembly": "; \n; sub_52E86 from 0x52e86 to 0x52eac (38 bytes)\n; \n; 2 xrefs:\n; > sub_529EC @ 0x529f4\n; > sub_52A58 @ 0x52a9e\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\nPUSH            {R4,R5,R7,LR}                                          ; +0x0, 0x52e86\nADD             R7, SP, #8                                             ; +0x2, 0x52e88\nMOV             R5, R0                                                 ; +0x4, 0x52e8a\nLDR             R0, [R0,#8]                                            ; +0x6, 0x52e8c\nMOV             R4, R1                                                 ; +0x8, 0x52e8e\nCMP             R0, #0                                                 ; +0xa, 0x52e90\nBPL             loc_52E96                                              ; +0xc, 0x52e92\nNEGS            R0, R0                                                 ; +0xe, 0x52e94\nCMP             R0, R4                                                 ; +0x10, 0x52e96\nBGE             loc_52EA6                                              ; +0x12, 0x52e98\nMOV             R0, R5                                                 ; +0x14, 0x52e9a\nMOV             R1, R4                                                 ; +0x16, 0x52e9c\nBL              sub_5336A                                              ; +0x18, 0x52e9e\nCBZ             R0, loc_52EA6                                          ; +0x1c, 0x52ea2\nPOP             {R4,R5,R7,PC}                                          ; +0x1e, 0x52ea4\nMOVS            R0, #0                                                 ; +0x20, 0x52ea6\nSTR             R4, [R5,#4]                                            ; +0x22, 0x52ea8\nPOP             {R4,R5,R7,PC}                                          ; +0x24, 0x52eaa", "xrefs": ["sub_529EC @ 0x529f4", "sub_52A58 @ 0x52a9e"], "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"}